Пример #1
0
 private void ApplyFont(GUIStyle style, FontProperties fp)
 {
     style.normal.textColor = fp.fontColor;
     style.font             = fp.font;
     style.fontSize         = fp.fontSize;
     style.wordWrap         = true;
 }
Пример #2
0
        public GUIStyle GetTextBoxStyle(FontProperties font)
        {
            var style = GUI.skin.textField;

            var fp = font ?? fontProperties;

            if (fp != null)
            {
                ApplyFont(style, fp);
            }

            return(style);
        }
Пример #3
0
        public GUIStyle GetMessageBoxStyle(FontProperties fontProperties)
        {
            var style = new GUIStyle();

            if (fontProperties == null)
            {
                style.normal.textColor = Color.white;
            }
            else
            {
                ApplyFont(style, fontProperties);
            }

            return(style);
        }