|
WebObjects 5.2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.webobjects.eoapplication.EOUserInterfaceParameters
EOUserInterfaceParameters has many static methods used to localize strings and icons and to determine several aspects (fonts, colors, border sizes) of the user interface.
The methods to retrieve localized and platform-specific strings and images use a resource
bundle which you can set with setStandardResourceBundle
. Unless you specify your
own custom resource bundle, an instance of EODefaultResourceBundle is used to load resources
from the server.
EOUserInterfaceParameters also has various methods to set and get fonts, colors and border sizes which are used by controllers while they dynamically generate elements of the user interface. So you can widely modify the look of the application by invoking a few set methods on EOUserInterfaceParameters as long as you use dynamic user interface generation (Direct to Java Client).
standardResourceBundle()
,
EODefaultResourceBundle
Field Summary | |
static String |
OptimizeForMacKey
|
Constructor Summary | |
EOUserInterfaceParameters()
|
Method Summary | |
static Font |
actionTitleFont()
Returns the font used for large-size action buttons. |
static int |
actionTitlePosition()
Returns the title position in large-size action buttons. |
static boolean |
activateWindowsDelayed()
Returns whether windows should be activated delayed at the end of an event. |
static boolean |
allowActionIcons()
Returns whether large-size action buttons should use icons or not (if icons are available). |
static boolean |
allowSmallActionIcons()
Returns whether small-size action buttons should use icons or not (if icons are available). |
static Color |
disabledTextBackgroundColor()
Returns the color used for the background of disabled text fields. |
static Color |
editableTextBackgroundColor()
Returns the color used for the background of editable text fields. |
static boolean |
enableSaveOnlyIfEdited()
Returns whether Save actions should only be enabled if a document is edited. |
static Color |
highlightLabelColor()
Returns the color used for highlighted labels (in front of widgets). |
static Font |
highlightLabelFont()
Returns the font used for highlighted labels (in front of widgets). |
static Color |
highlightTitleColor()
Returns the color used for highlighted titles, for example in boxes and tab views. |
static Font |
highlightTitleFont()
Returns the font used for highlighted titles, for example in boxes and tab views. |
static Color |
labelColor()
Returns the color used for labels (in front of widgets). |
static int |
labelDistance()
Returns the distance between labels and widgets used by the default controller layout mechanisms. |
static Font |
labelFont()
Returns the font used for labels (in front of widgets). |
static int |
largeBorder()
Returns the large border size used by the default controller layout mechanisms. |
static Icon |
localizedIcon(String iconName)
Returns a localized version of the icon named iconName or
null if no icon can be found with the specified name. |
static String |
localizedString(String string)
Returns a localized version of string or string
itself if no localized version can be found. |
static boolean |
makeIconBackgroundsTransparent()
Returns whether the background of all icons loaded through the default resource bundle should be made explicitly transparent. |
static int |
mediumBorder()
Returns the medium border size used by the default controller layout mechanisms. |
static Dimension |
minimumActionButtonSize()
Returns the minimum size of large-size action buttons. |
static Dimension |
minimumSmallActionButtonSize()
Returns the minimum size of small-size action buttons. |
static Dimension |
minimumSpecialActionButtonSize()
Returns the minimum size of special action buttons used as integration components for controllers activated by buttons. |
static void |
optimizeForMac()
|
static boolean |
optimizeMenuAccelerators()
Returns whether standard menu accelerators like Command-n (new), Command-o (open) should be constantly updated to affect the active type of document (object). |
static Color |
queryTextBackgroundColor()
Returns the color used for the background of query text fields. |
static void |
setActionTitleFont(Font font)
Sets the font used for large-size action buttons. |
static void |
setActionTitlePosition(int position)
Sets the title position in large-size action buttons. |
static void |
setActivateWindowsDelayed(boolean flag)
Sets whether windows should be activated delayed at the end of an event. |
static void |
setAllowActionIcons(boolean flag)
Sets whether large-size action buttons should use icons or not (if icons are available). |
static void |
setAllowSmallActionIcons(boolean flag)
Sets whether small-size action buttons should use icons or not (if icons are available). |
static void |
setDisabledTextBackgroundColor(Color color)
Sets the color used for the background of disabled text fields. |
static void |
setEditableTextBackgroundColor(Color color)
Sets the color used for the background of editable text fields. |
static void |
setEnableSaveOnlyIfEdited(boolean flag)
Sets whether Save actions should only be enabled if a document is edited. |
static void |
setHighlightLabelColor(Color color)
Sets the color used for highlighted labels (in front of widgets). |
static void |
setHighlightLabelFont(Font font)
Sets the font used for highlighted labels (in front of widgets). |
static void |
setHighlightTitleColor(Color color)
Sets the color used for highlighted titles, for example in boxes and tab views. |
static void |
setHighlightTitleFont(Font font)
Sets the font used for highlighted titles, for example in boxes and tab views. |
static void |
setLabelColor(Color color)
Sets the color used for labels (in front of widgets). |
static void |
setLabelDistance(int distance)
Sets the distance between labels and widgets used by the default controller layout mechanisms. |
static void |
setLabelFont(Font font)
Sets the font used for labels (in front of widgets). |
static void |
setLargeBorder(int border)
Sets the large border size used by the default controller layout mechanisms. |
static void |
setMakeIconBackgroundsTransparent(boolean flag)
Sets whether the background of all icons loaded through the default resource bundle should be made explicitly transparent. |
static void |
setMediumBorder(int border)
Sets the medium border size used by the default controller layout mechanisms. |
static void |
setMinimumActionButtonSize(Dimension size)
Sets the minimum size of large-size action buttons. |
static void |
setMinimumSmallActionButtonSize(Dimension size)
Sets the minimum size of small-size action buttons. |
static void |
setMinimumSpecialActionButtonSize(Dimension size)
Sets the minimum size of small-size of special action buttons used as integration components for controllers activated by buttons. |
static void |
setOptimizeMenuAccelerators(boolean flag)
Sets whether standard menu accelerators like Command-n (new), Command-o (open) should be constantly updated to affect the active type of document (object). |
static void |
setQueryTextBackgroundColor(Color color)
Sets the color used for the background of query text fields. |
static void |
setShowDefaultDocumentActionsInWindows(boolean flag)
Sets whether the default document actions like Save and Revert should be shown with explicit buttons in document windows. |
static void |
setSmallActionTitleFont(Font font)
Sets the font used for small-size action buttons. |
static void |
setSmallActionTitlePosition(int position)
Sets the title position in small-size action buttons. |
static void |
setSmallBorder(int border)
Sets the small border size used by the default controller layout mechanisms. |
static void |
setSpecialActionTitleFont(Font font)
Sets the font used for special action buttons with icons. |
static void |
setSpecialActionTitlePosition(int position)
Sets the title position in the special action buttons used as integration components for controllers activated by buttons. |
static void |
setSpecialTextOnlyActionTitleFont(Font font)
Sets the font used for special action buttons without icons (text only). |
static void |
setStandardResourceBundle(ResourceBundle resourceBundle)
Sets the resource bundle used by the methods on EOUserInterfaceParameters to retrieve localized and platform specific resources. |
static void |
setTitleColor(Color color)
Sets the color used for titles, for example in boxes and tab views. |
static void |
setTitleFont(Font font)
Sets the font used for titles, for example in boxes and tab views. |
static void |
setUseBorderWithActionIcons(boolean flag)
Sets whether large-size action buttons with icons use borders or not. |
static void |
setUseBorderWithSmallActionIcons(boolean flag)
Sets whether small-size action buttons with icons use borders or not. |
static void |
setUseSpecialColors(boolean flag)
Sets whether widgets generated dynamically by controllers use the colors specified in EOUserInterfaceParameters or not. |
static void |
setUseSpecialFonts(boolean flag)
Sets whether widgets generated dynamically by controllers use the fonts specified in EOUserInterfaceParameters or not. |
static void |
setUseTitleWithActionIcons(boolean flag)
Sets whether large-size action buttons with icons also display titles or not. |
static void |
setUseTitleWithSmallActionIcons(boolean flag)
Sets whether small-size action buttons with icons also display titles or not. |
static void |
setUseWindowMenus(boolean flag)
Sets whether all windows (frames) of the application should show the standard application actions menu. |
static void |
setWidgetFont(Font font)
Sets the font used for normal input widgets, for example text fields. |
static boolean |
showDefaultDocumentActionsInWindows()
Returns whether the default document actions like Save and Revert should be shown with explicit buttons in document windows. |
static Font |
smallActionTitleFont()
Returns the font used for small-size action buttons. |
static int |
smallActionTitlePosition()
Returns the title position in small-size action buttons. |
static int |
smallBorder()
Returns the small border size used by the default controller layout mechanisms. |
static Font |
specialActionTitleFont()
Returns the font used for special action buttons with icons. |
static int |
specialActionTitlePosition()
Returns the title position in the special action buttons used as integration components for controllers activated by buttons. |
static Font |
specialTextOnlyActionTitleFont()
Returns the font used for special action buttons without icons (text only). |
static Icon |
standardActionIcon(String actionName)
Returns a localized version of a large-size icon representing the action actionName (for example "save") or null
if no icon for the action can be found. |
static ResourceBundle |
standardResourceBundle()
Returns the resource bundle used by the methods on EOUserInterfaceParameters to retrieve localized and platform specific resources. |
static Icon |
standardSmallActionIcon(String actionName)
Returns a localized version of a small-size icon representing the action actionName (for example "save") or null
if no icon for the action can be found. |
static Color |
titleColor()
Returns the color used for titles, for example in boxes and tab views. |
static Font |
titleFont()
Returns the font used for titles, for example in boxes and tab views. |
static boolean |
useBorderWithActionIcons()
Returns whether large-size action buttons with icons use borders or not. |
static boolean |
useBorderWithSmallActionIcons()
Returns whether small-size action buttons with icons use borders or not. |
static boolean |
useSpecialColors()
Returns whether widgets generated dynamically by controllers use the colors specified in EOUserInterfaceParameters or not. |
static boolean |
useSpecialFonts()
Returns whether widgets generated dynamically by controllers use the fonts specified in EOUserInterfaceParameters or not. |
static boolean |
useTitleWithActionIcons()
Returns whether large-size action buttons with icons also display titles or not. |
static boolean |
useTitleWithSmallActionIcons()
Returns whether small-size action buttons with icons also display titles or not. |
static boolean |
useWindowMenus()
Returns whether all windows (frames) of the application should show the standard application actions menu. |
static Font |
widgetFont()
Returns the font used for normal input widgets, for example text fields. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final String OptimizeForMacKey
Constructor Detail |
public EOUserInterfaceParameters()
Method Detail |
public static Font actionTitleFont()
public static int actionTitlePosition()
EOComponentController.Bottom
.public static boolean activateWindowsDelayed()
true
.true
if windows should be activated delayed at the end of an event;
false
otherwisepublic static boolean allowActionIcons()
true
.true
if large-size action buttons should use icons; false
otherwisepublic static boolean allowSmallActionIcons()
true
.true
if small-size action buttons should use icons; false
otherwisepublic static Color disabledTextBackgroundColor()
public static Color editableTextBackgroundColor()
public static boolean enableSaveOnlyIfEdited()
true
.true
if Save actions should only be enabled
if a document is edited; false
otherwisepublic static Color highlightLabelColor()
public static Font highlightLabelFont()
public static Color highlightTitleColor()
public static Font highlightTitleFont()
public static Color labelColor()
public static int labelDistance()
public static Font labelFont()
public static int largeBorder()
public static Icon localizedIcon(String iconName)
iconName
or
null
if no icon can be found with the specified name.iconName
- the name of the localized icon to loadnull
if no icon can be found with the specified namepublic static String localizedString(String string)
string
or string
itself if no localized version can be found.string
- the string to localizepublic static boolean makeIconBackgroundsTransparent()
false
.true
if icon backgrounds should be made explicitly transparent;
false
otherwisepublic static int mediumBorder()
public static Dimension minimumActionButtonSize()
public static Dimension minimumSmallActionButtonSize()
public static Dimension minimumSpecialActionButtonSize()
public static void optimizeForMac()
public static boolean optimizeMenuAccelerators()
true
.true
if standard menu accelerators should be updated
based on the active type of document; false
otherwise.public static Color queryTextBackgroundColor()
public static void setActionTitleFont(Font font)
font
- the font used for large-size action buttonspublic static void setActionTitlePosition(int position)
EOComponentController.Bottom
.position
- the position of titles in large-size action buttonspublic static void setActivateWindowsDelayed(boolean flag)
true
.flag
- true
if windows should be activated delayed at the end of an event;
false
otherwisepublic static void setAllowActionIcons(boolean flag)
true
.flag
- true
if large-size action buttons should use icons; false
otherwisepublic static void setAllowSmallActionIcons(boolean flag)
flag
- true
if small-size action buttons should use icons; false
otherwisepublic static void setDisabledTextBackgroundColor(Color color)
color
- the color used for the background of disabled text fieldspublic static void setEditableTextBackgroundColor(Color color)
color
- the color used for the background of editable text fieldspublic static void setEnableSaveOnlyIfEdited(boolean flag)
true
.flag
- true
if Save actions should only be enabled
if a document is edited; false
otherwisepublic static void setHighlightLabelColor(Color color)
color
- the color used for highlighted labelspublic static void setHighlightLabelFont(Font font)
font
- the font used for highlighted labelspublic static void setHighlightTitleColor(Color color)
color
- the color used for highlighted titlespublic static void setHighlightTitleFont(Font font)
font
- the font used for highlighted titlespublic static void setLabelColor(Color color)
color
- the color used for labelspublic static void setLabelDistance(int distance)
distance
- the distance between labels and widgets used by the default controller layout mechanismspublic static void setLabelFont(Font font)
font
- the font used for labelspublic static void setLargeBorder(int border)
border
- the large border size used by the default controller layout mechanismspublic static void setMakeIconBackgroundsTransparent(boolean flag)
false
.flag
- true
if icon backgrounds should be made explicitly transparent;
false
otherwisepublic static void setMediumBorder(int border)
border
- the medium border size used by the default controller layout mechanismspublic static void setMinimumActionButtonSize(Dimension size)
size
- the minimum size of large-size action buttonspublic static void setMinimumSmallActionButtonSize(Dimension size)
size
- the minimum size of small-size action buttonspublic static void setMinimumSpecialActionButtonSize(Dimension size)
size
- the minimum size of special action buttonspublic static void setOptimizeMenuAccelerators(boolean flag)
true
.flag
- true
if standard menu accelerators should be updated
based on the active type of document; false
otherwisepublic static void setQueryTextBackgroundColor(Color color)
color
- the color used for the background of query text fieldspublic static void setShowDefaultDocumentActionsInWindows(boolean flag)
true
.flag
- true
if the default document actions should be shown
with explicit buttons in document windows; false
otherwisepublic static void setSmallActionTitleFont(Font font)
font
- the font used for small-size action buttonspublic static void setSmallActionTitlePosition(int position)
EOComponentController.Right
.position
- the position of titles in small-size action buttonspublic static void setSmallBorder(int border)
border
- the small border size used by the default controller layout mechanismspublic static void setSpecialActionTitleFont(Font font)
font
- the font used for special action buttons with iconspublic static void setSpecialActionTitlePosition(int position)
EOComponentController.Right
.position
- the position of titles in special action buttonspublic static void setSpecialTextOnlyActionTitleFont(Font font)
font
- the font used for special action buttons without iconspublic static void setStandardResourceBundle(ResourceBundle resourceBundle)
resourceBundle
- the resource bundle used to retrieve localized and platform specific resourcespublic static void setTitleColor(Color color)
color
- the color used for titlespublic static void setTitleFont(Font font)
font
- the font used for titlespublic static void setUseBorderWithActionIcons(boolean flag)
false
on Mac OS X and true
on all other platforms.flag
- true
if large-size action buttons with icons use borders; false
otherwisepublic static void setUseBorderWithSmallActionIcons(boolean flag)
false
on Mac OS X and true
on all other platforms.flag
- true
if small-size action buttons with icons use borders; false
otherwisepublic static void setUseSpecialColors(boolean flag)
false
,
but the EODynamicApplication class used for Direct to Java Client sets it to
true
at startup time.flag
- true
if dynamically generated widgets should use the colors
specified in EOUserInterfaceParameters; false
otherwisepublic static void setUseSpecialFonts(boolean flag)
false
,
but the EODynamicApplication class used for Direct to Java Client sets it to
true
at startup time.flag
- true
if dynamically generated widgets should use the fonts
specified in EOUserInterfaceParameters; false
otherwisepublic static void setUseTitleWithActionIcons(boolean flag)
true
.flag
- true
if large-size action buttons with icons also display titles;
false
otherwisepublic static void setUseTitleWithSmallActionIcons(boolean flag)
true
.flag
- true
if small-size action buttons with icons also display titles;
false
otherwisepublic static void setUseWindowMenus(boolean flag)
true
.flag
- true
if all frames should show the standard application actions menu;
false
otherwisepublic static void setWidgetFont(Font font)
font
- the font used for normal input widgetspublic static boolean showDefaultDocumentActionsInWindows()
true
.true
if the default document actions should be shown
with explicit buttons in document windows; false
otherwisepublic static Font smallActionTitleFont()
public static int smallActionTitlePosition()
EOComponentController.Right
.public static int smallBorder()
public static Font specialActionTitleFont()
public static int specialActionTitlePosition()
EOComponentController.Right
.public static Font specialTextOnlyActionTitleFont()
public static Icon standardActionIcon(String actionName)
actionName
(for example "save") or null
if no icon for the action can be found. The name of the icon looked up
is derived from the action name as "ActionIconactionName
- the name of the actionnull
if no icon can be found for the actionpublic static ResourceBundle standardResourceBundle()
public static Icon standardSmallActionIcon(String actionName)
actionName
(for example "save") or null
if no icon for the action can be found. The name of the icon looked up
is derived from the action name as "SmallActionIconactionName
- the name of the actionnull
if no icon can be found for the actionpublic static Color titleColor()
public static Font titleFont()
public static boolean useBorderWithActionIcons()
false
on Mac OS X and true
on all other platforms.true
if large-size action buttons with icons use borders; false
otherwisepublic static boolean useBorderWithSmallActionIcons()
false
on Mac OS X and true
on all other platforms.true
if small-size action buttons with icons use borders; false
otherwisepublic static boolean useSpecialColors()
false
,
but the EODynamicApplication class used for Direct to Java Client sets it to
true
at startup time.true
if dynamically generated widgets should use the colors
specified in EOUserInterfaceParameters; false
otherwisepublic static boolean useSpecialFonts()
false
,
but the EODynamicApplication class used for Direct to Java Client sets it to
true
at startup time.true
if dynamically generated widgets should use the fonts
specified in EOUserInterfaceParameters; false
otherwisepublic static boolean useTitleWithActionIcons()
true
.true
if large-size action buttons with icons also display titles;
false
otherwisepublic static boolean useTitleWithSmallActionIcons()
true
.true
if small-size action buttons with icons also display titles;
false
otherwisepublic static boolean useWindowMenus()
true
.true
if all frames should show the standard application actions menu;
false
otherwisepublic static Font widgetFont()
|
Last updated Fri Feb 21 13:15:00 PST 2003. | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |