Interface FlatClientProperties
-
public interface FlatClientProperties
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
BUTTON_TYPE
Specifies type of a button.static java.lang.String
BUTTON_TYPE_HELP
Paint a help button (circle with question mark).static java.lang.String
BUTTON_TYPE_ROUND_RECT
Paint the button with round edges.static java.lang.String
BUTTON_TYPE_SQUARE
Paint the button with square edges.static java.lang.String
BUTTON_TYPE_TAB
Paint the toggle button in tab style.static java.lang.String
BUTTON_TYPE_TOOLBAR_BUTTON
Paint the button in toolbar style.static java.lang.String
COMPONENT_ROUND_RECT
Paint the component with round edges.static java.lang.String
MENU_BAR_EMBEDDED
Specifies whether the menu bar is embedded into the title pane if custom window decorations are enabled.static java.lang.String
MINIMUM_HEIGHT
Specifies minimum height of a component.static java.lang.String
MINIMUM_WIDTH
Specifies minimum width of a component.static java.lang.String
OUTLINE
Specifies the outline color of the component border.static java.lang.String
OUTLINE_ERROR
Paint the component border in another color (usually reddish) to indicate an error.static java.lang.String
OUTLINE_WARNING
Paint the component border in another color (usually yellowish) to indicate a warning.static java.lang.String
PLACEHOLDER_TEXT
Placeholder text that is only painted if the text field is empty.static java.lang.String
POPUP_DROP_SHADOW_PAINTED
Specifies whether a drop shadow is painted if the component is shown in a popup or if the component is the owner of another component that is shown in a popup.static java.lang.String
PROGRESS_BAR_LARGE_HEIGHT
Specifies whether the progress bar has always the larger height even if no string is painted.static java.lang.String
PROGRESS_BAR_SQUARE
Specifies whether the progress bar is paint with square edges.static java.lang.String
SCROLL_BAR_SHOW_BUTTONS
Specifies whether the decrease/increase arrow buttons of a scrollbar are shown.static java.lang.String
SCROLL_PANE_SMOOTH_SCROLLING
Specifies whether the scroll pane uses smooth scrolling.static java.lang.String
SELECT_ALL_ON_FOCUS_POLICY
Specifies whether all text is selected when the text component gains focus.static java.lang.String
SELECT_ALL_ON_FOCUS_POLICY_ALWAYS
Always select all text when the text component gains focus.static java.lang.String
SELECT_ALL_ON_FOCUS_POLICY_NEVER
Never select all text when the text component gains focus.static java.lang.String
SELECT_ALL_ON_FOCUS_POLICY_ONCE
Select all text when the text component gains focus for the first time and selection was not modified (is at end of text).static java.lang.String
SELECTED_STATE
Specifies selected state of a checkbox.static java.lang.String
SELECTED_STATE_INDETERMINATE
Paint an indeterminate state on a checkbox.static java.lang.String
SQUARE_SIZE
Specifies whether the button preferred size will be made square (quadratically).static java.lang.String
TAB_BUTTON_SELECTED_BACKGROUND
Background color if selected and toggle button type isBUTTON_TYPE_TAB
.static java.lang.String
TAB_BUTTON_UNDERLINE_COLOR
Color of underline if toggle button type isBUTTON_TYPE_TAB
.static java.lang.String
TAB_BUTTON_UNDERLINE_HEIGHT
Height of underline if toggle button type isBUTTON_TYPE_TAB
.static java.lang.String
TABBED_PANE_HAS_FULL_BORDER
Specifies whether a full border is painted around a tabbed pane.static java.lang.String
TABBED_PANE_SHOW_TAB_SEPARATORS
Specifies whether separators are shown between tabs.static java.lang.String
TABBED_PANE_TAB_HEIGHT
Specifies the height of a tab.
-
Method Summary
Static Methods Modifier and Type Method Description static boolean
clientPropertyBoolean(javax.swing.JComponent c, java.lang.String key, boolean defaultValue)
Checks whether a client property of a component is a boolean and returns its value.static java.lang.Boolean
clientPropertyBooleanStrict(javax.swing.JComponent c, java.lang.String key, java.lang.Boolean defaultValue)
Checks whether a client property of a component is aBoolean
and returns its value.static int
clientPropertyChoice(javax.swing.JComponent c, java.lang.String key, java.lang.String... choices)
static java.awt.Color
clientPropertyColor(javax.swing.JComponent c, java.lang.String key, java.awt.Color defaultValue)
Checks whether a client property of a component is a color and returns its value.static boolean
clientPropertyEquals(javax.swing.JComponent c, java.lang.String key, java.lang.Object value)
Checks whether a client property of a component has the given value.static int
clientPropertyInt(javax.swing.JComponent c, java.lang.String key, int defaultValue)
Checks whether a client property of a component is an integer and returns its value.
-
-
-
Field Detail
-
BUTTON_TYPE
static final java.lang.String BUTTON_TYPE
Specifies type of a button.Components
JButton
andJToggleButton
Value typeString
Allowed ValuesBUTTON_TYPE_SQUARE
,BUTTON_TYPE_ROUND_RECT
,BUTTON_TYPE_TAB
,BUTTON_TYPE_HELP
andBUTTON_TYPE_TOOLBAR_BUTTON
- See Also:
- Constant Field Values
-
BUTTON_TYPE_SQUARE
static final java.lang.String BUTTON_TYPE_SQUARE
Paint the button with square edges.Components
JButton
andJToggleButton
- See Also:
BUTTON_TYPE
, Constant Field Values
-
BUTTON_TYPE_ROUND_RECT
static final java.lang.String BUTTON_TYPE_ROUND_RECT
Paint the button with round edges.Components
JButton
andJToggleButton
- See Also:
BUTTON_TYPE
, Constant Field Values
-
BUTTON_TYPE_TAB
static final java.lang.String BUTTON_TYPE_TAB
Paint the toggle button in tab style.Components
JToggleButton
- See Also:
BUTTON_TYPE
, Constant Field Values
-
BUTTON_TYPE_HELP
static final java.lang.String BUTTON_TYPE_HELP
Paint a help button (circle with question mark).Components
JButton
- See Also:
BUTTON_TYPE
, Constant Field Values
-
BUTTON_TYPE_TOOLBAR_BUTTON
static final java.lang.String BUTTON_TYPE_TOOLBAR_BUTTON
Paint the button in toolbar style.Components
JButton
andJToggleButton
- See Also:
BUTTON_TYPE
, Constant Field Values
-
SELECTED_STATE
static final java.lang.String SELECTED_STATE
Specifies selected state of a checkbox.Component
JCheckBox
Value typeString
Allowed ValuesSELECTED_STATE_INDETERMINATE
- See Also:
- Constant Field Values
-
SELECTED_STATE_INDETERMINATE
static final java.lang.String SELECTED_STATE_INDETERMINATE
Paint an indeterminate state on a checkbox.- See Also:
SELECTED_STATE
, Constant Field Values
-
SQUARE_SIZE
static final java.lang.String SQUARE_SIZE
Specifies whether the button preferred size will be made square (quadratically).Components
JButton
andJToggleButton
Value typeBoolean
- See Also:
- Constant Field Values
-
MINIMUM_WIDTH
static final java.lang.String MINIMUM_WIDTH
Specifies minimum width of a component.Component
JButton
,JToggleButton
,JComboBox
,JSpinner
andJTextComponent
Value typeInteger
- See Also:
- Constant Field Values
-
MINIMUM_HEIGHT
static final java.lang.String MINIMUM_HEIGHT
Specifies minimum height of a component.Component
JButton
andJToggleButton
Value typeInteger
- See Also:
- Constant Field Values
-
OUTLINE
static final java.lang.String OUTLINE
Specifies the outline color of the component border.Components
JButton
,JComboBox
,JFormattedTextField
,JPasswordField
,JScrollPane
,JSpinner
,JTextField
andJToggleButton
Value typeString
orColor
orColor
[2]
Allowed ValuesOUTLINE_ERROR
,OUTLINE_WARNING
, any color (typeColor
) or an array of two colors (typeColor
[2]) where the first color is for focused state and the second for unfocused state- See Also:
- Constant Field Values
-
OUTLINE_ERROR
static final java.lang.String OUTLINE_ERROR
Paint the component border in another color (usually reddish) to indicate an error.- See Also:
OUTLINE
, Constant Field Values
-
OUTLINE_WARNING
static final java.lang.String OUTLINE_WARNING
Paint the component border in another color (usually yellowish) to indicate a warning.- See Also:
OUTLINE
, Constant Field Values
-
COMPONENT_ROUND_RECT
static final java.lang.String COMPONENT_ROUND_RECT
Paint the component with round edges.Components
JComboBox
,JSpinner
,JTextField
,JFormattedTextField
andJPasswordField
Value typeBoolean
- See Also:
- Constant Field Values
-
POPUP_DROP_SHADOW_PAINTED
static final java.lang.String POPUP_DROP_SHADOW_PAINTED
Specifies whether a drop shadow is painted if the component is shown in a popup or if the component is the owner of another component that is shown in a popup.Component
JComponent
Value typeBoolean
- See Also:
- Constant Field Values
-
PROGRESS_BAR_LARGE_HEIGHT
static final java.lang.String PROGRESS_BAR_LARGE_HEIGHT
Specifies whether the progress bar has always the larger height even if no string is painted.Component
JProgressBar
Value typeBoolean
- See Also:
- Constant Field Values
-
PROGRESS_BAR_SQUARE
static final java.lang.String PROGRESS_BAR_SQUARE
Specifies whether the progress bar is paint with square edges.Component
JProgressBar
Value typeBoolean
- See Also:
- Constant Field Values
-
MENU_BAR_EMBEDDED
static final java.lang.String MENU_BAR_EMBEDDED
Specifies whether the menu bar is embedded into the title pane if custom window decorations are enabled. Default istrue
.Component
JRootPane
Value typeBoolean
- See Also:
- Constant Field Values
-
SCROLL_BAR_SHOW_BUTTONS
static final java.lang.String SCROLL_BAR_SHOW_BUTTONS
Specifies whether the decrease/increase arrow buttons of a scrollbar are shown.Component
JScrollBar
orJScrollPane
Value typeBoolean
- See Also:
- Constant Field Values
-
SCROLL_PANE_SMOOTH_SCROLLING
static final java.lang.String SCROLL_PANE_SMOOTH_SCROLLING
Specifies whether the scroll pane uses smooth scrolling.Component {
JScrollPane
Value typeBoolean
- See Also:
- Constant Field Values
-
TABBED_PANE_SHOW_TAB_SEPARATORS
static final java.lang.String TABBED_PANE_SHOW_TAB_SEPARATORS
Specifies whether separators are shown between tabs.Component
JTabbedPane
Value typeBoolean
- See Also:
- Constant Field Values
-
TABBED_PANE_HAS_FULL_BORDER
static final java.lang.String TABBED_PANE_HAS_FULL_BORDER
Specifies whether a full border is painted around a tabbed pane.Component
JTabbedPane
Value typeBoolean
- See Also:
- Constant Field Values
-
TABBED_PANE_TAB_HEIGHT
static final java.lang.String TABBED_PANE_TAB_HEIGHT
Specifies the height of a tab.Component
JTabbedPane
Value typeInteger
- See Also:
- Constant Field Values
-
SELECT_ALL_ON_FOCUS_POLICY
static final java.lang.String SELECT_ALL_ON_FOCUS_POLICY
Specifies whether all text is selected when the text component gains focus.Component
JTextField
(and subclasses)
Value typeString
Allowed ValuesSELECT_ALL_ON_FOCUS_POLICY_NEVER
,SELECT_ALL_ON_FOCUS_POLICY_ONCE
(default) orSELECT_ALL_ON_FOCUS_POLICY_ALWAYS
- See Also:
- Constant Field Values
-
SELECT_ALL_ON_FOCUS_POLICY_NEVER
static final java.lang.String SELECT_ALL_ON_FOCUS_POLICY_NEVER
Never select all text when the text component gains focus.- See Also:
SELECT_ALL_ON_FOCUS_POLICY
, Constant Field Values
-
SELECT_ALL_ON_FOCUS_POLICY_ONCE
static final java.lang.String SELECT_ALL_ON_FOCUS_POLICY_ONCE
Select all text when the text component gains focus for the first time and selection was not modified (is at end of text). This is the default.- See Also:
SELECT_ALL_ON_FOCUS_POLICY
, Constant Field Values
-
SELECT_ALL_ON_FOCUS_POLICY_ALWAYS
static final java.lang.String SELECT_ALL_ON_FOCUS_POLICY_ALWAYS
Always select all text when the text component gains focus.- See Also:
SELECT_ALL_ON_FOCUS_POLICY
, Constant Field Values
-
PLACEHOLDER_TEXT
static final java.lang.String PLACEHOLDER_TEXT
Placeholder text that is only painted if the text field is empty.Component
JTextField
(and subclasses) orJComboBox
Value typeString
- See Also:
- Constant Field Values
-
TAB_BUTTON_UNDERLINE_HEIGHT
static final java.lang.String TAB_BUTTON_UNDERLINE_HEIGHT
Height of underline if toggle button type isBUTTON_TYPE_TAB
.Component
JToggleButton
Value typeInteger
- See Also:
- Constant Field Values
-
TAB_BUTTON_UNDERLINE_COLOR
static final java.lang.String TAB_BUTTON_UNDERLINE_COLOR
Color of underline if toggle button type isBUTTON_TYPE_TAB
.Component
JToggleButton
Value typeColor
- See Also:
- Constant Field Values
-
TAB_BUTTON_SELECTED_BACKGROUND
static final java.lang.String TAB_BUTTON_SELECTED_BACKGROUND
Background color if selected and toggle button type isBUTTON_TYPE_TAB
.Component
JToggleButton
Value typeColor
- See Also:
- Constant Field Values
-
-
Method Detail
-
clientPropertyEquals
static boolean clientPropertyEquals(javax.swing.JComponent c, java.lang.String key, java.lang.Object value)
Checks whether a client property of a component has the given value.
-
clientPropertyBoolean
static boolean clientPropertyBoolean(javax.swing.JComponent c, java.lang.String key, boolean defaultValue)
Checks whether a client property of a component is a boolean and returns its value. If the client property is not set, or not a boolean, defaultValue is returned.
-
clientPropertyBooleanStrict
static java.lang.Boolean clientPropertyBooleanStrict(javax.swing.JComponent c, java.lang.String key, java.lang.Boolean defaultValue)
Checks whether a client property of a component is aBoolean
and returns its value. If the client property is not set, or not aBoolean
, defaultValue is returned.
-
clientPropertyInt
static int clientPropertyInt(javax.swing.JComponent c, java.lang.String key, int defaultValue)
Checks whether a client property of a component is an integer and returns its value. If the client property is not set, or not an integer, defaultValue is returned.
-
clientPropertyColor
static java.awt.Color clientPropertyColor(javax.swing.JComponent c, java.lang.String key, java.awt.Color defaultValue)
Checks whether a client property of a component is a color and returns its value. If the client property is not set, or not a color, defaultValue is returned.
-
clientPropertyChoice
static int clientPropertyChoice(javax.swing.JComponent c, java.lang.String key, java.lang.String... choices)
-
-