This is the mail archive of the cygwin-xfree@cygwin.com mailing list for the Cygwin XFree86 project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Custom icons per window class/name patch


> Howdy Colin and Harold,
>
> At 10:54 AM 5/24/2003 +0100, you wrote:
> >Just tried your patch.
> >Works fine on xeyes, xcalc etc but banged (Dr Watson and all that jazz) on
> >ethereal (a gtk application).
> >I put the .ini file in c:\windows, but I assume it can go anywhere in the
> >%PATH%?
> >I'll have a play a bit more later and come back with some better results and
> >trace!
>
> Can you guys find an app that runs locally which causes this?  I'm cut off
> from real unix machines and compiling Konqueror under cygwin is a little
> bit more than I'm up for.  Just d/ling it would probably take all day!

for example the application of the kde-cygwin port of the QT library: designer,
linguist or assistant or the applications (konqueror,kate,...) of the
KDE3-cygwin port

You can find binary releases on http://sf.net/projects/kde-cygwin

qt - http://prdownloads.sourceforge.net/kde-cygwin/qt-3.0.4-b1.tar.bz2?download

kde -
http://prdownloads.sourceforge.net/kde-cygwin/setup-kde-3.1.1-b1.exe?download

> My initial feeling is that this is just a pixmap depth problem:  The XC
> apps all use 1-bit bitmaps, and the commercial-ish apps give colored pixmaps
> and that function miGetImage() doesn't downconvert, so the memory given
> for the bitmap isn't enough (not is the processing right, but that won't
> cause a crash, just ugliness).
>
Right: Above applications provides a icon_pixmap with 16bit per pixels.
A hack, which fixes the segfault is shown below. winScaleXBitmapToWindows()
assums that the xpixmap has one bit depth.

static void
winScaleXBitmapToWindows( int iconSize, int effBPP, PixmapPtr pixmap, unsigned
char *image)
...
< xStride  = ((pixmap->drawable.width +31)&(~31))/8;
> xStride  = ((pixmap->drawable.width * pixmap->drawable.bitsPerPixel
+31)&(~31))/8;

Unfortunally, no icon is shown in this case. There must be more fixes required.

Ralf


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]