YATS/Forge Documentation
 All Classes Namespaces Files Functions Variables Enumerator Pages
net.minecraft.client.gui.FontRenderer Class Reference

Public Member Functions

 FontRenderer (GameSettings par1GameSettings, String par2Str, RenderEngine par3RenderEngine, boolean par4)
 
void readFontData ()
 
int drawStringWithShadow (String par1Str, int par2, int par3, int par4)
 
int drawString (String par1Str, int par2, int par3, int par4)
 
int drawString (String par1Str, int par2, int par3, int par4, boolean par5)
 
int getStringWidth (String par1Str)
 
int getCharWidth (char par1)
 
String trimStringToWidth (String par1Str, int par2)
 
String trimStringToWidth (String par1Str, int par2, boolean par3)
 
void drawSplitString (String par1Str, int par2, int par3, int par4, int par5)
 
int splitStringWidth (String par1Str, int par2)
 
void setUnicodeFlag (boolean par1)
 
boolean getUnicodeFlag ()
 
void setBidiFlag (boolean par1)
 
List listFormattedStringToWidth (String par1Str, int par2)
 
boolean getBidiFlag ()
 

Public Attributes

int FONT_HEIGHT = 9
 
Random fontRandom = new Random()
 

Constructor & Destructor Documentation

net.minecraft.client.gui.FontRenderer.FontRenderer ( GameSettings  par1GameSettings,
String  par2Str,
RenderEngine  par3RenderEngine,
boolean  par4 
)

Member Function Documentation

void net.minecraft.client.gui.FontRenderer.drawSplitString ( String  par1Str,
int  par2,
int  par3,
int  par4,
int  par5 
)

Splits and draws a String with wordwrap (maximum length is parameter k)

int net.minecraft.client.gui.FontRenderer.drawString ( String  par1Str,
int  par2,
int  par3,
int  par4 
)

Draws the specified string.

int net.minecraft.client.gui.FontRenderer.drawString ( String  par1Str,
int  par2,
int  par3,
int  par4,
boolean  par5 
)

Draws the specified string. Args: string, x, y, color, dropShadow

int net.minecraft.client.gui.FontRenderer.drawStringWithShadow ( String  par1Str,
int  par2,
int  par3,
int  par4 
)

Draws the specified string with a shadow.

boolean net.minecraft.client.gui.FontRenderer.getBidiFlag ( )

Get bidiFlag that controls if the Unicode Bidirectional Algorithm should be run before rendering any string

int net.minecraft.client.gui.FontRenderer.getCharWidth ( char  par1)

Returns the width of this character as rendered.

int net.minecraft.client.gui.FontRenderer.getStringWidth ( String  par1Str)

Returns the width of this string. Equivalent of FontMetrics.stringWidth(String s).

boolean net.minecraft.client.gui.FontRenderer.getUnicodeFlag ( )

Get unicodeFlag controlling whether strings should be rendered with Unicode fonts instead of the default.png font.

List net.minecraft.client.gui.FontRenderer.listFormattedStringToWidth ( String  par1Str,
int  par2 
)

Breaks a string into a list of pieces that will fit a specified width.

void net.minecraft.client.gui.FontRenderer.readFontData ( )
void net.minecraft.client.gui.FontRenderer.setBidiFlag ( boolean  par1)

Set bidiFlag to control if the Unicode Bidirectional Algorithm should be run before rendering any string.

void net.minecraft.client.gui.FontRenderer.setUnicodeFlag ( boolean  par1)

Set unicodeFlag controlling whether strings should be rendered with Unicode fonts instead of the default.png font.

int net.minecraft.client.gui.FontRenderer.splitStringWidth ( String  par1Str,
int  par2 
)

Returns the width of the wordwrapped String (maximum length is parameter k)

String net.minecraft.client.gui.FontRenderer.trimStringToWidth ( String  par1Str,
int  par2 
)

Trims a string to fit a specified Width.

String net.minecraft.client.gui.FontRenderer.trimStringToWidth ( String  par1Str,
int  par2,
boolean  par3 
)

Trims a string to a specified width, and will reverse it if par3 is set.

Member Data Documentation

int net.minecraft.client.gui.FontRenderer.FONT_HEIGHT = 9

the height in pixels of default text

Random net.minecraft.client.gui.FontRenderer.fontRandom = new Random()

The documentation for this class was generated from the following file: