Class DiagramText
java.lang.Object
org.stathissideris.ascii2image.graphics.DiagramComponent
org.stathissideris.ascii2image.graphics.DiagramText
-
Field Summary
-
Constructor Summary
ConstructorDescriptionDiagramText
(int x, int y, String text, Font font, FontMeasurer fontMeasurer) -
Method Summary
Modifier and TypeMethodDescriptionvoid
alignRightEdgeTo
(int x) void
centerHorizontallyBetween
(int minX, int maxX) void
centerInBounds
(Rectangle2D bounds) void
centerVerticallyBetween
(int minY, int maxY) getColor()
getFont()
getText()
int
getXPos()
int
getYPos()
boolean
boolean
void
void
void
setHasOutline
(boolean hasOutline) void
setOutlineColor
(Color outlineColor) void
void
setTextOnLine
(boolean b) void
setXPos
(int i) void
setYPos
(int i) toString()
Methods inherited from class org.stathissideris.ascii2image.graphics.DiagramComponent
createClosedFromBoundaryCells, createClosedFromBoundaryCells, makePointForCell
-
Field Details
-
DEFAULT_COLOR
-
-
Constructor Details
-
DiagramText
-
-
Method Details
-
centerInBounds
-
centerHorizontallyBetween
public void centerHorizontallyBetween(int minX, int maxX) -
centerVerticallyBetween
public void centerVerticallyBetween(int minY, int maxY) -
alignRightEdgeTo
public void alignRightEdgeTo(int x) -
getColor
- Returns:
-
getFont
- Returns:
-
getText
- Returns:
-
getXPos
public int getXPos()- Returns:
-
getYPos
public int getYPos()- Returns:
-
setColor
- Parameters:
color
-
-
setFont
- Parameters:
font
-
-
setText
- Parameters:
string
-
-
setXPos
public void setXPos(int i) - Parameters:
i
-
-
setYPos
public void setYPos(int i) - Parameters:
i
-
-
getBounds
-
toString
-
isTextOnLine
public boolean isTextOnLine()- Returns:
-
setTextOnLine
public void setTextOnLine(boolean b) - Parameters:
b
-
-
hasOutline
public boolean hasOutline() -
setHasOutline
public void setHasOutline(boolean hasOutline) -
getOutlineColor
-
setOutlineColor
-