Re: GNOME_STOCK_EMPTY
- From: Joel Becker <jlbec evilplan org>
- To: Tim Janik <timj gtk org>
- Cc: Havoc Pennington <hp redhat com>, Sven Neumann <sven gimp org>, Gtk+ Developers <gtk-devel-list gnome org>
- Subject: Re: GNOME_STOCK_EMPTY
- Date: Sat, 10 Nov 2001 21:01:11 +0000
On Sat, Nov 10, 2001 at 06:54:19PM +0100, Tim Janik wrote:
> On 9 Nov 2001, Havoc Pennington wrote:
> > alignment = gtk_alignment_new (0.5, 0.5, 1.0, 1.0);
> > gtk_icon_size_lookup (GTK_ICON_SIZE_WHATEVER, &width, &height);
> > gtk_widget_set_size_request (alignment, width, height);
> >
> > Then you have a stock-icon-sized spacer.
>
> sure that'd work. but isn't it a hell more inconvenient than just
> having an empty stock item?
> i can't see any good reason to not provide one.
Well, I chatted with Havoc, and I was satisfied with his
answer. But I don't know which is more "proper". My thought is
basically to fill in a column of stock items, some of which may be
clear. I don't know which is the "proper, clean" solution:
i = gtk_image_from_stock(GTK_STOCK_FOO);
gtk_container_add(i)
i = gtk_image_from_stock(GTK_STOCK_EMPTY);
gtk_container_add(i)
i = gtk_image_from_stock(GTK_STOCK_FOO);
gtk_container_add(i)
or
i = gtk_image_from_stock(GTK_STOCK_FOO);
gtk_container_add(i)
i = gtk_alignment_new();
a = gtk_icon_size_lookup();
gtk_widget_set_size_request(i, a);
gtk_container_add(i);
i = gtk_image_from_stock(GTK_STOCK_FOO);
gtk_container_add(i)
Joel
--
"Under capitalism, man exploits man. Under Communism, it's just
the opposite."
- John Kenneth Galbraith
http://www.jlbec.org/
jlbec evilplan org
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]