A duim menu question 
Author Message
 A duim menu question

If I define menus as command tables, how can I later access the gadget that
represents a specific item (for example inside a method
refresh-my-frame(frame) that enables/disables/changes labels of menu items
throughout the frame?

Thanks,
Nimi



Sun, 07 Sep 2003 22:18:23 GMT  
 A duim menu question


Quote:
> If I define menus as command tables, how can I later access the gadget that
> represents a specific item (for example inside a method
> refresh-my-frame(frame) that enables/disables/changes labels of menu items
> throughout the frame?

Can't you enable and disable commands themselves then the menu-items will
just follow.

__Jason



Sun, 07 Sep 2003 23:05:16 GMT  
 A duim menu question

Quote:

> Hi Jason,

> > Can't you enable and disable commands themselves then the menu-items will
> > just follow.

> This is another issue: when I'm doing command-enabled?-setter() on a
> command-table (in order to affect the entire menu) only the second item of
> that menu is affected! Looks like a strange bug...

This should work. Can you change the individual items as a workaround?

Quote:
> But my question referred to another problem I'm having: I need to change the
> label of the menu item from a routine that only has access to the frame
> object (and the global *command-table* definitions). How could I do that?

Isn't there a way of changing the label on a command? I don't really
remember, and I don't have FunDev handy sorry.

__Jason



Mon, 08 Sep 2003 02:01:34 GMT  
 A duim menu question

Quote:

>If I define menus as command tables, how can I later access the gadget that
>represents a specific item (for example inside a method
>refresh-my-frame(frame) that enables/disables/changes labels of menu items
>throughout the frame?

Using 'command-enabled-setter' will just do the right thing.

I don't remember right now how to change the label, but there
is something like do-command-menu-items that will map
over all the items in the menu.



Mon, 08 Sep 2003 22:00:22 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. DUIM focus question

2. DUIM font question

3. DUIM question

4. Stupid question about DUIM/widgets

5. DUIM question

6. TKinter question - A combo box / menu question

7. problem with DUIM at higher resolutions

8. updating an icon label in DUIM

9. updating an icon label in DUIM

10. help with DUIM application

11. DUIM clipboard

12. <tree-node> in DUIM

 

 
Powered by phpBB® Forum Software