ru.biosoft.graphics
Class TextView
java.lang.Object
ru.biosoft.graphics.View
ru.biosoft.graphics.TextView
- public class TextView
- extends View
| Fields inherited from class ru.biosoft.graphics.View |
ACTIVE, at, BASELINE, BOTTOM, CENTER, HIDE, LEFT, model, RIGHT, shape, TOP, type |
|
Constructor Summary |
TextView(java.lang.String text,
ColorFont font,
java.awt.Graphics graphics)
|
TextView(java.lang.String text,
java.awt.Point pt,
int alignment,
ColorFont font,
java.awt.Graphics graphics)
|
|
Method Summary |
java.awt.Rectangle |
getBounds()
Returns an integer Rectangle that completely encloses the
View. |
java.awt.Rectangle |
getTextPos(int from,
int to,
java.awt.FontMetrics fm)
|
void |
initSize(java.awt.Graphics graphics)
|
void |
move(int x,
int y)
Moves View to the new location using specified offsets. |
void |
paint(java.awt.Graphics2D g)
Paints this view on specified Graphics2D. |
| Methods inherited from class ru.biosoft.graphics.View |
getModel, getShape, intersects, isActive, isVisible, move, scale, setActive, setLocation, setLocation, setModel, setToScale, setVisible, updateBounds |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
text
protected java.lang.String text
alignment
protected int alignment
y
protected int y
rect
protected java.awt.Rectangle rect
font
protected ColorFont font
TextView
public TextView(java.lang.String text,
java.awt.Point pt,
int alignment,
ColorFont font,
java.awt.Graphics graphics)
TextView
public TextView(java.lang.String text,
ColorFont font,
java.awt.Graphics graphics)
initSize
public void initSize(java.awt.Graphics graphics)
getTextPos
public java.awt.Rectangle getTextPos(int from,
int to,
java.awt.FontMetrics fm)
getBounds
public java.awt.Rectangle getBounds()
- Description copied from class:
View
- Returns an integer
Rectangle that completely encloses the
View.
- Overrides:
getBounds in class View
- Returns:
- an integer
Rectangle that completely encloses the
View.
move
public void move(int x,
int y)
- Description copied from class:
View
- Moves View to the new location using specified offsets.
- Specified by:
move in class View
- Parameters:
x - offset along the X axis direction.y - offset along the Y axis direction.
paint
public void paint(java.awt.Graphics2D g)
- Description copied from class:
View
- Paints this view on specified Graphics2D.
- Overrides:
paint in class View
- Parameters:
g - specified Graphics2D.
Copyright © 2001-2003 Biosof.Ru. All Rights Reserved.