Elin Decompiled Documentation EA 23.102 Nightly
Loading...
Searching...
No Matches
UIItem.cs
Go to the documentation of this file.
1using UnityEngine;
2using UnityEngine.UI;
3
4public class UIItem : MonoBehaviour
5{
6 public UIText text1;
7
8 public UIText text2;
9
10 public UIText text3;
11
12 public UIText text4;
13
14 public Image image1;
15
16 public Image image2;
17
19
21
23
24 public UIItem item;
25
26 public Toggle toggle;
27
28 public UIDropdown dd;
29
30 public object refObj;
31
32 public void SetTopic(string lang1, string lang2)
33 {
34 text1.SetText(lang1.lang());
35 text2.SetText(lang2.lang());
36 }
37
38 public void SetWidth(int w)
39 {
40 LayoutElement orCreate = this.GetOrCreate<LayoutElement>();
41 float preferredWidth = (orCreate.minWidth = w);
42 orCreate.preferredWidth = preferredWidth;
43 }
44
45 public void Hyphenate()
46 {
48 {
49 HyphenationJpn hyphenationJpn = text1.GetComponent<HyphenationJpn>() ?? text1.gameObject.AddComponent<HyphenationJpn>();
50 if ((bool)hyphenationJpn)
51 {
52 text1.hyphenation = hyphenationJpn;
53 hyphenationJpn.enabled = true;
54 text1.SetText(text1.text);
55 }
56 }
57 }
58}
bool hyphenation
Definition: LangSetting.cs:38
Definition: Lang.cs:6
static LangSetting setting
Definition: Lang.cs:54
Definition: UIItem.cs:5
Image image2
Definition: UIItem.cs:16
UIText text3
Definition: UIItem.cs:10
UIDropdown dd
Definition: UIItem.cs:28
UIButton button3
Definition: UIItem.cs:22
UIButton button1
Definition: UIItem.cs:18
Image image1
Definition: UIItem.cs:14
void SetTopic(string lang1, string lang2)
Definition: UIItem.cs:32
void SetWidth(int w)
Definition: UIItem.cs:38
UIText text2
Definition: UIItem.cs:8
UIText text4
Definition: UIItem.cs:12
UIButton button2
Definition: UIItem.cs:20
void Hyphenate()
Definition: UIItem.cs:45
UIText text1
Definition: UIItem.cs:6
Toggle toggle
Definition: UIItem.cs:26
object refObj
Definition: UIItem.cs:30
UIItem item
Definition: UIItem.cs:24
Definition: UIText.cs:6
void SetText(string s)
Definition: UIText.cs:159