com.mot.lnf
Interface SystemLNF


public interface SystemLNF

Methods used to retrieve look and feel information from the system


Field Summary
static int COLOR_BACKGROUND
          A color specifier for use with the getColor method, specifies the background color of the screen.
static int COLOR_BORDER
          A color specifier for use with the getColor method, identifies the color for boxes and borders when the object is to be drawn in a non-highlighted state.
static int COLOR_FOREGROUND
          A color specifier for use with the getColor method, specifies the foreground color of the screen.
static int COLOR_HIGHLIGHTED_BACKGROUND
          A color specifier for use with the getColor method, identifies the color for the focus, or focus highlight, when it is drawn as a filled in rectangle.
static int COLOR_HIGHLIGHTED_BORDER
          A color specifier for use with the getColor method, identifies the color for boxes and borders when the object is to be drawn in a highlighted state.
static int COLOR_HIGHLIGHTED_FOREGROUND
          A color specifier for use with the getColor method, identifies the color for text characters and simple graphics when they are highlighted.
static int DEFAULT_FONT
          Type specifier to pass into getFont method, indicates the default font of the system.
static int FONT_INPUT_TEXT
          Type specifier to pass into getFont method, indicates the font to be used for drawing input text
static int FONT_STATIC_TEXT
          Type specifier to pass into getFont method, indicates the font to be used for drawing static text
 
Method Summary
 int getBestImageHeight(int type)
          Returns the best image height for a given image type.
 int getBestImageWidth(int type)
          Returns the best image width for a given image type.
 int getBorderStyle(boolean highlighted)
          Retrieve the border style used on this platform.
 int getColor(int type)
          Retrieve a color from the system, in the form 0x00RRGGBB.
 javax.microedition.lcdui.Font getFont(int type)
          Retrieve a font from the system.
 

Field Detail

COLOR_BACKGROUND

public static final int COLOR_BACKGROUND
A color specifier for use with the getColor method, specifies the background color of the screen. The background color will always contrast with the foreground color.

COLOR_FOREGROUND

public static final int COLOR_FOREGROUND
A color specifier for use with the getColor method, specifies the foreground color of the screen. The foreground color will always contrast with the background color.

COLOR_HIGHLIGHTED_BACKGROUND

public static final int COLOR_HIGHLIGHTED_BACKGROUND
A color specifier for use with the getColor method, identifies the color for the focus, or focus highlight, when it is drawn as a filled in rectangle. The highlighted background will always constrast with the highlighted foreground.

COLOR_HIGHLIGHTED_FOREGROUND

public static final int COLOR_HIGHLIGHTED_FOREGROUND
A color specifier for use with the getColor method, identifies the color for text characters and simple graphics when they are highlighted. Highlighted foreground is the color to be used to draw the highlighted text and graphics against the highlighted background. The highlighted foreground will always constrast with the highlighted background.

COLOR_BORDER

public static final int COLOR_BORDER
A color specifier for use with the getColor method, identifies the color for boxes and borders when the object is to be drawn in a non-highlighted state. The border color is intended to be used with the background color and will contrast with it.

COLOR_HIGHLIGHTED_BORDER

public static final int COLOR_HIGHLIGHTED_BORDER
A color specifier for use with the getColor method, identifies the color for boxes and borders when the object is to be drawn in a highlighted state. The highlighted border color is intended to be used with the background color (not the highlighted background color) and will contrast with it.

FONT_STATIC_TEXT

public static final int FONT_STATIC_TEXT
Type specifier to pass into getFont method, indicates the font to be used for drawing static text

FONT_INPUT_TEXT

public static final int FONT_INPUT_TEXT
Type specifier to pass into getFont method, indicates the font to be used for drawing input text

DEFAULT_FONT

public static final int DEFAULT_FONT
Type specifier to pass into getFont method, indicates the default font of the system.
Method Detail

getColor

public int getColor(int type)
Retrieve a color from the system, in the form 0x00RRGGBB. Type specifier is guaranteed to be one of the definitions below.
Parameters:
type - one of COLOR_BACKGROUND, COLOR_FOREGROUND, COLOR_HIGHLIGHTED_BACKGROUND, COLOR_HIGHLIGHTED_FOREGROUND, COLOR_BORDER, or COLOR_HIGHLIGHTED_BORDER
Returns:
color in the form of 0x00RRGGBB

getFont

public javax.microedition.lcdui.Font getFont(int type)
Retrieve a font from the system. Type specifier is guaranteed to be one of the definitions below.
Parameters:
type - one of DEFAULT_FONT, Font.FONT_INPUT_TEXT, or Font.FONT_STATIC_TEXT
Returns:
font matching the type

getBestImageWidth

public int getBestImageWidth(int type)
Returns the best image width for a given image type. The image type must be one of Display.LIST_ELEMENT, Display.CHOICE_GROUP_ELEMENT, or Display.ALERT
Parameters:
type - one of Display.LIST_ELEMENT, Display.CHOICE_GROUP_ELEMENT, or Display.ALERT
Returns:
the best image width for the image type, may be zero if there is no best size; must not be negative

getBestImageHeight

public int getBestImageHeight(int type)
Returns the best image height for a given image type. The image type must be one of Display.LIST_ELEMENT, Display.CHOICE_GROUP_ELEMENT, or Display.ALERT
Parameters:
type - one of Display.LIST_ELEMENT, Display.CHOICE_GROUP_ELEMENT, or Display.ALERT
Returns:
the best image height for the image type, may be zero if there is no best size; must not be negative

getBorderStyle

public int getBorderStyle(boolean highlighted)
Retrieve the border style used on this platform. Returns one of Graphics.SOLID or Graphics.DOTTED
Parameters:
highlighted - false indicates the state when an Item does not have cursor focus. true indicates the state when an Item does have cursor focus
Returns:
return the style used for drawing an Item's border