|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--sub_arctic.output.simple_text_renderer | +--sub_arctic.output.gradient_text_renderer | +--sub_arctic.output.radial_gradient_text
Object for drawing of text with a radial gradient pattern in one of several standard styles.
Field Summary | |
protected int |
_draw_style
Drawing style used for gradient. |
static int |
BL_GRAD
Style code constant for top-left centered gradient |
static int |
BR_GRAD
Style code constant for top-left centered gradient |
static int |
CENT_GRAD
Style code constant for centered gradient |
static int |
LAST_GRAD_STYLE
Last valid style code value |
static int |
TL_GRAD
Style code constant for top-left centered gradient |
static int |
TR_GRAD
Style code constant for top-left centered gradient |
Fields inherited from class sub_arctic.output.gradient_text_renderer |
_draw_gradient |
Fields inherited from class sub_arctic.output.simple_text_renderer |
_draw_color,
_draw_font,
_metrics |
Constructor Summary | |
radial_gradient_text(java.awt.Font in_font,
gradient in_grad,
int in_style)
Construct a renderer given a Font, a gradient, and a style code. |
Method Summary | |
int |
draw_style()
Drawing style used for gradient. |
void |
draw_text(drawable on_surface,
int at_x,
int at_y,
java.lang.String txt)
Render text onto the given drawable object at the given location. |
void |
set_draw_gradient(gradient grad)
Set the gradient to draw text in. |
void |
set_draw_gradient(radial_gradient grad)
Set the gradient to draw text in. |
void |
set_draw_style(int style_code)
Set the drawing style used for gradient. |
Methods inherited from class sub_arctic.output.gradient_text_renderer |
draw_gradient |
Methods inherited from class sub_arctic.output.simple_text_renderer |
baseline,
draw_color,
draw_font,
h,
leading,
set_draw_color,
set_draw_font,
w |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Field Detail |
public static final int TL_GRAD
public static final int BL_GRAD
public static final int TR_GRAD
public static final int BR_GRAD
public static final int CENT_GRAD
public static final int LAST_GRAD_STYLE
protected int _draw_style
Constructor Detail |
public radial_gradient_text(java.awt.Font in_font, gradient in_grad, int in_style)
Font
- in_font font that this renderer uses.radial_gradient
- in_grad gradient that the actual text is drawn
with.int
- in_style style code indicating direction of
gradient. Must be one of:
{TL,BL,TR,BR,CENT}_GRAD.Method Detail |
public void set_draw_gradient(gradient grad)
gradient
- grad the new radial gradient for drawingpublic void set_draw_gradient(radial_gradient grad)
radial_gradient
- grad the new gradient for drawingpublic int draw_style()
public void set_draw_style(int style_code)
int
- style_code the new drawing style code.public void draw_text(drawable on_surface, int at_x, int at_y, java.lang.String txt)
drawable
- on_surface the drawing surface where we draw the result.int
- at_x x coordinate to draw at.int
- at_y y coordinate to draw at.String
- txt the text to draw.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |