public override string ToString() { var sb = new StringBuilder(); sb.Append(Bold.ToString()); sb.Append("-"); sb.Append(Italic.ToString()); sb.Append("-"); sb.Append(Underline.ToString()); sb.Append("-"); sb.Append(Strikethrough.ToString()); sb.Append("-"); sb.Append(VerticalAlignment.ToString()); sb.Append("-"); sb.Append(Shadow.ToString()); sb.Append("-"); sb.Append(FontSize.ToString()); sb.Append("-"); sb.Append(FontColor); sb.Append("-"); sb.Append(FontName); sb.Append("-"); sb.Append(FontFamilyNumbering.ToString()); return(sb.ToString()); }
public override void Serialize(ref string xml, int indentLevel) { string indent = ""; for (int indentIdx = 0; indentIdx < indentLevel; ++indentIdx) { indent += " "; } xml += string.Format("{0}{1}{2}", indent, "<Element>", Environment.NewLine); base.Serialize(ref xml, indentLevel + 1); xml += string.Format("{0}{1}{2}{3}{4}", indent, "<GumpLink>", System.Web.HttpUtility.HtmlEncode(GumpLink), "</GumpLink>", Environment.NewLine); xml += string.Format("{0}{1}{2}{3}{4}", indent, "<WebColor>", System.Web.HttpUtility.HtmlEncode(WebColor), "</WebColor>", Environment.NewLine); xml += string.Format("{0}{1}{2}{3}{4}", indent, "<Text>", System.Web.HttpUtility.HtmlEncode(Text), "</Text>", Environment.NewLine); xml += string.Format("{0}{1}{2}{3}{4}", indent, "<Underlined>", Underlined.ToString(), "</Underlined>", Environment.NewLine); xml += string.Format("{0}{1}{2}{3}{4}", indent, "<Italicized>", Italicized.ToString(), "</Italicized>", Environment.NewLine); xml += string.Format("{0}{1}{2}{3}{4}", indent, "<Bold>", Bold.ToString(), "</Bold>", Environment.NewLine); xml += string.Format("{0}{1}{2}{3}{4}", indent, "<FontSize>", (int)FontSize, "</FontSize>", Environment.NewLine); xml += string.Format("{0}{1}{2}", indent, "</Element>", Environment.NewLine); }
public override string ToString() { return("[m_bBold=" + Bold.ToString() + ";" + "m_bItalic=" + Italic.ToString() + ";" + "m_nFontSize=" + FontSize.ToString() + ";" + "m_sID=" + ID + ";]" + "Text=" + Text + "]"); }
/// <summary> /// Converts this Font instance to a human-readable string. /// </summary> /// <returns>A string representation of this Font.</returns> public override string ToString() { return(OverrideHelper.ToString( "FontFamilyName", FontFamilyName, "FontSize", FontSize.ToString(), "Italic", Italic.ToString(), "Bold", Bold.ToString(), "WordWrapping", WordWeapping.ToString())); }