fontlab_glyport.ui.cocoa_menu
cocoa_menu
NSMenu/NSMenuItem as plain objects a host turns into QActions (R025).
Supports both construction styles the corpus uses:
NSMenuItem.alloc().initWithTitle_action_keyEquivalent_(title, "go:", "")
(50 uses) and GlyphsApp's NSMenuItem(title, callback, target=None,
keyboard=None, modifier=0) (30 uses). fire() performs the item: a
Python callable action is called with the item as sender (bound to
target when that is an object owning a method of that name), a selector
string is performed on target with its colon arity. state,
enabled, keyEquivalent and the modifier mask are kept for the host,
which observes changes through changed callbacks.
Classes
Complete member index
Every captured member retains its own identity. Identical captured declaration text is linked once; this does not establish native inheritance or interchangeable objects.
| Member | Kind | Signature | Summary |
|---|---|---|---|
NSAlternateKeyMask |
attribute | ||
NSCommandKeyMask |
attribute | ||
NSControlKeyMask |
attribute | ||
NSMixedState |
attribute | ||
NSOffState |
attribute | ||
NSOnState |
attribute | ||
NSShiftKeyMask |
attribute |