Re: options menu size




ahh.  thank you very much.  It works now :)

On 28 Dec 2001, Havoc Pennington wrote:


mcmahill mtl mit edu writes:
When I add an options menu to a table, it ends up being too small to read
when you're not accessing the menu.  Ie, the currently selected option can
t be read.  By either making other widgets in the same table column bigger
or by using set_usize on the options menu, I can get it big enough, but
this isn't so robust when different users choose different fonts.

So it seems as though the options menu isn't requesting enough size from
the table.

Any ideas how to fix this?

It's a cheesy bug - what you have to do is put the menu items in the
GtkMenu, show the menu items (gtk_widget_show), and only then call
gtk_option_menu_set_menu(). If you do stuff in the wrong order then 
the option menu doesn't notice you've added new menu items and gets
its size request wrong.

Havoc





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]