|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdanger.ui.Style
public class Style
A Style object includes information about how to draw a View, including color, fonts, and drawing methods. The standard Style object contains the built-in look. You can change the look of Views on a per-View basis by either overriding the Style object to define different drawing methods, or using method calls to change colors and fonts.
| Constructor Summary | |
|---|---|
Style()
Construct a Style object. |
|
Style(String s)
Construct a style based on a string describing the colors and fonts to use. |
|
Style(Style style)
Construct a Style which is a copy of the specified Style. |
|
| Method Summary | |
|---|---|
int |
attributeCount()
Get the number of attributes in the style. |
static void |
drawArrow(Pen pen,
int x,
int y,
int width,
int height,
int direction)
Draw a an arrow outline using the current pen color. |
static void |
drawArrow(Pen pen,
Style style,
int x,
int y,
int width,
int height,
boolean focused,
int direction)
Draw an arrow usually used for indicating something can scroll. |
void |
drawButtonBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for BUTTON_BACKGROUND. |
void |
drawButtonFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for BUTTON_FRAME. |
static void |
drawCheckBox(Pen pen,
Style style,
int x,
int y,
boolean enabled,
boolean focused,
boolean on)
Draw a check box. |
static void |
drawCheckBox(Pen pen,
Style style,
int x,
int y,
boolean enabled,
boolean focused,
int value)
Draw a check box. |
void |
drawCheckBoxBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for CHECK_BOX_BACKGROUND. |
static void |
drawCheckMark(Pen pen,
int color,
int x1,
int y1,
int x2,
int y2,
int x3,
int y3,
int thickness)
Draw a check mark. |
void |
drawCurrentTabItem(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for CURRENT_TAB_ITEM. |
void |
drawDateEditorBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for DATE_EDITOR_BACKGROUND. |
void |
drawDatePickerFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for DATE_PICKER_FRAME. |
void |
drawDatePickerWindowFrame(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for DATE_PICKER_WINDOW_FRAME. |
void |
drawDialogBackground(Pen pen,
Style style,
Rect rect)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for DIALOG_BACKGROUND. |
void |
drawDialogFrame(Pen pen,
Style style,
Rect rect,
DialogWindow window)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for DIALOG_FRAME. |
void |
drawElement(int type,
Pen pen,
View view,
Rect rect)
Draw an Style element. |
void |
drawFocusedMenuItemBackground(Pen pen,
Style style,
Rect rect,
View view,
int cornerOptions)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for FOCUSED_MENU_ITEM_BACKGROUND. |
void |
drawFocusedTabItem(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for FOCUSED_TAB_ITEM. |
void |
drawIconPickerFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for ICON_PICKER_FRAME. |
void |
drawIconPickerSelectionBackground(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for ICON_PICKER_SELECTION_BACKGROUND. |
void |
drawIconPickerWindowFrame(Pen pen,
Style style,
Rect rect,
View view,
boolean enabled,
boolean focused,
boolean transparent)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for ICON_PICKER_WINDOW_FRAME. |
void |
drawImageViewFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for IMAGE_VIEW_FRAME. |
void |
drawListSelectionBackground(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for LIST_SELECTION_BACKGROUND. |
void |
drawMarqueeBackground(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MARQUEE_BACKGROUND. |
void |
drawMarqueeFrame(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MARQUEE_FRAME. |
void |
drawMenuBackground(Pen pen,
Style style,
Rect rect,
boolean topIsFlat,
boolean bottomIsFlat)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MENU_BACKGROUND. |
void |
drawMenuFrame(Pen pen,
Style style,
Rect rect,
View view,
boolean topIsFlat,
boolean bottomIsFlat)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MENU_FRAME. |
void |
drawMonthViewBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MONTH_VIEW_BACKGROUND. |
void |
drawMovingTabItem(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MOVING_TAB_ITEM. |
static void |
drawOutlinedArrow(Pen pen,
Style style,
int x,
int y,
int width,
int height,
int direction)
Draw an arrow with an outline for use against possibly black backgrounds. |
static void |
drawPickerArrows(Pen pen,
Style style,
int x,
int y,
boolean focused)
Draw double arrows suitable for a picker widget. |
void |
drawPickerWindowFrame(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for PICKER_WINDOW_FRAME. |
static void |
drawPopupArrows(Pen pen,
Style style,
int x,
int y,
int width,
int height,
boolean focused)
Draw double arrows suitable for a popup menu. |
void |
drawPopupMenuBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for POPUP_MENU_BACKGROUND. |
void |
drawPopupMenuFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for POPUP_MENU_FRAME. |
static void |
drawRadioButton(Pen pen,
Style style,
int x,
int y,
boolean enabled,
boolean focused,
boolean on)
Draw a radio button. |
void |
drawRingtonePickerFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for RING_TONE_PICKER_FRAME. |
static void |
drawRoundedBox(Pen pen,
Style style,
int left,
int top,
int right,
int bottom,
boolean enabled,
boolean focused,
int cornerSize,
boolean hasFrame)
Draw a rounded box. |
static void |
drawRoundedBox(Pen pen,
Style style,
int left,
int top,
int right,
int bottom,
boolean enabled,
boolean focused,
int cornerSize,
boolean hasFrame,
boolean clearBackground)
Draw a rounded box. |
static void |
drawScrollDownArrow(Pen pen,
Style style,
int width,
int height)
Draw a down arrow usually used for indicating something can scroll. |
static void |
drawScrollUpArrow(Pen pen,
Style style,
int width,
int y)
Draw an up arrow usually used for indicating something can scroll. |
void |
drawSliderBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for SLIDER_BACKGROUND. |
void |
drawSliderFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for SLIDER_FRAME. |
void |
drawSliderWindowFrame(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for SLIDER_WINDOW_FRAME. |
void |
drawTabItem(Pen pen,
Style style,
Rect rect,
View view)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for TAB_ITEM. |
void |
drawTitleBarBackground(Pen pen,
Style style,
Rect rect,
TitleBar titleBar)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for TITLE_BAR_BACKGROUND. |
void |
drawTitleBarPill(Pen pen,
Style style,
Rect rect)
Equivalent to drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for TITLE_BAR_PILL. |
void |
drawViewFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
int arcSize,
boolean hasFrame,
boolean clearBackground)
Draw a view frame. |
static void |
fillArrow(Pen pen,
int x,
int y,
int width,
int height,
int direction)
Draw a filled arrow using the current pen color. |
String |
getAttributeName(int attribute)
Get the name of the numbered attribute. |
int |
getAttributeType(int attribute)
Get the type of the numbered attribute. |
static Style[] |
getAvailableStyles()
Get an array of the currently available styles. |
int |
getBackgroundColor(boolean focused)
Get the background color. |
int |
getBackgroundColor(boolean enabled,
boolean focused)
Get the background color. |
static int |
getCheckBoxHeight()
Get the height of check boxes. |
static int |
getCheckBoxWidth()
Get the width of check boxes. |
int |
getColor(int attribute)
Get the color to use for the specified attribute. |
static Style |
getDefaultStyle()
Return the default style, which is the default setting for the system style. |
Font |
getFont(int attribute)
Get the font to use for the specified attribute. |
int |
getForegroundColor(boolean focused)
Get the foreground color. |
int |
getForegroundColor(boolean enabled,
boolean focused)
Get the foreground color. |
int |
getFrameColor(boolean focused)
Get the frame color. |
int |
getFrameColor(boolean enabled,
boolean focused)
Get the frame color. |
int[] |
getGradient(int attribute)
Get the gradient to use for the specified attribute. |
int |
getLabelColor(boolean focused)
Get the label color. |
int |
getLabelColor(boolean enabled,
boolean focused)
Get the label color. |
Font |
getLabelFont(boolean enabled)
Get the label font. |
int |
getLabelOutlineColor(boolean focused)
Get the label outline color. |
int |
getLabelOutlineColor(boolean enabled,
boolean focused)
Get the label outline color. |
int |
getLightTextColor(boolean selected)
Get the light text color. |
Font |
getMenuFont(boolean enabled)
Get the menu font. |
int |
getMenuTextColor(boolean focused)
Get the menu text color. |
int |
getMenuTextColor(boolean enabled,
boolean focused)
Get the menu text color. |
int |
getMenuTextOutlineColor(boolean focused)
Get the menu text outline color. |
int |
getMenuTextOutlineColor(boolean enabled,
boolean focused)
Get the menu text outline color. |
int |
getMenuTextOutlineFillColor(boolean focused)
Get the menu text outline fill color. |
int |
getMenuTextOutlineFillColor(boolean enabled,
boolean focused)
Get the menu text outline fill color. |
String |
getName()
Get the name of the Style. |
static int |
getRadioButtonHeight()
Get the height of radio buttons. |
static int |
getRadioButtonWidth()
Get the width of radio buttons. |
static int |
getScrollArrowHeight()
Get the height of the scroll arrows used in the menus. |
static int |
getScrollArrowWidth()
Get the width of the scroll arrows used in the menus. |
int |
getSecondaryFrameColor(boolean enabled,
boolean focused)
Get the secondary frame color. |
int |
getShadowColor(boolean focused)
Get the shadow color. |
int |
getShadowColor(boolean enabled,
boolean focused)
Get the shadow color. |
static Style |
getSystemStyle()
Return the current system style, which is used to draw all Views if no other style is specified. |
int |
getTextColor(boolean focused)
Get the text color. |
int |
getTextColor(boolean enabled,
boolean focused)
Get the text color. |
int |
getTextOutlineColor(boolean focused)
Get the text outline color. |
int |
getTextOutlineColor(boolean enabled,
boolean focused)
Get the text outline color. |
static void |
registerForChanges(Listener listener)
Register to receive an event when the system style changes. |
void |
setColor(int attribute,
int color)
Set the color to use for the specified attribute. |
void |
setFont(int attribute,
Font font)
Set the font to use for the specified attribute. |
void |
setGradient(int attribute,
int[] gradient)
Set the gradient to use for the specified attribute. |
void |
setImmutable()
Specify that this style cannot be changed. |
static void |
unRegisterForChanges(Listener listener)
Unregister as a listener for style changed events, as set by registerForChanges(danger.app.Listener). |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int BACKGROUND_COLOR
getColor(int).
public static final int FOREGROUND_COLOR
getColor(int).
public static final int FRAME_COLOR
getColor(int).
public static final int LABEL_COLOR
getColor(int).
public static final int SECONDARY_FRAME_COLOR
getColor(int).
public static final int SHADOW_COLOR
getColor(int).
public static final int TEXT_COLOR
getColor(int).
public static final int TEXT_OUTLINE_COLOR
getColor(int).
public static final int DISABLED_BACKGROUND_COLOR
getColor(int).
public static final int DISABLED_FOREGROUND_COLOR
getColor(int).
public static final int DISABLED_FRAME_COLOR
getColor(int).
public static final int DISABLED_LABEL_COLOR
getColor(int).
public static final int DISABLED_SECONDARY_FRAME_COLOR
getColor(int).
public static final int DISABLED_SHADOW_COLOR
getColor(int).
public static final int DISABLED_TEXT_COLOR
getColor(int).
public static final int DISABLED_TEXT_OUTLINE_COLOR
getColor(int).
public static final int FOCUSED_BACKGROUND_COLOR
getColor(int).
public static final int FOCUSED_FOREGROUND_COLOR
getColor(int).
public static final int FOCUSED_FRAME_COLOR
getColor(int).
public static final int FOCUSED_LABEL_COLOR
getColor(int).
public static final int FOCUSED_SECONDARY_FRAME_COLOR
getColor(int).
public static final int FOCUSED_SHADOW_COLOR
getColor(int).
public static final int FOCUSED_TEXT_COLOR
getColor(int).
public static final int FOCUSED_TEXT_OUTLINE_COLOR
getColor(int).
public static final int LIGHT_TEXT_COLOR
getColor(int).
public static final int LIGHT_SELECTED_TEXT_COLOR
getColor(int).
public static final int CARET_COLOR
getColor(int).
public static final int DIVIDER_COLOR
getColor(int).
public static final int PANE_COLOR
getColor(int).
public static final int SCROLL_BAR_THUMB_COLOR
getColor(int).
public static final int SELECTION_BACKGROUND_COLOR
getColor(int).
public static final int DIALOG_TITLE_TEXT_COLOR
getColor(int).
public static final int DIALOG_TITLE_FRAME_COLOR
getColor(int).
public static final int DIALOG_TITLE_OUTLINE_COLOR
getColor(int).
public static final int DIALOG_TITLE_FONT
getColor(int).
public static final int DIALOG_FRAME_COLOR
getColor(int).
public static final int APP_DIALOG_TITLE_FRAME_COLOR
getColor(int).
public static final int SYSTEM_DIALOG_TITLE_TEXT_COLOR
getColor(int).
public static final int SYSTEM_DIALOG_TITLE_FRAME_COLOR
getColor(int).
public static final int SYSTEM_DIALOG_TITLE_OUTLINE_COLOR
getColor(int).
public static final int SYSTEM_DIALOG_TITLE_FONT
getColor(int).
public static final int SYSTEM_DIALOG_FRAME_COLOR
getColor(int).
public static final int SYSTEM_ERROR_TITLE_TEXT_COLOR
getColor(int).
public static final int SYSTEM_ERROR_TITLE_FRAME_COLOR
getColor(int).
public static final int SYSTEM_ERROR_TITLE_OUTLINE_COLOR
getColor(int).
public static final int SYSTEM_ERROR_TITLE_FONT
getColor(int).
public static final int SYSTEM_ERROR_FRAME_COLOR
getColor(int).
public static final int WINDOW_SHADOW_COLOR
getColor(int).
public static final int WINDOW_SHADOW_FRAME_COLOR
getColor(int).
public static final int SPLASH_SCREEN_TEXT_COLOR
getColor(int).
public static final int SPLASH_SCREEN_TEXT_OUTLINE_COLOR
getColor(int).
public static final int FOREGROUND25_COLOR
public static final int FOREGROUND50_COLOR
public static final int FOREGROUND75_COLOR
public static final int CHOOSER_RING_COLOR
getColor(int).
public static final int CHOOSER_SELECTED_RING_COLOR
getColor(int).
public static final int TITLE_BAR_BACKGROUND_COLOR
getColor(int).
public static final int TITLE_BAR_OVER_CHOOSER_BACKGROUND_COLOR
getColor(int).
public static final int TITLE_BAR_PILL_COLOR
getColor(int).
public static final int TITLE_BAR_OVER_CHOOSER_PILL_COLOR
getColor(int).
public static final int TITLE_BAR_TEXT_COLOR
getColor(int).
public static final int TITLE_BAR_OVER_CHOOSER_TEXT_COLOR
getColor(int).
public static final int TITLE_BAR_TEXT_OUTLINE_COLOR
getColor(int).
public static final int TITLE_BAR_OVER_CHOOSER_TEXT_OUTLINE_COLOR
getColor(int).
public static final int TITLE_BAR_CLOCK_COLOR
getColor(int).
public static final int TITLE_BAR_OVER_CHOOSER_CLOCK_COLOR
getColor(int).
public static final int TITLE_BAR_CLOCK_OUTLINE_COLOR
getColor(int).
public static final int TITLE_BAR_OVER_CHOOSER_CLOCK_OUTLINE_COLOR
getColor(int).
public static final int MENU_FRAME_COLOR
getColor(int).
public static final int MENU_SHADOW_COLOR
getColor(int).
public static final int MENU_SHORTCUT_COLOR
getColor(int).
public static final int LABEL_FONT
getFont(int).
public static final int DISABLED_LABEL_FONT
getFont(int).
public static final int MENU_FONT
getFont(int).
public static final int DISABLED_MENU_FONT
getFont(int).
public static final int APP_ALERT_TITLE_TEXT_COLOR
getColor(int).
public static final int APP_ALERT_TITLE_FRAME_COLOR
getColor(int).
public static final int APP_ALERT_TITLE_OUTLINE_COLOR
getColor(int).
public static final int APP_ALERT_TITLE_FONT
getFont(int).
public static final int APP_ALERT_FRAME_COLOR
getColor(int).
public static final int CHOOSER_RING_DARK_COLOR
getColor(int).
public static final int CHOOSER_RING_MEDIUM_COLOR
getColor(int).
public static final int CHOOSER_RING_LIGHT_COLOR
getColor(int).
public static final int CHOOSER_RING_DEFAULTAPP_DARK_COLOR
getColor(int).
public static final int CHOOSER_RING_DEFAULTAPP_MEDIUM_COLOR
getColor(int).
public static final int CHOOSER_RING_DEFAULTAPP_LIGHT_COLOR
getColor(int).
public static final int LABEL_OUTLINE_COLOR
getColor(int).
public static final int DISABLED_LABEL_OUTLINE_COLOR
getColor(int).
public static final int FOCUSED_LABEL_OUTLINE_COLOR
getColor(int).
public static final int MENU_TEXT_COLOR
getColor(int).
public static final int MENU_TEXT_OUTLINE_COLOR
getColor(int).
public static final int MENU_TEXT_OUTLINE_FILL_COLOR
getColor(int).
public static final int DISABLED_MENU_TEXT_COLOR
getColor(int).
public static final int DISABLED_MENU_TEXT_OUTLINE_COLOR
getColor(int).
public static final int DISABLED_MENU_TEXT_OUTLINE_FILL_COLOR
getColor(int).
public static final int FOCUSED_MENU_TEXT_COLOR
getColor(int).
public static final int FOCUSED_MENU_TEXT_OUTLINE_COLOR
getColor(int).
public static final int FOCUSED_MENU_TEXT_OUTLINE_FILL_COLOR
getColor(int).
public static final int TITLE_BAR_GRADIENT
getGradient(int).
public static final int MENU_BACKGROUND_GRADIENT
getGradient(int).
public static final int DATE_EDITOR_GRADIENT
getGradient(int).
public static final int APP_ALERT_TOP_GRADIENT
getGradient(int).
public static final int APP_ALERT_BOTTOM_GRADIENT
getGradient(int).
public static final int SYSTEM_ERROR_TOP_GRADIENT
getGradient(int).
public static final int SYSTEM_ERROR_BOTTOM_GRADIENT
getGradient(int).
public static final int CONTROL_GRADIENT
getGradient(int).
public static final int FOCUSED_CONTROL_GRADIENT
getGradient(int).
public static final int DISABLED_CONTROL_GRADIENT
getGradient(int).
public static final int SIGNAL_STRENGTH_COLOR
getColor(int).
public static final int SIGNAL_STRENGTH_OUTLINE_COLOR
getColor(int).
public static final int SIGNAL_STRENGTH_CHOOSER_COLOR
getColor(int).
public static final int SIGNAL_STRENGTH_CHOOSER_OUTLINE_COLOR
getColor(int).
public static final int SPLASH_SCREEN_TITLE_TEXT_COLOR
getColor(int).
public static final int SPLASH_SCREEN_TITLE_TEXT_OUTLINE_COLOR
getColor(int).
public static final int FOCUSED_LIST_ITEM_GRADIENT
getGradient(int).
public static final int BATTERY_BAR_COLOR
getColor(int).
public static final int BATTERY_BAR_OVER_CHOOSER_COLOR
getColor(int).
public static final int TAB_FRAME_COLOR
getColor(int).
public static final int MOVING_TAB_FRAME_COLOR
getColor(int).
public static final int TAB_ITEM_GRADIENT
getGradient(int).
public static final int CURRENT_TAB_ITEM_GRADIENT
getGradient(int).
public static final int MOVING_TAB_ITEM_GRADIENT
getGradient(int).
public static final int CONTROL_FRAME_COLOR
getColor(int).
public static final int FOCUSED_CONTROL_FRAME_COLOR
getColor(int).
public static final int DISABLED_CONTROL_FRAME_COLOR
getColor(int).
public static final int PICKER_ARROW_COLOR
getColor(int).
public static final int DISABLED_PICKER_ARROW_COLOR
getColor(int).
public static final int TEXT_SHADOW_COLOR
getColor(int).
public static final int SPLASH_SCREEN_TEXT_SHADOW_COLOR
getColor(int).
public static final int FOCUSED_CONTROL_TEXT_SHADOW_COLOR
getColor(int).
public static final int TAB_TEXT_COLOR
getColor(int).
public static final int CURRENT_TAB_TEXT_COLOR
getColor(int).
public static final int FOCUSED_TAB_TEXT_COLOR
getColor(int).
public static final int MOVING_TAB_TEXT_COLOR
getColor(int).
public static final int MENU_TITLE_FRAME_COLOR
getColor(int).
public static final int ATTRIBUTE_COLOR
getAttributeType(int).
public static final int ATTRIBUTE_FONT
getAttributeType(int).
public static final int ATTRIBUTE_GRADIENT
getAttributeType(int).
public static final int BUTTON_CORNER_SIZE
public static final int PICKER_CORNER_SIZE
public static final int DIRECTION_UP
drawArrow(danger.ui.Pen, int, int, int, int, int).
public static final int DIRECTION_DOWN
drawArrow(danger.ui.Pen, int, int, int, int, int).
public static final int DIRECTION_LEFT
drawArrow(danger.ui.Pen, int, int, int, int, int).
public static final int DIRECTION_RIGHT
drawArrow(danger.ui.Pen, int, int, int, int, int).
public static final int SCROLL_ARROW_WIDTH
getScrollArrowWidth() instead.public static final int SCROLL_ARROW_HEIGHT
getScrollArrowHeight() instead.public static final int OUTLINED_SCROLL_ARROW_WIDTH
public static final int OUTLINED_SCROLL_ARROW_HEIGHT
public static final int CHECK_BOX_WIDTH
getCheckBoxWidth() instead.public static final int CHECK_BOX_HEIGHT
getCheckBoxHeight() instead.public static final int RADIO_BUTTON_WIDTH
getRadioButtonWidth() instead.public static final int RADIO_BUTTON_HEIGHT
getRadioButtonHeight() instead.public static final int BUTTON_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int BUTTON_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int DATE_PICKER_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int ICON_PICKER_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int IMAGE_VIEW_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int POPUP_MENU_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int POPUP_MENU_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int RING_TONE_PICKER_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int SLIDER_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int SLIDER_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int DIALOG_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int MENU_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int DIALOG_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int TITLE_BAR_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int TITLE_BAR_PILL
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int MONTH_VIEW_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int ICON_PICKER_WINDOW_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int MENU_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int MENU_FRAME_FLAT
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int MENU_FRAME_TOP_FLAT
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int MENU_FRAME_BOTTOM_FLAT
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int SLIDER_WINDOW_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int DATE_PICKER_WINDOW_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int PICKER_WINDOW_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int FOCUSED_MENU_ITEM_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int MARQUEE_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int LIST_SELECTION_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int DATE_EDITOR_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int CHECK_BOX_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int ICON_PICKER_SELECTION_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int MARQUEE_FRAME
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int FOCUSED_TOP_MENU_ITEM_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int FOCUSED_BOTTOM_MENU_ITEM_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int FOCUSED_TOP_AND_BOTTOM_MENU_ITEM_BACKGROUND
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int TAB_ITEM
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int FOCUSED_TAB_ITEM
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int CURRENT_TAB_ITEM
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
public static final int MOVING_TAB_ITEM
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect).
| Constructor Detail |
|---|
public Style(Style style)
style - the style to make a copy of.public Style()
public Style(String s)
| Method Detail |
|---|
public int getColor(int attribute)
attribute - one of the defined attribute constants, for
example, FOCUSED_FRAME_COLOR, FRAME_COLOR, etc.public Font getFont(int attribute)
attribute - one of the defined attribute constants, for
example, LABEL_FONT, MENU_FONT, etc.public int[] getGradient(int attribute)
Pen.fillSplitGradientRect(Rect,int,int,int,int[]).
attribute - one of the defined attribute constants, for
example, FOCUSED_CONTROL_GRADIENT, CONTROL_GRADIENT, etc.
public void setColor(int attribute,
int color)
attribute - one of the defined attribute constants, for
example, FOCUSED_FRAME_COLOR, FRAME_COLOR, etc.color - the color to use.
public void setFont(int attribute,
Font font)
attribute - one of the defined attribute constants, for
example, LABEL_FONT, MENU_FONT, etc.font - the color to use.
public void setGradient(int attribute,
int[] gradient)
attribute - one of the defined attribute constants, for
example, FOCUSED_CONTROL_GRADIENT, CONTROL_GRADIENT, etc.gradient - the gradient to use. The gradient should be in the form
used for
Pen.fillSplitGradientRect(Rect,int,int,int,int[]).public String getName()
public int getBackgroundColor(boolean focused)
getColor(int) with either
FOCUSED_BACKGROUND_COLOR or
BACKGROUND_COLOR.
focused - whether to get the focused background color.
public int getBackgroundColor(boolean enabled,
boolean focused)
getColor(int) with one of
FOCUSED_BACKGROUND_COLOR,
BACKGROUND_COLOR,
DISABLED_BACKGROUND_COLOR.
enabled - whether to get the enabled color.focused - whether to get the focused color.public int getForegroundColor(boolean focused)
getColor(int) with one of
FOCUSED_FOREGROUND_COLOR,
FOREGROUND_COLOR.
focused - whether to get the focused color.
public int getForegroundColor(boolean enabled,
boolean focused)
getColor(int) with one of
FOCUSED_FOREGROUND_COLOR,
DISABLED_FOREGROUND_COLOR,
FOREGROUND_COLOR.
enabled - whether to get the enabled color.focused - whether to get the focused color.public int getFrameColor(boolean focused)
getColor(int) with one of
FOCUSED_FRAME_COLOR,
FRAME_COLOR.
focused - whether to get the focused color.
public int getFrameColor(boolean enabled,
boolean focused)
getColor(int) with one of
FOCUSED_FRAME_COLOR,
DISABLED_FRAME_COLOR,
FRAME_COLOR.
enabled - whether to get the enabled color.focused - whether to get the focused color.
public int getSecondaryFrameColor(boolean enabled,
boolean focused)
enabled - whether to get the enabled color.focused - whether to get the focused color.public int getShadowColor(boolean focused)
focused - whether to get the focused color.
public int getShadowColor(boolean enabled,
boolean focused)
enabled - whether to get the enabled color.focused - whether to get the focused color.public int getTextColor(boolean focused)
focused - whether to get the focused color.
public int getTextColor(boolean enabled,
boolean focused)
enabled - whether to get the enabled color.focused - whether to get the focused color.public int getTextOutlineColor(boolean focused)
focused - whether to get the focused color.
public int getTextOutlineColor(boolean enabled,
boolean focused)
enabled - whether to get the enabled color.focused - whether to get the focused color.
public int getMenuTextColor(boolean enabled,
boolean focused)
enabled - whether to get the enabled color.focused - whether to get the focused color.public int getMenuTextColor(boolean focused)
focused - whether to get the focused color.
public int getMenuTextOutlineColor(boolean enabled,
boolean focused)
enabled - whether to get the enabled color.focused - whether to get the focused color.public int getMenuTextOutlineColor(boolean focused)
focused - whether to get the focused color.
public int getMenuTextOutlineFillColor(boolean enabled,
boolean focused)
enabled - whether to get the enabled color.focused - whether to get the focused color.public int getMenuTextOutlineFillColor(boolean focused)
focused - whether to get the focused color.public int getLabelColor(boolean focused)
focused - whether to get the focused color.public int getLabelOutlineColor(boolean focused)
focused - whether to get the focused color.
public int getLabelOutlineColor(boolean enabled,
boolean focused)
enabled - whether to get the enabled color.focused - whether to get the focused color.public int getLightTextColor(boolean selected)
selected - whether to get the selected color.
public int getLabelColor(boolean enabled,
boolean focused)
enabled - whether to get the enabled color.focused - whether to get the focused color.public Font getLabelFont(boolean enabled)
enabled - whether to get the enabled font.public Font getMenuFont(boolean enabled)
enabled - whether to get the enabled font.
public static void drawCheckMark(Pen pen,
int color,
int x1,
int y1,
int x2,
int y2,
int x3,
int y3,
int thickness)
pen - non-null; The pen to use.color - The color to use.x1 - X coordinate of the left corner of the check mark.y1 - Y coordinate of the left corner of the check mark.x2 - X coordinate of the bottom corner of the check mark.y2 - Y coordinate of the bottom corner of the check mark.x3 - X coordinate of the right corner of the check mark.y3 - Y coordinate of the right corner of the check mark.thickness - The thickness of the check mark.
public static void drawCheckBox(Pen pen,
Style style,
int x,
int y,
boolean enabled,
boolean focused,
boolean on)
drawCheckBox(Pen,Style,int,int,boolean,boolean,int).
pen - non-null; The pen to use.style - non-null; The style to use.x - X coordinate of the check box (left)y - Y coordinate of the check box (top)focused - Whether to use the focused style colors.enabled - Whether to use the enabled style colors.on - Whether the check box is on and thus has a check mark.
The dimensions of check boxes are 12 x 11.
public static void drawCheckBox(Pen pen,
Style style,
int x,
int y,
boolean enabled,
boolean focused,
int value)
pen - non-null; The pen to use.style - non-null; The style to use.x - X coordinate of the check box (left)y - Y coordinate of the check box (top)focused - Whether to use the focused style colors.enabled - Whether to use the enabled style colors.value - CheckBox.CHECKED_VALUE,
CheckBox.UNCHECKED_VALUE, or
CheckBox.INDETERMINATE_VALUE.
The dimensions of check boxes are 12 x 11.
public static void drawRadioButton(Pen pen,
Style style,
int x,
int y,
boolean enabled,
boolean focused,
boolean on)
pen - non-null; The pen to use.style - non-null; The style to use.x - X coordinate of the check box (left)y - Y coordinate of the check box (top)enabled - Whether to use the enabled style colors.focused - Whether to use the focused style colors.on - Whether the check box is on and thus has a check mark.
public static void drawRoundedBox(Pen pen,
Style style,
int left,
int top,
int right,
int bottom,
boolean enabled,
boolean focused,
int cornerSize,
boolean hasFrame)
pen - non-null; The pen to use.style - non-null; The style to use.left - left coordinate of the box.top - top coordinate of the box.right - right coordinate of the box.bottom - bottom coordinate of the box.enabled - Whether to use the enabled style colors.focused - Whether to use the focused style colors.cornerSize - arc size of the rounded corners.hasFrame - whether the box has a frame.
public static void drawRoundedBox(Pen pen,
Style style,
int left,
int top,
int right,
int bottom,
boolean enabled,
boolean focused,
int cornerSize,
boolean hasFrame,
boolean clearBackground)
pen - non-null; The pen to use.style - non-null; The style to use.left - left coordinate of the box.top - top coordinate of the box.right - right coordinate of the box.bottom - bottom coordinate of the box.enabled - Whether to use the enabled style colors.focused - Whether to use the focused style colors.cornerSize - arc size of the rounded corners.hasFrame - whether the box has a frame.clearBackground - whether to clear the background before drawing.
public static void drawPickerArrows(Pen pen,
Style style,
int x,
int y,
boolean focused)
pen - non-null; The pen to use.style - non-null; The style to use.x - X coordinate of the arrows.y - Y coordinate of the arrows.focused - Whether to use the focused style colors.
public static void drawPopupArrows(Pen pen,
Style style,
int x,
int y,
int width,
int height,
boolean focused)
pen - non-null; The pen to use.style - non-null; The style to use.x - X coordinate of the arrows.y - Y coordinate of the arrows.width - The width of one arrow.height - The width of one arrow.focused - Whether to use the focused style colors.
public static void drawArrow(Pen pen,
int x,
int y,
int width,
int height,
int direction)
pen - non-null; The pen to use.x - X coordinate of the arrow.y - Y coordinate of the arrow.width - Arrow width.height - Arrow height.direction - One of DIRECTION_DOWN,
DIRECTION_UP, DIRECTION_LEFT,
DIRECTION_RIGHT.
public static void fillArrow(Pen pen,
int x,
int y,
int width,
int height,
int direction)
pen - non-null; The pen to use.x - X coordinate of the arrow.y - Y coordinate of the arrow.width - Arrow width.height - Arrow height.direction - One of DIRECTION_DOWN,
DIRECTION_UP, DIRECTION_LEFT,
DIRECTION_RIGHT.
public static void drawScrollUpArrow(Pen pen,
Style style,
int width,
int y)
pen - non-null; The pen to use.style - non-null; The style to use.width - width of the view to draw the arrow in (the arrow will be centered horizontally)y - Y coordinate of the arrow.
public static void drawScrollDownArrow(Pen pen,
Style style,
int width,
int height)
pen - non-null; The pen to use.style - non-null; The style to use.width - width of the view to draw the arrow in (the arrow will be centered horizontally)height - height of hte view to draw the arrow in (the arrow will be placed near the bottom)public static final int getScrollArrowWidth()
public static final int getScrollArrowHeight()
public static final int getCheckBoxWidth()
public static final int getCheckBoxHeight()
public static final int getRadioButtonWidth()
public static final int getRadioButtonHeight()
public static void drawArrow(Pen pen,
Style style,
int x,
int y,
int width,
int height,
boolean focused,
int direction)
pen - non-null; The pen to use.style - non-null; The style to use.x - X coordinate of the arrow.y - Y coordinate of the arrow.focused - Whether to use the focused style colors.direction - One of DIRECTION_DOWN,
DIRECTION_UP, DIRECTION_LEFT,
DIRECTION_RIGHT.
public static void drawOutlinedArrow(Pen pen,
Style style,
int x,
int y,
int width,
int height,
int direction)
pen - non-null; The pen to use.style - non-null; The style to use.x - X coordinate of the arrow.y - Y coordinate of the arrow.width - Width of the arrow.height - Height of the arrow.direction - One of DIRECTION_DOWN,
DIRECTION_UP, DIRECTION_LEFT,
DIRECTION_RIGHT.public static Style getSystemStyle()
public static Style getDefaultStyle()
public String getAttributeName(int attribute)
attribute - the attribute to get the name of.public int getAttributeType(int attribute)
ATTRIBUTE_COLOR, ATTRIBUTE_FONT,
ATTRIBUTE_GRADIENT.
attribute - the attribute to get the name of.public int attributeCount()
public static Style[] getAvailableStyles()
public static void registerForChanges(Listener listener)
listener - the listener to receive the event. It will be
sent an event of type EventType.EVENT_SYSTEM_STYLE_CHANGED
when the system style changes.public static void unRegisterForChanges(Listener listener)
registerForChanges(danger.app.Listener).
listener - the listener to unregister.public void setImmutable()
public void drawElement(int type,
Pen pen,
View view,
Rect rect)
StyleManager.drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) to draw an element.
You can override this method if you subclass Style.
type - the type of element to draw. This should be one of
BUTTON_FRAME, BUTTON_BACKGROUND, etc.pen - the pen to use to draw the element.view - the View associated with the element to draw.rect - the bounding rectangle of the element.
public void drawButtonFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for BUTTON_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.transparent - whether the element is transparent.
public void drawButtonBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for BUTTON_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.
public void drawDatePickerFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for DATE_PICKER_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.transparent - whether the element is transparent.
public void drawIconPickerFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for ICON_PICKER_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.transparent - whether the element is transparent.
public void drawIconPickerWindowFrame(Pen pen,
Style style,
Rect rect,
View view,
boolean enabled,
boolean focused,
boolean transparent)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for ICON_PICKER_WINDOW_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.enabled - whether the element is enabled.focused - whether the element is focused.transparent - whether the element is transparent.
public void drawImageViewFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for IMAGE_VIEW_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.transparent - whether the element is transparent.
public void drawPopupMenuFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for POPUP_MENU_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.transparent - whether the element is transparent.
public void drawPopupMenuBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for POPUP_MENU_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.transparent - whether the element is transparent.
public void drawRingtonePickerFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for RING_TONE_PICKER_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.transparent - whether the element is transparent.
public void drawSliderFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for SLIDER_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.transparent - whether the element is transparent.
public void drawSliderBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
boolean transparent)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for SLIDER_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.transparent - whether the element is transparent.
public void drawDialogBackground(Pen pen,
Style style,
Rect rect)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for DIALOG_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.
public void drawMenuFrame(Pen pen,
Style style,
Rect rect,
View view,
boolean topIsFlat,
boolean bottomIsFlat)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MENU_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.topIsFlat - whether the top of the menu is flat.bottomIsFlat - whether the bottom of the menu is flat.
public void drawDatePickerWindowFrame(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for DATE_PICKER_WINDOW_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawPickerWindowFrame(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for PICKER_WINDOW_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawMenuBackground(Pen pen,
Style style,
Rect rect,
boolean topIsFlat,
boolean bottomIsFlat)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MENU_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.topIsFlat - whether the top of the menu is flat.bottomIsFlat - whether the bottom of the menu is flat.
public void drawDialogFrame(Pen pen,
Style style,
Rect rect,
DialogWindow window)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for DIALOG_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.window - window to draw the frame for.
public void drawTitleBarBackground(Pen pen,
Style style,
Rect rect,
TitleBar titleBar)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for TITLE_BAR_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.titleBar - the title bar.
public void drawTitleBarPill(Pen pen,
Style style,
Rect rect)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for TITLE_BAR_PILL.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.
public void drawSliderWindowFrame(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for SLIDER_WINDOW_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawFocusedMenuItemBackground(Pen pen,
Style style,
Rect rect,
View view,
int cornerOptions)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for FOCUSED_MENU_ITEM_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.cornerOptions - whether the corners should be rounded
(options same as those for Pen.fillSplitGradientRect(danger.ui.Rect, int, int, int, int[])).
public void drawTabItem(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for TAB_ITEM.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawFocusedTabItem(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for FOCUSED_TAB_ITEM.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawCurrentTabItem(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for CURRENT_TAB_ITEM.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawMovingTabItem(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MOVING_TAB_ITEM.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawMarqueeBackground(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MARQUEE_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawMarqueeFrame(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MARQUEE_FRAME.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawListSelectionBackground(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for LIST_SELECTION_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawDateEditorBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for DATE_EDITOR_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.
public void drawCheckBoxBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for CHECK_BOX_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.
public void drawIconPickerSelectionBackground(Pen pen,
Style style,
Rect rect,
View view)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for ICON_PICKER_SELECTION_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.view - the view associated with the element.
public void drawViewFrame(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused,
int arcSize,
boolean hasFrame,
boolean clearBackground)
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.hasFrame - whether the view has a frame.clearBackground - whether the background should be cleared first.
public void drawMonthViewBackground(Pen pen,
Style style,
Rect rect,
boolean enabled,
boolean focused)
drawElement(int, danger.ui.Pen, danger.ui.View, danger.ui.Rect) for MONTH_VIEW_BACKGROUND.
pen - the pen to use to draw the element.style - the style to draw the element with.rect - the bounding rectangle of the element.enabled - whether the element is enabled.focused - whether the element is focused.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||