Re: can't access menu?
Re: can't access menu?
- Subject: Re: can't access menu?
- From: Matt Neuburg <email@hidden>
- Date: Tue, 22 Mar 2005 09:04:38 -0800
On Tue, 22 Mar 2005 11:32:57 -0500, Luc Vandal <email@hidden> said:
>Hi,
>
>I'm trying to set the menu's title but something strange happens. If I
>add a breakpoint in my code, I cannot step over!
>
>- (void)awakeFromNib
>{
> [[NSApp mainMenu] setTitle:@"Something"];
>}
>
The main menu is the menu bar, the thing at the top of the screen that
contains your menus (File, Edit, and so forth). So speaking of its title is
pretty meaningless. An easy approach to what you're probably trying to do is
to start with an outlet to the actual menu item whose title you're trying to
set, and use that to access the menu item. Be careful of the difference
between menu items and menus, by the way. m.
--
matt neuburg, phd = email@hidden, <http://www.tidbits.com/matt/>
A fool + a tool + an autorelease pool = cool!
AppleScript: the Definitive Guide
<http://www.amazon.com/exec/obidos/ASIN/0596005571/somethingsbymatt>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden