public class FontRenderOptions
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
boolean |
bold
Use bold font
|
int |
color
Color of the text
|
boolean |
disableECF
Disable ECF so char are actually drawn
|
float |
fontScale
Scale for the font
|
boolean |
italic
Use italic font
|
boolean |
shadow
Draw with shadow
|
boolean |
strikethrough
Striketrhough the text
|
boolean |
underline
Underline the text
|
| Constructor and Description |
|---|
FontRenderOptions() |
FontRenderOptions(boolean b) |
FontRenderOptions(FontRenderOptions fro) |
FontRenderOptions(java.lang.String ecfs) |
FontRenderOptions(java.lang.String ecfs,
int color) |
| Modifier and Type | Method and Description |
|---|---|
void |
apply(net.minecraft.util.text.TextFormatting ecf)
Applies the
TextFormatting style to this FontRenderOptions. |
void |
from(FontRenderOptions fro) |
static net.minecraft.util.text.TextFormatting |
getFormatting(java.lang.String text,
int index)
Gets the
TextFormatting at the specified position in the text. |
static Link |
getLink(java.lang.String text,
int index) |
int |
getShadowColor()
Gets the shadow color corresponding to the current color.
|
static boolean |
isFormatting(java.lang.String text,
int index)
Checks if there is a
TextFormatting at the specified position in the text. |
int |
processStyles(java.lang.String text)
Process styles applied to the beginning of the text with
TextFormatting values. |
int |
processStyles(java.lang.String text,
int index)
Process styles applied at the specified position in the text with
TextFormatting values. |
void |
resetStyles() |
void |
resetStylesLine() |
void |
saveDefault() |
void |
setLineFro(FontRenderOptions fro) |
public float fontScale
public int color
public boolean shadow
public boolean bold
public boolean italic
public boolean underline
public boolean strikethrough
public boolean disableECF
public FontRenderOptions()
public FontRenderOptions(boolean b)
public FontRenderOptions(FontRenderOptions fro)
public FontRenderOptions(java.lang.String ecfs)
public FontRenderOptions(java.lang.String ecfs,
int color)
public int processStyles(java.lang.String text)
TextFormatting values.FontRenderOptions and returns the number of characters read.text - the textpublic int processStyles(java.lang.String text,
int index)
TextFormatting values.FontRenderOptions and returns the number of characters read.text - the textindex - the indexpublic void apply(net.minecraft.util.text.TextFormatting ecf)
TextFormatting style to this FontRenderOptions.ecf - the ecfpublic void saveDefault()
public void resetStyles()
public void setLineFro(FontRenderOptions fro)
public void resetStylesLine()
public void from(FontRenderOptions fro)
public int getShadowColor()
public static net.minecraft.util.text.TextFormatting getFormatting(java.lang.String text,
int index)
TextFormatting at the specified position in the text.text - the textindex - the indexpublic static boolean isFormatting(java.lang.String text,
int index)
TextFormatting at the specified position in the text.text - the textindex - the indexpublic static Link getLink(java.lang.String text, int index)