(informal protocol)
Framework | /System/Library/Frameworks/AppKit.framework |
Companion guide | |
Declared in | NSFontPanel.h |
Informal protocol. The Font Panel can be explicitly ordered to display some or all of its elements by responding to the validModesForFontPanel:
instance method.
Returns the mode mask corresponding to the expected font panel mode.
- (NSUInteger)validModesForFontPanel:(NSFontPanel *)fontPanel
The mode masks are defined in Mode Masks
.
The Font Panel has the ability to hide elements that are not applicable for a given context by having the target respond to validModesForFontPanel:
. If the target desires a font panel mode other than the standard mode mask, it must respond to this method.
This message is sent up the responder chain to the first responder implementing the method. Ideally that object should be the first responder found that also implements changeFont:
.
NSFontPanel.h
The following constants correspond to the available font panel mode masks returned by validModesForFontPanel:
.
enum { NSFontPanelFaceModeMask = 1 << 0, NSFontPanelSizeModeMask = 1 << 1, NSFontPanelCollectionModeMask = 1 << 2, NSFontPanelUnderlineEffectModeMask = 1<<8, NSFontPanelStrikethroughEffectModeMask = 1<<9, NSFontPanelTextColorEffectModeMask = 1<< 10, NSFontPanelDocumentColorEffectModeMask = 1<<11, NSFontPanelShadowEffectModeMask = 1<<12, NSFontPanelAllEffectsModeMask = 0XFFF00, NSFontPanelStandardModesMask = 0xFFFF, NSFontPanelAllModesMask = 0xFFFFFFFF };
NSFontPanelFaceModeMask
Display the typeface column.
Available in Mac OS X v10.3 and later.
Declared in NSFontPanel.h
.
NSFontPanelSizeModeMask
Display the font size column.
Available in Mac OS X v10.3 and later.
Declared in NSFontPanel.h
.
NSFontPanelCollectionModeMask
Display the font collections column.
Available in Mac OS X v10.3 and later.
Declared in NSFontPanel.h
.
NSFontPanelUnderlineEffectModeMask
Display the underline popup menu.
Available in Mac OS X v10.4 and later.
Declared in NSFontPanel.h
.
NSFontPanelStrikethroughEffectModeMask
Display the strike-through popup menu.
Available in Mac OS X v10.4 and later.
Declared in NSFontPanel.h
.
NSFontPanelTextColorEffectModeMask
Display the text color button.
Available in Mac OS X v10.4 and later.
Declared in NSFontPanel.h
.
NSFontPanelDocumentColorEffectModeMask
Display the document color button.
Available in Mac OS X v10.4 and later.
Declared in NSFontPanel.h
.
NSFontPanelShadowEffectModeMask
Display the shadow effects button.
Available in Mac OS X v10.4 and later.
Declared in NSFontPanel.h
.
NSFontPanelAllEffectsModeMask
Display all the effects user interface items.
Available in Mac OS X v10.4 and later.
Declared in NSFontPanel.h
.
NSFontPanelStandardModesMask
Display the standard default font panel—that is, including the collections, typeface, and size columns.
Available in Mac OS X v10.3 and later.
Declared in NSFontPanel.h
.
NSFontPanelAllModesMask
Display all the available adornments.
Available in Mac OS X v10.3 and later.
Declared in NSFontPanel.h
.
NSFontPanel.h
© 2007 Apple Inc. All Rights Reserved. (Last updated: 2007-04-06)