private string StyleRefPart(string reference, RefPartStyle style) { switch (style) { case RefPartStyle.RoundBrackets: return("(" + reference + ")"); case RefPartStyle.SquareBrackets: return("[" + reference + "]"); case RefPartStyle.Braces: return("{" + reference + "}"); case RefPartStyle.LeadingColon: return(":" + reference); case RefPartStyle.LeadingSemiColon: return(";" + reference); case RefPartStyle.TrailingColon: return(reference + ":"); case RefPartStyle.TrailingSemiColon: return(reference + ";"); case RefPartStyle.Italic: case RefPartStyle.Bold: return(reference); } throw new Exception("can't find " + style.ToString()); }
private string StyleRefPart(string reference, RefPartStyle style) { switch (style) { case RefPartStyle.RoundBrackets: return "(" + reference + ")"; case RefPartStyle.SquareBrackets: return "[" + reference + "]"; case RefPartStyle.Braces: return "{" + reference + "}"; case RefPartStyle.LeadingColon: return ":" + reference; case RefPartStyle.LeadingSemiColon: return ";" + reference; case RefPartStyle.TrailingColon: return reference + ":"; case RefPartStyle.TrailingSemiColon: return reference + ";"; case RefPartStyle.Italic: case RefPartStyle.Bold: return reference; } throw new Exception("can't find " + style.ToString()); }