Re: gtk_window_set_icons
- From: Havoc Pennington <hp redhat com>
- To: Owen Taylor <otaylor redhat com>
- Cc: gtk-devel-list gnome org
- Subject: Re: gtk_window_set_icons
- Date: 26 Aug 2001 18:35:24 -0400
Owen Taylor <otaylor redhat com> writes:
> getters and setters and properties all need to give back what was set.
> If you go with a list (see below), then the behavior is obvious,
> though limitations of our current set of types probably make the
> property uninteresting.
Do we have any way to have a "list of pixbufs" property?
> Ugh. What an awful interface. Look how much text it took you took explain
> it in the docs!
>
> "Pick 1,2, or 3 icons, of sizes close to the sizes of the parameter names,
> then match them up with the parameters" is just too painful.
>
> I think a list + a recommendation in the docs: "a good choice for the sizes
> to include is 16x16 and 48x48" would be much nicer.
I am not that fond of the interface, but I hate the list too. It
continues the "make up some sizes" pattern currently seen in X. Plus
GList interfaces are annoying to use and not very self-documenting.
Admittedly, in the light of day my attempts to avoid the list didn't
work out so well. Suggestion below.
> Also, I think GTK+ should give the window manager the icons in the
> sizes that the app provides and let the window manager / user worry
> about scaling. Remember, scaling twice provides considerably worse
> results than scaling once, and scaling even by a small amount reduces
> quality.
Yes, that makes sense.
> > I wasn't sure what size to use for the WM_NORMAL_HINTS pixmap
> > though.
We do need to do our own scaling here. There should be a standard size
for the pixmap, WM's can't really scale it unless they are the kind of
WM that will prefer _NET_WM_ICON anyhow.
> gdk_pixbuf_render_pixmap_and_mask (info->icon_32,
> &info->icon_pixmap,
> &info->icon_mask,
> 128);
>
> While violatation of the ICCCM for this is common, you _at least_ need
> to use the system default colormap/visual for this, not the GdkRGB
> colormap/visual.
Right, of course. (grumbles about how render_pixmap_and_mask should
have a cmap arg)
OK, if we do the list, I think we should have:
gtk_window_set_icon_list (GtkWindow, GList)
but also simply:
gtk_window_set_icon (GtkWindow, GdkPixbuf)
The docs for the list are "set whatever natural sizes you have" and
the docs for set_icon are "set the largest natural size you have which
isn't larger than 48x48 or so"
I think we need gtk_window_set_icon(). Otherwise I know I will get
annoyed every time I have to build the list.
Opinions on:
gtk_window_set_default_icon(_list?)
and the transients-inherit-from-parent behavior?
Havoc
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]