Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re^2: How to Change Defaults in Basic Tk Menu

by haj (Vicar)
on Aug 30, 2020 at 00:08 UTC ( [id://11121189]=note: print w/replies, xml ) Need Help??


in reply to Re: How to Change Defaults in Basic Tk Menu
in thread How to Change Defaults in Basic Tk Menu

Note that for readability you can also use the labels instead of numerical indices:

my $wrap = $menu->entrycget('View','-menu')->entrycget('Wrap','-menu') +; $wrap->invoke('Word');

@roho: I don't know how choroba did it, but I found out that you've been using a method $more->menu and failed to find documentation for it. This made me curious, and I found that this method gets you the hardcoded menu from the Tk::Text widget, only that you don't get a chance to set the -wrap option for this widget. The rest was a matter of digging through this menu and the Tk docs...

Replies are listed 'Best First'.
Re^3: How to Change Defaults in Basic Tk Menu
by roho (Bishop) on Aug 30, 2020 at 04:57 UTC
    Thanks for the follow-up info haj. This was indeed quite obscure.

    "It's not how hard you work, it's how much you get done."

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11121189]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others contemplating the Monastery: (3)
As of 2024-04-25 17:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found