public class Label extends Shape
Constructor and Description |
---|
Label(double... coord)
Constructor.
|
Label(java.lang.String text,
double[] coord)
Constructor.
|
Label(java.lang.String text,
double rotation,
double[] coord)
Constructor.
|
Label(java.lang.String text,
double horizontalReference,
double verticalReference,
double[] coord)
Constructor.
|
Label(java.lang.String text,
double horizontalReference,
double verticalReference,
double rotation,
double[] coord)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
coordToString(double... c)
Convert coordinate to a string.
|
double[] |
getCoordinate()
Returns the coordinates of label.
|
java.awt.Font |
getFont()
Returns the font of label.
|
double |
getRotation()
Returns the rotation angel of label.
|
java.lang.String |
getText()
Returns the text of label.
|
void |
paint(Graphics g)
Draw the component with given graphics object.
|
Label |
setCoordinate(double... coord)
Set the coordinate of label.
|
Label |
setFont(java.awt.Font font)
Set the font of label.
|
Label |
setRotation(double angle)
Set the rotation angel of label.
|
Label |
setText(java.lang.String text)
Set the text of label.
|
public Label(java.lang.String text, double[] coord)
public Label(java.lang.String text, double rotation, double[] coord)
public Label(java.lang.String text, double horizontalReference, double verticalReference, double[] coord)
public Label(java.lang.String text, double horizontalReference, double verticalReference, double rotation, double[] coord)
public Label(double... coord)
public Label setText(java.lang.String text)
public java.lang.String getText()
public Label setCoordinate(double... coord)
public double[] getCoordinate()
public Label setRotation(double angle)
public double getRotation()
public Label setFont(java.awt.Font font)
public java.awt.Font getFont()
public void paint(Graphics g)
Shape
public static java.lang.String coordToString(double... c)