Xojo Conferences
XDCMay2019MiamiUSA

Platforms to show: All Mac Windows Linux Cross-Platform

NSMenuMBS.helpMenu as NSMenuMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 14.0 Yes Yes Yes Yes No
Function: Returns the help menu if one is registered.

Feedback, Comments & Corrections

NSMenuMBS.mainMenu as NSMenuMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 14.0 Yes Yes Yes Yes No
Function: Returns the main menu.

Feedback, Comments & Corrections

NSMenuMBS.menuBarVisible as boolean
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 9.6 Yes No No Yes, macOS only No
Function: Returns a Boolean value that indicates whether the menu bar is visible.
Notes:
Available in Mac OS X v10.2 and later.
Returns true if the menu bar is visible, otherwise false.

Feedback, Comments & Corrections

NSMenuMBS.NSMenuDidAddItemNotification as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 12.3 Yes No No Yes, macOS only No
Function: One of the notifications sent for menus.
Notes:
Use this constant with NSNotificationObserverMBS class to get an event when such a notification is sent.

Posted after a menu item is added to the menu. The notification object is the instance of NSMenuMBS that just added the new menu item.
This is very useful to customize the menu in Real Studio. The runtime rebuilds menu bar often, so you can catch it and edit menu.

The userInfo dictionary contains the following information:
NSMenuItemIndex: An integer index of the menu item that was added.

Feedback, Comments & Corrections

NSMenuMBS.NSMenuDidBeginTrackingNotification as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 12.3 Yes No No Yes, macOS only No
Function: One of the notifications sent for menus.
Notes:
Posted when menu tracking begins. The notification object is the main menu bar (NSApplicationMBS mainMenu) or the root menu of a popup button. This notification does not contain a userInfo dictionary.

Use this constant with NSNotificationObserverMBS class to get an event when such a notification is sent.

Feedback, Comments & Corrections

NSMenuMBS.NSMenuDidChangeItemNotification as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 12.3 Yes No No Yes, macOS only No
Function: One of the notifications sent for menus.
Notes:
Use this constant with NSNotificationObserverMBS class to get an event when such a notification is sent.

Posted after a menu item in the menu changes appearance. Changes include enabling/disabling, changes in state, and changes to title. The notification object is the instance of NSMenuMBS with the menu item that changed. The userInfo dictionary contains the following information:

KeyValue
NSMenuItemIndexAn integer index of the menu item that changed.

Feedback, Comments & Corrections

NSMenuMBS.NSMenuDidEndTrackingNotification as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 12.3 Yes No No Yes, macOS only No
Function: One of the notifications sent for menus.
Notes:
Use this constant with NSNotificationObserverMBS class to get an event when such a notification is sent.

Posted when menu tracking ends, even if no action is sent. The notification object is the main menu bar (NSApplicationMBS mainMenu) or the root menu of a popup button. This notification does not contain a userInfo

Feedback, Comments & Corrections

NSMenuMBS.NSMenuDidRemoveItemNotification as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 12.3 Yes No No Yes, macOS only No
Function: One of the notifications sent for menus.
Notes:
Use this constant with NSNotificationObserverMBS class to get an event when such a notification is sent.

Posted after a menu item is removed from the menu. The notification object is the instance of NSMenu that just removed the menu item. The userInfo dictionary contains the following information:

NSMenuItemIndex: An integer index of the menu item that was removed. Note that this index may no longer be valid and in any event no longer points to the menu item that was removed.

Feedback, Comments & Corrections

NSMenuMBS.NSMenuDidSendActionNotification as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 12.3 Yes No No Yes, macOS only No
Function: One of the notifications sent for menus.
Notes:
Use this constant with NSNotificationObserverMBS class to get an event when such a notification is sent.

Posted just after the application dispatches a menu item's action method to the menu item's target. The notification object is the instance of NSMenuMBS containing the chosen menu item. The userInfo dictionary contains the following information:

KeyValue
MenuItemThe menu item that was chosen.

Feedback, Comments & Corrections

NSMenuMBS.NSMenuWillSendActionNotification as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 12.3 Yes No No Yes, macOS only No
Function: One of the notifications sent for menus.
Notes:
Use this constant with NSNotificationObserverMBS class to get an event when such a notification is sent.

Posted just before the application dispatches a menu item's action method to the menu item's target. The notification object is the instance of NSMenuMBS containing the chosen menu item. The userInfo dictionary contains the following information:

KeyValue
MenuItemThe menu item that was chosen.

Feedback, Comments & Corrections

NSMenuMBS.popUpContextMenu(menu as NSMenuMBS, theEvent as NSEventMBS, view as NSViewMBS, font as NSFontMBS = nil)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 14.2 Yes No No Yes, macOS only No
Function: Displays a contextual menu over a view for an event using a specified font.
Notes:
menu: The menu object to use for the contextual menu.
event: An NSEvent object representing the event.
view: The view object over which to display the contextual menu.
font: An NSFont object representing the font for the contextual menu. If you pass in nil for the font, the method uses the default font for menu.

Specifying a font using the font parameter is discouraged. Instead set the menu’s font using the setFont: method and pass nil for the font parameter.

Feedback, Comments & Corrections

NSMenuMBS.setMenuBarVisible(value as boolean)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 9.6 Yes No No Yes, macOS only No
Function: Sets whether the menu bar is visible and selectable by the user.
Notes:
value: true if menu bar is to be visible, otherwise false.
Available in Mac OS X v10.2 and later.

Feedback, Comments & Corrections

NSMenuMBS.windowsMenu as NSMenuMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method Cocoa Menus MBS MacBase Plugin 14.0 Yes Yes Yes Yes No
Function: Returns the window menu if one is registered.

Feedback, Comments & Corrections

The items on this page are in the following plugins: MBS MacBase Plugin.




Links
MBS FileMaker Plugins