public interface Theme
The interface also contains a set of constants used by teh declared methods.
Modifier and Type | Field and Description |
---|---|
static int |
ALIGN_BOTTOM
Constant for bottom alignment on vertical (Oy) axe.
|
static int |
ALIGN_CENTER
Constant for center alignment on horizontal (Ox) axe.
|
static int |
ALIGN_LEFT
Constant for left alignment on horizontal (Ox) axe.
|
static int |
ALIGN_MIDDLE
Constant for middle alignment on vertical (Oy) axe.
|
static int |
ALIGN_NONE
The alignment is defined on both direction.
|
static int |
ALIGN_RIGHT
Constant for right alignment on horizontal (Ox) axe.
|
static int |
ALIGN_TOP
Constant for top alignment on vertical (Oy) axe.
|
static int |
HORIZONTAL_ALIGN_MASK
Constant used to extract the horizontal alignment from an alignment value.
|
static int |
VERTICAL_ALIGN_MASK
Constant used to extract the vertical alignment from an alignment value.
|
Modifier and Type | Method and Description |
---|---|
void |
draw3DBorder(ThreeDBorderGuiImpl border,
GuiDriver gd,
int x,
int y,
int width,
int height)
Draws a
ThreeDBorderGuiImpl widget. |
void |
drawAlertBox(GuiDriver gd,
int x,
int y,
int width,
int height,
int paragraphWidth,
ImageWrapper icon,
java.lang.String text,
FontDetails font)
Renders borders of a top-level window.
|
void |
drawBrowseColumnDrag(BrowseGuiImpl browse,
GuiDriver gd,
int x,
int y,
int width,
int height)
Draw animation of a dragged column in a
BrowseGuiImpl widget. |
void |
drawBrowseColumnLabel(BrowseColumnGuiImpl column,
GuiDriver gd,
int x,
int y,
int width,
int height,
FontDetails fontDetails)
Draw the label on a
BrowseColumnGuiImpl widget. |
void |
drawBrowseMarkersColumn(BrowseColumnGuiImpl column,
GuiDriver gd,
int x,
int y,
int width,
int height)
Draw a browse marker column
BrowseColumnGuiImpl widget (without label). |
void |
drawBrowseNormalColumn(BrowseColumnGuiImpl column,
GuiDriver gd,
int x,
int y,
int width,
int height)
Draw a normal column
BrowseColumnGuiImpl widget (without label). |
void |
drawBrowseResizingColumn(BrowseGuiImpl browse,
GuiDriver gd,
int left,
int top,
int right,
int bottom)
Draw animation of a dragged column in a
BrowseGuiImpl widget. |
void |
drawBrowseRowHighlight(BrowseGuiImpl browse,
GuiDriver gd,
int x,
int y,
int width,
int height)
Highlight the currently active row in a
BrowseGuiImpl widget. |
void |
drawBrowseTitlePanel(BrowseGuiImpl browse,
GuiDriver gd,
GuiColorResolver gc,
GuiFontResolver gf,
int x,
int y,
int width,
int height)
Draw the title panel of a
BrowseGuiImpl widget. |
void |
drawButton(ButtonGuiImpl button,
GuiDriver gd,
GuiColorResolver gc,
GuiFontResolver gf,
int x,
int y,
int width,
int height)
Renders borders of a top-level window.
|
void |
drawCaptionButton(CaptionButton button,
GuiDriver gd,
int x,
int y,
int width,
int height)
Renders a
CaptionButton . |
void |
drawComboBoxButton(ComboBoxGuiImpl combo,
GuiDriver gd,
int x,
int y,
int width,
int height,
boolean pressed,
boolean enabled,
boolean hover)
Renders the opening button of the combo box widget.
|
void |
drawComboBoxEntryField(ComboBoxGuiImpl combo,
GuiDriver gd,
GuiColorResolver gc,
int x,
int y,
int width,
int height,
FontDetails<?> font,
boolean pressed,
boolean enabled,
boolean hover)
Renders the entry field of a combo box.
|
void |
drawComboBoxFieldBorder(ComboBoxGuiImpl combo,
GuiDriver gd,
int x,
int y,
int width,
int height,
boolean pressed,
boolean enabled,
boolean hover)
Renders the border (and possibly the background) of the combo box widget.
|
void |
drawEditorCaret(EditorGuiImpl editor,
GuiDriver gd,
int x1,
int y1,
int x2,
int y2)
Renders caret of the editor widget.
|
void |
drawEditorContent(EditorGuiImpl editor,
GuiDriver gd,
GuiFontResolver gf,
GuiColorResolver gc,
int x,
int y,
int width,
int height,
NativePoint selStart,
NativePoint selEnd,
int dx,
int dy)
Renders the content of an
EditorGuiImpl widget. |
void |
drawFillInBorder(GuiDriver gd,
GuiColorResolver gc,
int x,
int y,
int width,
int height,
boolean border3D,
boolean hasFocus,
boolean hover)
Renders the border (and possibly the background) of the fill-in widget.
|
void |
drawFillInCaret(FillInGuiImpl fillIn,
GuiDriver gd,
int x1,
int y1,
int x2,
int y2)
Renders caret of the fill-in widget.
|
void |
drawFillInSelection(FillInGuiImpl fillIn,
GuiDriver gd,
int clipWidth,
int clipHeight,
int selX,
int selWidth,
int selHeight,
java.lang.String selTxt,
int font,
ColorRgb bgColor,
ColorRgb fgColor)
Renders the selection (and possibly its background) of the fill-in widget widget.
|
void |
drawFrameTitle(FrameGuiImpl frame,
GuiDriver gd,
GuiColorResolver gc,
GuiFontResolver gf,
int x,
int y,
int width,
int height)
Draw the title panel of a
BrowseGuiImpl widget. |
void |
drawLabel(LabelGuiImpl label,
GuiDriver gd,
GuiColorResolver gc,
GuiFontResolver gf,
int x,
int y,
int width,
int height,
boolean emptyMode)
Renders a label.
|
void |
drawLabelUnderline(GuiDriver gd,
int x,
int y,
int width,
int height,
ColorRgb fgColor)
Draw the horizontal bar under a label if the label is underlined.
|
void |
drawLineBorder(LineBorderGuiImpl border,
GuiDriver gd,
GuiColorResolver gc,
int x,
int y,
int width,
int height)
Draw the line border
LineBorderGuiImpl widget. |
void |
drawMenuBackground(GuiDriver gd,
int x,
int y,
int width,
int height,
boolean popup)
Renders the background of a menu widget.
|
void |
drawMenuBarElement(SubMenuGuiImpl menu,
GuiDriver gd,
GuiFontResolver gf,
int x,
int y,
int width,
int height,
boolean hover)
Draws an element of a menu in a menubar.
|
void |
drawMenuItemBackground(AbstractWidget item,
GuiDriver gd,
int x,
int y,
int width,
int height,
boolean hover)
Renders the background of an item in a menu widget.
|
void |
drawMenuItemContent(AbstractWidget item,
GuiDriver gd,
GuiFontResolver gf,
int x,
int y,
int width,
int height,
int textHeight,
boolean focused)
Renders the foreground content of menu item in a menu.
|
void |
drawMenuSeparator(GuiDriver gd,
int x,
int y,
int width,
int height)
Renders the separator line in a menu widget.
|
void |
drawRadioButton(RadioButtonGuiImpl rb,
GuiDriver gd,
GuiColorResolver gc,
GuiFontResolver gf,
int x,
int y,
int width,
int height,
boolean focused,
boolean hover)
Renders a GUI radio button widget.
|
void |
drawRectangle(RectangleGuiImpl rect,
GuiDriver gd,
GuiColorResolver gc,
int x,
int y,
int width,
int height)
Draws a
RectangleGuiImpl widget. |
void |
drawScrollBarButton(GuiDriver gd,
GuiColorResolver gc,
int x,
int y,
int width,
int height,
ScrollBar.Position pos,
boolean horizontal,
boolean enabled,
boolean pressed,
boolean highlighted)
Renders a button of the scrollbar widget.
|
void |
drawScrollBarGauge(GuiDriver gd,
GuiColorResolver gc,
int x,
int y,
int width,
int height,
boolean horizontal)
Renders the gauge (background) of the scrollbar widget.
|
void |
drawScrollBarThumb(GuiDriver gd,
GuiColorResolver gc,
int x,
int y,
int width,
int height,
boolean pressed,
boolean hover,
boolean horizontal)
Renders the thumb/slider of the scrollbar widget.
|
void |
drawSelectionFocus(GuiDriver gd,
int x,
int y,
int width,
int height)
Utility method for drawing a dotted rectangle using XOR operation.
|
void |
drawSelectionListBackground(GuiDriver gd,
GuiColorResolver gc,
int x,
int y,
int width,
int height)
Renders the background of a selection list.
|
void |
drawSelectionListItem(ComboBoxGuiImpl box,
GuiDriver gd,
GuiColorResolver gc,
int x,
int y,
int width,
int height,
java.lang.String text,
int fontSize,
boolean enabled,
boolean highlighted,
boolean selected)
Renders a single item in a combo box selection list.
|
void |
drawStatusBar(GuiDriver gd,
GuiColorResolver gc,
int x,
int y,
int width,
int height,
java.lang.String text,
GuiFontResolver.FontCache cache,
NativePoint txtOrig,
NativeDimension txtDim,
boolean resizable)
Renders the status bar of a top-level window.
|
void |
drawToggleBox(ToggleBoxGuiImpl checkbox,
GuiDriver gd,
GuiColorResolver gc,
GuiFontResolver gf,
int x,
int y,
int width,
int height,
boolean pressed,
boolean hover)
Renders a GUI toggle box widget.
|
void |
drawToolTip(GuiDriver gd,
int x,
int y,
int width,
int height,
FontDetails fnt,
java.lang.String text)
Draw a
ToolTip . |
void |
drawWindowBorder(GuiDriver gd,
int x,
int y,
int width,
int height,
NativeInsets border,
boolean active)
Renders borders of a top-level window.
|
void |
drawWindowTitle(GuiDriver gd,
GuiFontResolver gf,
int x,
int y,
int width,
int height,
java.lang.String title,
boolean active)
Renders the text on the titlebar of a top-level window.
|
void |
drawWindowTitleBar(GuiDriver gd,
int x,
int y,
int width,
int height,
boolean active)
Renders the background of the titlebar of a top-level window.
|
int |
get3DBorderOffset()
Obtain the offset in a 3D bordered widget.
|
int |
getAlertBoxPadding()
Obtain the padding for alert boxes.
|
int |
getCaptionButtonHeight(boolean maximized)
Returns the height of a caption button on window's title bar.
|
int |
getCaptionButtonsAlignment()
Get the alignment of caption button for this theme.
|
int |
getCaptionButtonWidth(CaptionButtonType type,
boolean dialog)
Returns the width of a caption button on window's title bar.
|
int |
getCheckBoxSize()
Obtain the size of image on a checkbox widget.
|
int |
getCheckBoxSpace()
Obtains the space needed by a checkbox widget.
|
int |
getComboBoxButtonSize()
Obtain the size of the button that opens the combo box.
|
int |
getComboBoxDropDownOffset()
Obtain the vertical distance between the combo box and the scrolling selection list.
|
int |
getComboBoxEntryShift()
Obtain the shifting distance in a combo box widget.
|
int |
getComboBoxFieldExtraSpace(boolean horiz,
boolean is3D)
Obtain the field extra space for combo box layout.
|
java.util.Map<java.lang.String,java.lang.String> |
getDefaultFontAliases()
Obtain the map of default font aliases specific to current
Theme , to which a key
defaults, if not overridden in the directory. |
java.util.Map<java.lang.Integer,ColorRgb> |
getDefaultSystemPalette()
Obtain the default system palette for this theme.
|
ImageWrapper |
getImage(java.lang.String name,
int width,
int height,
boolean antialias)
Obtain an image resource specific to this
Theme . |
int |
getMenuBarElementMinSize(boolean horiz)
Obtain the minimum size of a titlebar element for this Theme, including any border.
|
int |
getMenuCheckmarkWidth()
Obtain the width of the check mark to for togglable menus.
|
NativeInsets |
getMenuInsets()
Obtain the insets of a popup menu.
|
int |
getMenuItemHeight(MenuElement menuItem)
Obtain the height of a
MenuElement in a menu widget. |
int |
getMenuLeftPad()
Obtain the left padding of the test in a menu item.
|
int |
getMenuRightPad()
Obtain the right padding of the test in a menu item.
|
int |
getMenuSeparatorHeight()
Obtain the fixed height of a separator in a popup menu widget.
|
int |
getMenuSmArrowWidth()
Obtain the width of the arrow marking menus with submenus (including additional space).
|
java.lang.String |
getName()
Get the name of this
Theme . |
char |
getPasswordCharacter()
Obtain the character used to replace text in password fields.
|
int |
getPrebuiltArrowImageSize()
Utility method that returns the size of the prebuilt arrow images.
|
int |
getRadioButtonExtraDist()
Obtain the distance separating radio buttons in a set.
|
int |
getRadioButtonImageSpace()
Obtain the distance before text, including the radio button (text offset).
|
NativePoint |
getRowToggleOffset(BrowseColumnGuiImpl column,
boolean editor)
Get the offset of the in-browse toggle-box relatively to the containing cell.
|
NativeDimension |
getRowToggleSize(BrowseColumnGuiImpl column,
boolean editor)
Get the size of the in-browse toggle-box.
|
int |
getScrollBarButtonHeight()
Obtain the size of the scroll button on the direction of the scroll.
|
int |
getScrollBarButtonWidth()
Obtain the size of the scroll button on the direction perpendicular to scroll direction.
|
int |
getScrollBarGaugeWidth()
Obtain the width of the gauge of a scrollbar widget.
|
int |
getScrollBarThumbMinSize()
Obtain the minimum size of the thumb/slider of a scrollbar widget.
|
int |
getScrollBarThumbWidth()
Obtain the thumb/slider width in a scrollbar widget.
|
int |
getSpaceBeforeButton(CaptionButtonType type)
Return the amount of space to the right of this button.
|
java.util.Map<java.lang.String,java.lang.String> |
getStandardFontTable()
Obtain the map of standard fonts specific to current
Theme , to which a key defaults,
if not overridden in the directory. |
java.awt.Font |
getTitleBarFont()
Obtain the
Font used to render the windows title. |
int |
getTitleBarHeight(boolean maximized)
Returns the height of window's titleBar.
|
java.awt.Color |
getTitleBarTextColor(boolean active)
Obtain the
Color used to render the windows title. |
NativeInsets |
getWindowBorderInsets(boolean modal)
Returns the window's border insets.
|
int |
getWindowIconAlignment()
Get the icon alignment for this theme.
|
int |
getWindowTitleAlignment()
Get the title alignment for this theme.
|
boolean |
isMouseHoverSensitive()
Check if the theme is mouse hover sensitive.
|
double |
layoutTitleBar(TopLevelWindow window,
Widget icon,
Label title,
CaptionButton[] captionButtons,
double width,
CoordinatesConversion c)
Do the layout of a titlebar.
|
default void |
releaseResources()
Release any held resources when this
Theme is removed. |
static final int ALIGN_NONE
This constant is defined for invalid or uninitialized alignment value.
static final int HORIZONTAL_ALIGN_MASK
static final int ALIGN_LEFT
static final int ALIGN_RIGHT
static final int ALIGN_CENTER
static final int VERTICAL_ALIGN_MASK
static final int ALIGN_TOP
static final int ALIGN_BOTTOM
static final int ALIGN_MIDDLE
java.lang.String getName()
Theme
. All implementing classes must implement or override
this method.default void releaseResources()
Theme
is removed.ImageWrapper getImage(java.lang.String name, int width, int height, boolean antialias)
Theme
. The image can be cached for
performance reasons. It will be automatically released when releaseResources()
is
called, when a new Theme
is loaded and this one is removed.name
- The name of the image as path within jar bundle.width
- The desired with of the returned image. This is only a hint. If available, an
image with exact width is returned. One need to check the size of the returned
ImageWrapper
to know the exact value.height
- The desired with of the returned image. This is only a hint. If available, an
image with exact width is returned. One need to check the size of the returned
ImageWrapper
to know the exact value.antialias
- if true
and image is scaled to meet the size hints, an smooth scaling
algorithm will be used, otherwise a faster one will be used but the image quality
will be lower. If image is not scaled the parameter is ignored.ImageWrapper
containing the requested image resource if it can be found
and loaded and null
otherwise.boolean isMouseHoverSensitive()
true
iif the theme is mouse hover sensitive.java.util.Map<java.lang.Integer,ColorRgb> getDefaultSystemPalette()
java.util.Map<java.lang.String,java.lang.String> getStandardFontTable()
Theme
, to which a key defaults,
if not overridden in the directory.Theme
.java.util.Map<java.lang.String,java.lang.String> getDefaultFontAliases()
Theme
, to which a key
defaults, if not overridden in the directory.Theme
.int getPrebuiltArrowImageSize()
int getTitleBarHeight(boolean maximized)
maximized
- On some themes, the maximized window have a different title bar height when
maximized.NativeInsets getWindowBorderInsets(boolean modal)
modal
- Usually the modal dialogs/windows have a different width if modal.int getCaptionButtonHeight(boolean maximized)
maximized
- On some themes, the maximized window have a different button height when
maximized.int getCaptionButtonWidth(CaptionButtonType type, boolean dialog)
type
- On some specific themes, the width of buttons is not the same.dialog
- true
for dialogs. The dialogs may have specific width for caption buttons.int getCaptionButtonsAlignment()
int getWindowTitleAlignment()
int getWindowIconAlignment()
int getSpaceBeforeButton(CaptionButtonType type)
type
- The caption button type.double layoutTitleBar(TopLevelWindow window, Widget icon, Label title, CaptionButton[] captionButtons, double width, CoordinatesConversion c)
Theme
can define how its components are arranged.window
- The window whose titlebar is laid out.icon
- The icon widget of the window (if any).title
- The Label
that displays the window's title.captionButtons
- An array with the CaptionButton
-s present on the titlebar of this window.width
- The width of the window (in character units).c
- the CoordinatesConversion
used for possible units conversions.java.awt.Font getTitleBarFont()
Font
used to render the windows title.Font
used to render the windows title.java.awt.Color getTitleBarTextColor(boolean active)
Color
used to render the windows title.active
- true
if the rendered window is active. The inactive window is usually fade.Color
used to render the windows title.void drawCaptionButton(CaptionButton button, GuiDriver gd, int x, int y, int width, int height)
CaptionButton
.button
- The CaptionButton
to be drawn.gd
- The GuiDriver
used for drawing operations. Note that internal state of
this object can affect the resulting output.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.void drawWindowTitleBar(GuiDriver gd, int x, int y, int width, int height, boolean active)
gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.active
- true
if the drawn windows is active.void drawWindowTitle(GuiDriver gd, GuiFontResolver gf, int x, int y, int width, int height, java.lang.String title, boolean active)
gd
- The GuiDriver
used for drawing operations.gf
- The GuiFontResolver
for selecting the required font.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.title
- The title of the window.active
- true
if the drawn windows is active.void drawWindowBorder(GuiDriver gd, int x, int y, int width, int height, NativeInsets border, boolean active)
gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.border
- The width of the border on each side.active
- true
if the drawn windows is active.void drawStatusBar(GuiDriver gd, GuiColorResolver gc, int x, int y, int width, int height, java.lang.String text, GuiFontResolver.FontCache cache, NativePoint txtOrig, NativeDimension txtDim, boolean resizable)
gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used for color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.text
- The text in the status bar.cache
- The font cache used for text rendering.txtOrig
- The NativePoint
where the text is drawn.txtDim
- The NativeDimension
of the text displayed in status bar.resizable
- true
window is resizable. In this case a "grip" is drawn in the lower right
corner.void drawButton(ButtonGuiImpl button, GuiDriver gd, GuiColorResolver gc, GuiFontResolver gf, int x, int y, int width, int height)
button
- The ButtonGuiImpl
to be rendered.gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
to be used for color selection.gf
- The GuiFontResolver
to be used.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.int getAlertBoxPadding()
void drawAlertBox(GuiDriver gd, int x, int y, int width, int height, int paragraphWidth, ImageWrapper icon, java.lang.String text, FontDetails font)
gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.paragraphWidth
- The width of the paragraph.icon
- The ImageWrapper
containing the image to be shown in the alert dialog. May
be null
.text
- The text to be displayed in this alert box.font
- The FontDetails
needed for text layout.int getRadioButtonExtraDist()
int getRadioButtonImageSpace()
void drawRadioButton(RadioButtonGuiImpl rb, GuiDriver gd, GuiColorResolver gc, GuiFontResolver gf, int x, int y, int width, int height, boolean focused, boolean hover)
rb
- The RadioButtonGuiImpl
to be rendered.gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
to be used for color selection.gf
- The GuiFontResolver
to be used.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.focused
- true
if the radio button have the focushover
- true
if mouse is hovering over the checkbox. Some styles are mouse hoveringint getCheckBoxSpace()
int getCheckBoxSize()
void drawToggleBox(ToggleBoxGuiImpl checkbox, GuiDriver gd, GuiColorResolver gc, GuiFontResolver gf, int x, int y, int width, int height, boolean pressed, boolean hover)
checkbox
- The ToggleBoxGuiImpl
to be rendered.gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
to be used for color selection.gf
- The GuiFontResolver
to be used.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.pressed
- true
if the checkbox is pressed (the mouse button is down on the button).hover
- true
if mouse is hovering over the checkbox. Some styles are mouse hoveringint getScrollBarButtonWidth()
int getScrollBarThumbWidth()
int getScrollBarThumbMinSize()
int getScrollBarGaugeWidth()
int getScrollBarButtonHeight()
void drawScrollBarGauge(GuiDriver gd, GuiColorResolver gc, int x, int y, int width, int height, boolean horizontal)
gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.horizontal
- The direction of the scrollbar, true
for horizontal.void drawScrollBarThumb(GuiDriver gd, GuiColorResolver gc, int x, int y, int width, int height, boolean pressed, boolean hover, boolean horizontal)
gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.pressed
- If the mouse is dragging the thumb of the scrollbar.hover
- Is mouse hovering this component ?horizontal
- The direction of the scrollbar, true
for horizontal.int get3DBorderOffset()
void drawScrollBarButton(GuiDriver gd, GuiColorResolver gc, int x, int y, int width, int height, ScrollBar.Position pos, boolean horizontal, boolean enabled, boolean pressed, boolean highlighted)
gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.pos
- The position of the button (UP/DOWN, LEFT/RIGHT).horizontal
- The direction of the scrollbar, true
for horizontal.enabled
- If the button is enabled.pressed
- If the button is down (pressed by mouse).highlighted
- If the mouse is hovering over the button.char getPasswordCharacter()
void drawFillInBorder(GuiDriver gd, GuiColorResolver gc, int x, int y, int width, int height, boolean border3D, boolean hasFocus, boolean hover)
gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.border3D
- If fill-in widget has a 3d border. Some flat Theme
s may ignore this.hasFocus
- The fill-in widget is focused.hover
- The mouse is hovering over the fill-in widget.void drawFillInSelection(FillInGuiImpl fillIn, GuiDriver gd, int clipWidth, int clipHeight, int selX, int selWidth, int selHeight, java.lang.String selTxt, int font, ColorRgb bgColor, ColorRgb fgColor)
fillIn
- The FillInGuiImpl
to be drawn.gd
- The GuiDriver
used for drawing operations.clipWidth
- The width of the clipping area.clipHeight
- The height of the clipping area.selX
- The offset where the selection starts.selWidth
- The width of the selection.selHeight
- The height of the selection.selTxt
- The selected text.font
- The font to be used.bgColor
- The background color of the selection (selection color).fgColor
- The selected text color (foreground color).void drawFillInCaret(FillInGuiImpl fillIn, GuiDriver gd, int x1, int y1, int x2, int y2)
fillIn
- The widget whose caret is to be rendered.gd
- The GuiDriver
used for drawing operations.x1
- The left extremity of the caret.y1
- The top extremity of the caret.x2
- The right extremity of the caret.y2
- The bottom extremity of the caret.int getComboBoxFieldExtraSpace(boolean horiz, boolean is3D)
horiz
- Direction. true
for horizontal space.is3D
- Whether this is widget has a 3D border.int getComboBoxEntryShift()
int getComboBoxButtonSize()
void drawComboBoxEntryField(ComboBoxGuiImpl combo, GuiDriver gd, GuiColorResolver gc, int x, int y, int width, int height, FontDetails<?> font, boolean pressed, boolean enabled, boolean hover)
combo
- The ComboBoxGuiImpl
whose entry field is painted.gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.font
- A FontDetails
used for text rendering.pressed
- true
if the widget is pressed (and eventually open).enabled
- Whether the widget has the focus.hover
- The mouse is hovering over the fill-in widget.void drawComboBoxFieldBorder(ComboBoxGuiImpl combo, GuiDriver gd, int x, int y, int width, int height, boolean pressed, boolean enabled, boolean hover)
combo
- The ComboBoxGuiImpl
whose border is being painted.gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.pressed
- true
if the widget is pressed (and eventually open).enabled
- Whether the widget has the focus.hover
- The mouse is hovering over the fill-in widget.void drawComboBoxButton(ComboBoxGuiImpl combo, GuiDriver gd, int x, int y, int width, int height, boolean pressed, boolean enabled, boolean hover)
combo
- The ComboBoxGuiImpl
whose border is being painted.gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.pressed
- true
if the widget is pressed (and eventually open).enabled
- Whether the widget has the focus.hover
- The mouse is hovering over the fill-in widget.void drawSelectionListBackground(GuiDriver gd, GuiColorResolver gc, int x, int y, int width, int height)
gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.void drawSelectionListItem(ComboBoxGuiImpl box, GuiDriver gd, GuiColorResolver gc, int x, int y, int width, int height, java.lang.String text, int fontSize, boolean enabled, boolean highlighted, boolean selected)
box
- The ComboBoxGuiImpl
whose border is being painted.gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.text
- The text to be displayed on this itemfontSize
- The size of teh font to be used.highlighted
- The mouse is hovering over the fill-in widget.enabled
- Whether the widget has the focus.int getComboBoxDropDownOffset()
int getMenuLeftPad()
int getMenuRightPad()
NativeInsets getMenuInsets()
int getMenuCheckmarkWidth()
int getMenuSmArrowWidth()
int getMenuBarElementMinSize(boolean horiz)
horiz
- If true
returns the minimum width, if false
returns minimum height.void drawMenuBackground(GuiDriver gd, int x, int y, int width, int height, boolean popup)
gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.popup
- true
for popup menus.void drawMenuSeparator(GuiDriver gd, int x, int y, int width, int height)
gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.int getMenuSeparatorHeight()
int getMenuItemHeight(MenuElement menuItem)
MenuElement
in a menu widget.void drawMenuItemContent(AbstractWidget item, GuiDriver gd, GuiFontResolver gf, int x, int y, int width, int height, int textHeight, boolean focused)
item
- The MenuItemGuiImpl
or SubMenuGuiImpl
to be drawn.gd
- The GuiDriver
used for drawing operations.gf
- The GuiFontResolver
to be used.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.textHeight
- The height of the text.focused
- true
if this item is highlighted/focused.void drawMenuItemBackground(AbstractWidget item, GuiDriver gd, int x, int y, int width, int height, boolean hover)
item
- The MenuItemGuiImpl
or SubMenuGuiImpl
to be drawn.gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.hover
- true
if this item is highlighted/focused.void drawMenuBarElement(SubMenuGuiImpl menu, GuiDriver gd, GuiFontResolver gf, int x, int y, int width, int height, boolean hover)
menu
- The SubMenuGuiImpl
widget to be painted.gd
- The GuiDriver
used for drawing operations.gf
- GUI font resolver.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.hover
- true
if this item is highlighted/focused.void drawLabel(LabelGuiImpl label, GuiDriver gd, GuiColorResolver gc, GuiFontResolver gf, int x, int y, int width, int height, boolean emptyMode)
label
- The LabelGuiImpl
to be drawn.gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.gf
- The GuiFontResolver
to be used.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.emptyMode
- If it is true
, empty string is displayed.void drawLabelUnderline(GuiDriver gd, int x, int y, int width, int height, ColorRgb fgColor)
gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.fgColor
- The color attribute for the line.void drawBrowseRowHighlight(BrowseGuiImpl browse, GuiDriver gd, int x, int y, int width, int height)
BrowseGuiImpl
widget.browse
- The BrowseGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.void drawBrowseColumnDrag(BrowseGuiImpl browse, GuiDriver gd, int x, int y, int width, int height)
BrowseGuiImpl
widget.browse
- The BrowseGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.void drawBrowseResizingColumn(BrowseGuiImpl browse, GuiDriver gd, int left, int top, int right, int bottom)
BrowseGuiImpl
widget.browse
- The BrowseGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.left
- The left offset of the resized column.top
- The top offset where the columns start.right
- The right offset of the resized column.bottom
- The bottom offset where the columns end.void drawBrowseTitlePanel(BrowseGuiImpl browse, GuiDriver gd, GuiColorResolver gc, GuiFontResolver gf, int x, int y, int width, int height)
BrowseGuiImpl
widget.browse
- The BrowseGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.gf
- The GuiFontResolver
to be used.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.void drawBrowseColumnLabel(BrowseColumnGuiImpl column, GuiDriver gd, int x, int y, int width, int height, FontDetails fontDetails)
BrowseColumnGuiImpl
widget.column
- The BrowseGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.fontDetails
- The font details to be used.void drawBrowseMarkersColumn(BrowseColumnGuiImpl column, GuiDriver gd, int x, int y, int width, int height)
BrowseColumnGuiImpl
widget (without label).column
- The BrowseGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.void drawBrowseNormalColumn(BrowseColumnGuiImpl column, GuiDriver gd, int x, int y, int width, int height)
BrowseColumnGuiImpl
widget (without label).column
- The BrowseGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.void drawToolTip(GuiDriver gd, int x, int y, int width, int height, FontDetails fnt, java.lang.String text)
ToolTip
.gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.fnt
- The FontDetails
to be used when drawing the text.text
- The actual text to be drawn.void drawFrameTitle(FrameGuiImpl frame, GuiDriver gd, GuiColorResolver gc, GuiFontResolver gf, int x, int y, int width, int height)
BrowseGuiImpl
widget.frame
- The FrameGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.gf
- The GuiFontResolver
to be used.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.NativePoint getRowToggleOffset(BrowseColumnGuiImpl column, boolean editor)
column
- The column that contains the toggle-box.editor
- true
if the toggle-box is contained in the current cell, i.e. it is the
editor. false
for all other inactive toggle boxes.NativeDimension getRowToggleSize(BrowseColumnGuiImpl column, boolean editor)
column
- The column that contains the toggle-box.editor
- true
if the toggle-box is contained in the current cell, i.e. it is the
editor. false
for all other inactive toggle boxes.void drawLineBorder(LineBorderGuiImpl border, GuiDriver gd, GuiColorResolver gc, int x, int y, int width, int height)
LineBorderGuiImpl
widget.border
- The FrameGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.void drawRectangle(RectangleGuiImpl rect, GuiDriver gd, GuiColorResolver gc, int x, int y, int width, int height)
RectangleGuiImpl
widget.rect
- The RectangleGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.gc
- The GuiColorResolver
used color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.void draw3DBorder(ThreeDBorderGuiImpl border, GuiDriver gd, int x, int y, int width, int height)
ThreeDBorderGuiImpl
widget.border
- The RectangleGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.void drawEditorContent(EditorGuiImpl editor, GuiDriver gd, GuiFontResolver gf, GuiColorResolver gc, int x, int y, int width, int height, NativePoint selStart, NativePoint selEnd, int dx, int dy)
EditorGuiImpl
widget.editor
- The EditorGuiImpl
widget.gd
- The GuiDriver
used for drawing operations.gf
- The GuiFontResolver
to be used.gc
- The GuiColorResolver
used color selection.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.selStart
- selection start anchor.selEnd
- selection end anchor.dx
- the full horizontal delta (left-side text which is scrolled by caret or by mouse).dy
- offset when scrolling vertically via the scrollbar (the cursor does not move).void drawEditorCaret(EditorGuiImpl editor, GuiDriver gd, int x1, int y1, int x2, int y2)
gd
- The GuiDriver
used for drawing operations.x1
- The left extremity of the caret.y1
- The top extremity of the caret.x2
- The right extremity of the caret.y2
- The bottom extremity of the caret.void drawSelectionFocus(GuiDriver gd, int x, int y, int width, int height)
gd
- The GuiDriver
used for drawing operations.x
- The horizontal location (in pixel units) of the widget to be painted/component.y
- The vertical location (in pixel units) of the widget to be painted/component.width
- The width of the painted widget/component.height
- The height of the painted widget/component.