TMPFont
命名空间:FairyGUI
源码:Assets/Scripts/Extensions/TextMeshPro/TMPFont.cs (行 15)
public class TMPFont : BaseFont
编译条件:
FAIRYGUI_TMPRO
TextMeshPro text adapter for FairyGUI. Most of codes were taken from TextMeshPro! Note that not all of TextMeshPro features are supported.
继承:BaseFont → TMPFont
继承成员
SupOffset, SupScale, canTint, customBoldAndItalic, customBold, customOutline, keepCrisp, mainTexture, name, shader, textRebuildFlag, version, PrepareCharacters
构造函数
TMPFont()
public TMPFont();
源码:Extensions/TextMeshPro/TMPFont.cs (行 45)
字段
_fontAsset
protected TMP_FontAsset _fontAsset;
源码:Extensions/TextMeshPro/TMPFont.cs (行 17)
方法
BuildGraphics(NGraphics)
public override bool BuildGraphics(NGraphics graphics);
| 参数 | 类型 | 说明 |
|---|---|---|
graphics | NGraphics |
源码:Extensions/TextMeshPro/TMPFont.cs (行 116)
Dispose()
override public void Dispose();
源码:Extensions/TextMeshPro/TMPFont.cs (行 57)
DrawGlyph(VertexBuffer, float, float)
override public void DrawGlyph(VertexBuffer vb, float x, float y);
| 参数 | 类型 | 说明 |
|---|---|---|
vb | VertexBuffer | |
x | float | |
y | float |
源码:Extensions/TextMeshPro/TMPFont.cs (行 442)
DrawLine(VertexBuffer, float, float, float, int, int)
override public void DrawLine(VertexBuffer vb, float x, float y, float width, int fontSize, int type);
| 参数 | 类型 | 说明 |
|---|---|---|
vb | VertexBuffer | |
x | float | |
y | float | |
width | float | |
fontSize | int | |
type | int |
源码:Extensions/TextMeshPro/TMPFont.cs (行 523)
GetGlyph(char, float, float, float)
override public bool GetGlyph(char ch, out float width, out float height, out float baseline);
| 参数 | 类型 | 说明 |
|---|---|---|
ch | char | |
width | float | |
height | float | |
baseline | float |
源码:Extensions/TextMeshPro/TMPFont.cs (行 330)
GetLineHeight(int)
override public int GetLineHeight(int size);
| 参数 | 类型 | 说明 |
|---|---|---|
size | int |
源码:Extensions/TextMeshPro/TMPFont.cs (行 694)
HasCharacter(char)
override public bool HasCharacter(char ch);
| 参数 | 类型 | 说明 |
|---|---|---|
ch | char |
源码:Extensions/TextMeshPro/TMPFont.cs (行 689)
Prepare(TextFormat)
public override void Prepare(TextFormat format);
| 参数 | 类型 | 说明 |
|---|---|---|
format | TextFormat |
源码:Extensions/TextMeshPro/TMPFont.cs (行 109)
SetFormat(TextFormat, float)
override public void SetFormat(TextFormat format, float fontSizeScale);
| 参数 | 类型 | 说明 |
|---|---|---|
format | TextFormat | |
fontSizeScale | float |
源码:Extensions/TextMeshPro/TMPFont.cs (行 301)
StartDraw(NGraphics)
override public void StartDraw(NGraphics graphics);
| 参数 | 类型 | 说明 |
|---|---|---|
graphics | NGraphics |
源码:Extensions/TextMeshPro/TMPFont.cs (行 252)
属性
fontAsset
public TMP_FontAsset fontAsset { get; set; }
源码:Extensions/TextMeshPro/TMPFont.cs (行 62)
fontWeight
public FontWeight fontWeight { get; set; }
源码:Extensions/TextMeshPro/TMPFont.cs (行 72)