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


Hi Earle,

> Howdy!
> At 02:56 PM 5/18/2003 -0400, you wrote:
> >Sorry to take this back to a discussion that you guys were having
> >earlier... but I remember that someone wrote something along the lines of,
> >"most window managers include their own set of icons for X apps since most
> >X apps do not set an icon to be shown on the upper-left hand corner of the
> >window".
> >Can anyone concretely prove to me that there is not a way to do app icons
> >without having a icon config file and a set of icon files for common X
> >apps?  I would really like to avoid the headaches of distributing icons
> >and a new config file, if at all possible.
> >I am going to hold off on committing this patch until I am convinced that
> >it is the best way to go.
>
> Yes, you're right for some apps (like the Qt ones Ralf mentioned) the icon is
> included in the application itself, and it sets the WM_HINTS accordingly.  You
> can then check for it in the winCreateWindow section and also in the WM_HINTS
> property handler if it's changed later.  Others don't and then it's up to the
> WM to give them one, either from a config file or some built-in defaults.

... or this has to be provided by the client application (maintainer).

Because currently I have not idea how to deal with the pixmap files provided by
WM_HINTS (I have searched several hours to find an exact spec how to access the
pixmaps, unfortunally without any success, [does noone has used this before ?])
I'm going to provide a set of icon files for kde/qt with the next kde release.
Applying my patch (icon_base_filename=application_name [1]) and the LoadImage()
feature of searching all the pathes of the PATH environment var takes the burden
from the xserver maintainer to the application maintainer (like me).

The maintainer only have to release a set of icons for example in their client
bin directory (in my cases /opt/kde3/bin), which will be added to the PATH env
var before starting the xserver.
The xserver will search this files in case of starting applications, while basic
application without any icon would use the default 'x' icon.

Perhaps some time later after releasing the xserver with the icon feature the
application maintainer could be asked to provide some icons, which will be in
the bin dir of the xfree server without the need of any additional config
directory. Optionals users can use this ini file, but no by default. The only
requirements for this is [1], which seems not very complicated for me to deal
with.

> So a full-fledged patch should take that bitmap ID and convert it from an
> XBM to a icon resource in the wincreate() function, and give the default or
> config file specified icon for xterm.

This was the best, but ... see above. :-(

> Also, I didn't intend the change to be an official patch.  Using a xwin.ini
> file was just expedient.  The proper thing would be to do a ~/.xwinrc file
> format, and not use .icos but XPMs.

KDE/qt for example uses png images by default, so there may be more formats. My
suggestion is to start with this basic implementation and to see if other people
have some ideas and knowledge to enhance this.

Great Job Earle.

Ralf


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