internal static LabelMixedTextStyle FromJson(JsonObject json)
{
if (json == null) return null;
LabelMixedTextStyle textStyle = new LabelMixedTextStyle();
textStyle.DefaultStyle = ServerTextStyle.FromJson((JsonObject)json["defaultStyle"]);
textStyle.Separator = (string)json["separator"];
textStyle.SeparatorEnabled = (bool)json["separatorEnabled"];
if ((JsonArray)json["splitIndexes"] != null && ((JsonArray)json["splitIndexes"]).Count > 0)
{
List<int> list = new List<int>();
foreach (int item in (JsonArray)json["splitIndexes"])
{
list.Add(item);
}
textStyle.SplitIndexes = list;
}
if (json["styles"] != null)
{
List<ServerTextStyle> textStyleList = new List<ServerTextStyle>();
foreach (JsonObject item in (JsonArray)json["styles"])
{
textStyleList.Add(ServerTextStyle.FromJson(item));
}
textStyle.Styles = textStyleList;
}
return textStyle;
}