Class GUIText
- java.lang.Object
-
- de.coreengine.rendering.renderable.gui.GUIText
-
public class GUIText extends Object
Class that represents a renderable text- Author:
- Darius Dinger
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GUIText.Alignment
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description GUIChar[]
getChars()
String
getFont()
Color
getFontColor()
float
getFontSize()
String
getText()
void
setAlignment(GUIText.Alignment alignment)
Setting the text alignment.void
setFont(String font)
Setting font of the text and recreating charsvoid
setFontSize(float fontSize)
void
setPadding(float padding)
void
setText(String text)
Setting text and recreating chars
-
-
-
Method Detail
-
setText
public void setText(String text)
Setting text and recreating chars- Parameters:
text
- New text of the GUIText
-
getText
public String getText()
- Returns:
- Text of the GUIText
-
setFont
public void setFont(String font)
Setting font of the text and recreating chars- Parameters:
font
- New font of the text
-
setAlignment
public void setAlignment(GUIText.Alignment alignment)
Setting the text alignment. Text will be aligned CENTERED, on the RIGHT or LEFT edge of the GUIPane (note the padding).- Parameters:
alignment
- New alignment
-
getFont
public String getFont()
- Returns:
- Font of the text
-
setFontSize
public void setFontSize(float fontSize)
- Parameters:
fontSize
- New size of the font
-
getChars
public GUIChar[] getChars()
- Returns:
- Characters of the text to render
-
getFontSize
public float getFontSize()
- Returns:
- Font size of the text
-
setPadding
public void setPadding(float padding)
- Parameters:
padding
- Padding of the gui text to the pane border
-
getFontColor
public Color getFontColor()
- Returns:
- Read/writeable color of the text/font
-
-