public static string StyleText(this string text, IrcFormatText.Style style = IrcFormatText.Style.Reset) { if (style == IrcFormatText.Style.Reset) { return(text); } return (IrcFormatText.StyleChar[IrcFormatText.GetStyleCodeInt(style)] + text + IrcFormatText.StyleChar[IrcFormatText.GetStyleCodeInt(style)] ); }
private static int GetStyleCodeInt(IrcFormatText.Style style) { return((int)style); }