Class Text
텍스트를 표시하는 GUI 클래스
네임스페이스: Game.Scripts.UI
어셈블리: Assembly-CSharp.dll
Syntax
[MoonSharpUserData]
public class Text : Control
생성자
Text(Rect)
텍스트를 표시하는 GUI 클래스
선언
public Text(Rect rect = null)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
Rect | rect |
Text(string, Rect)
텍스트를 표시하는 GUI 클래스
선언
public Text(string textStr, Rect rect)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
string | textStr | |
Rect | rect |
Text(RectTransform, Control)
텍스트를 표시하는 GUI 클래스
선언
public Text(RectTransform rt, Control original)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
UnityEngine.RectTransform | rt | |
Control | original |
Text(Text)
텍스트를 표시하는 GUI 클래스
선언
public Text(Text text)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
UnityEngine.UI.Text | text |
프로퍼티
autoTranslate
Text 자동 번역 여부 true : 자동 번역 기능을 활성화
선언
public bool autoTranslate { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
bool |
bestFit
textSize를 무시하고 Text 컴포넌트 rect 범위에 맞게 크기를 조정한다
선언
public bool bestFit { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
bool |
color
텍스트 색상
선언
public Color color { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
Color |
font
폰트를 설정합니다.
선언
public Font font { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
Font |
fontStyle
폰트 스타일 0 : Normal 1 : Bold 2 : Italic 3 : Bold and Italic
선언
public int fontStyle { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
int |
horizontalOverflow
Text 가로 영역을 넘어선 글의 처리 방식 true : 가로 범위를 넘어가도록 허용 false : 다음 행으로 내려쓰기
선언
public bool horizontalOverflow { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
bool |
lineSpacing
텍스트 행의 간격입니다.
선언
public float lineSpacing { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
float |
raycastTarget
텍스트의 raycastTarget 속성.
선언
public bool raycastTarget { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
bool |
text
텍스트 문자열
선언
public string text { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
string |
textAlign
텍스트 정렬
0 => UpperLeft 왼쪽 위
1 => UpperCenter 가운데 위
2 => UpperRight 오른쪽 위
3 => MiddleLeft 왼쪽 중간
4 => MiddleCenter가운데 중간
5 => MiddleRight 오른쪽 중간
6 => LowerLeft 왼쪽 아래
7 => LowerCenter 가운데 아래
8 => LowerRight 오른쪽 아래
선언
public int textAlign { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
int |
textSize
텍스트 크기
선언
public int textSize { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
int |
verticalOverflow
Text 세로 영역을 넘어선 글의 처리 방식 true : 세로 범위를 넘어가도록 허용 false : 넘어간 글자는 잘라내어 미표시
선언
public bool verticalOverflow { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
bool |
visible
텍스트 컨트롤의 표시 여부
선언
public override bool visible { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
bool |
재정의
함수
__call(Text, Dictionary<string, object>)
텍스트를 표시하는 GUI 클래스
선언
[MoonSharpUserDataMetamethod("__call")]
public static Text __call(Text self, Dictionary<string, object> style)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
Text | self | |
System.Collections.Generic.Dictionary<TKey, TValue><string, object> | style |
반환
타입 | 설명 |
---|---|
Text |
__call(object, Rect)
텍스트를 표시하는 GUI 클래스
선언
[MoonSharpUserDataMetamethod("__call")]
public static Text __call(object self, Rect rect)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
object | self | |
Rect | rect |
반환
타입 | 설명 |
---|---|
Text |
__call(object, string, Rect)
텍스트를 표시하는 GUI 클래스
선언
[MoonSharpUserDataMetamethod("__call")]
public static Text __call(object self, string textStr, Rect rect)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
object | self | |
string | textStr | |
Rect | rect |
반환
타입 | 설명 |
---|---|
Text |
__pairs(Text)
텍스트를 표시하는 GUI 클래스
선언
[MoonSharpUserDataMetamethod("__pairs")]
public static DynValue __pairs(Text self)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
Text | self |
반환
타입 | 설명 |
---|---|
MoonSharp.Interpreter.DynValue |
DOColor(Color, float)
텍스트의 색깔을 duration 동안 바꾼다.
선언
public override ScriptTweener DOColor(Color c, float duration)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
Color | c | 바꿀 컬러 |
float | duration | 시간 (초) |
반환
타입 | 설명 |
---|---|
ScriptTweener |
재정의
DOText(string, float, bool, string)
타이핑 효과를 나타냅니다.
선언
public ScriptTweener DOText(string endValue, float duration, bool scrambleMode = false, string scrambleText = null)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
string | endValue | 바뀔 텍스트 |
float | duration | 시간 (초) |
bool | scrambleMode | 스크램블 모드 여부 |
string | scrambleText | 스크램블 모드 시 들어갈 텍스트 |
반환
타입 | 설명 |
---|---|
ScriptTweener |
연산자
implicit operator Text(Text)
텍스트를 표시하는 GUI 클래스
선언
public static implicit operator Text(Text text)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
Text | text |
반환
타입 | 설명 |
---|---|
UnityEngine.UI.Text |
implicit operator Text(Text)
텍스트를 표시하는 GUI 클래스
선언
public static implicit operator Text(Text text)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
UnityEngine.UI.Text | text |
반환
타입 | 설명 |
---|---|
Text |