internal static string C(string str, Color color, int startIndex, int endIndex) { return(CStringUtils.TryFormat("{0}<color=#{1}>{2}</color>{3}", str.Substring(0, startIndex), ToHexValue(ref color), str.Substring(startIndex, endIndex - startIndex), str.Substring(endIndex) )); }
internal static string Arg(string value) { if (value != null && value.Length > 0) { value = value.Replace(Quote, EscapedQuote); value = value.Replace(SingleQuote, EscapedSingleQuote); if (value.IndexOf(' ') != -1) { value = CStringUtils.TryFormat("\"{0}\"", value); } return(value); } return("\"\""); }
public static string I(string str) { return(CStringUtils.TryFormat("<i>{0}</i>", str)); }
public static string B(string str) { return(CStringUtils.TryFormat("<b>{0}</b>", str)); }
public static string C(string str, Color color) { return(CStringUtils.TryFormat("<color=#{0}>{1}</color>", ToHexValue(ref color), str)); }
internal static string C(string str, CColorCode color) { return(CStringUtils.TryFormat("<color=${0}>{1}</color>", ((int)color).ToString(), str)); }