Option Menu



This is a continuation of a thread started on glade-
users.

I am having a problem with the optionmenu widget 
resizing (or rather, not resizing) when new menu items 
are added to the menu connected to the optionsmenu. 
After checking into the code, it seems that the size of 
the optionmenu is set only when the menu is attached to 
the optionmenu. The optionmenu size functions are 
private. How can I force the the optionmenu to resize 
after adding new menu items? I have x expand and shrink 
enabled, if you were wondering.

I have found a workaround in the mean time. If I save 
the menu that is attached to the optionmenu, then 
unattach it from the optionmenu, add new items to it, 
and then re-attach it, the optionmenu is resized 
correctly.

Why am I doing this, you ask? No, I'm not changing the 
optionmenu items at various times in the program. I'm 
setting the optionmenu items at startup based on a 
configuration file read in when the program starts.

Thanks for any education you can provide.

David




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