Unity Text 设置不同的文字大小以及颜色

private string ReturnCaptureString(string[] strings)
    {
        string content = "";

        if (strings.Length == 2)
        {

            if (strings[1].Contains(pp))
            {
                string[] conStrs = strings[1].Split(mChar);
                for (int i = 0; i < conStrs.Length; i++)
                {
                    content += "" + conStrs[i] + "" + "\n\r";
                }
            }
            else
            {
                content += "" + strings[1] + "" + "\n\r";
            }
        }
        else if (strings.Length == 3)
        {
            content = "" + strings[1] + "" + "\n\r";

            if (strings[2].Contains(pp))
            {
                string[] conStrs = strings[2].Split(mChar);
                for (int i = 0; i < conStrs.Length; i++)
                {
                    content += "" + conStrs[1] + "" + "\n\r";
                }
            }
            else
            {
                content += "" + strings[2] + "" + "\n\r";
            }
        }
        return content;
    }

你可能感兴趣的:(Unity Text 设置不同的文字大小以及颜色)