| ||
Introducing SharpPlot Your First Chart Recent Updates Sample Charts Tutorials General Tutorials Chart Tutorials SharpPlot Class Properties Methods Structures Enumerations Style examples Active Charts VectorMath Class DBUtil Class Get SharpPlot Download SharpPlot Buying SharpPlot SharpPlot Support Upgrading from GraPL Release notes |
Reference > Glossaries > Formatting text with simple HTML tags Formatting text with simple HTML tagsSharpPlot allows a limited subset of HTML tags to be included in all text elements, typically headings or axis labels. The tags which may be used in all output formats are: <b> – to bold a section of text For example: sp.Heading = "Data for Current Year<sup>1</sup> for <b>all</b> Products"; This will format the text in the main chart heading, which may refer to Note-1 elsewhere in the output. Note that you can use these HTML tags in text formatting strings, for example: sp.LabelLineSpacing = 1.4; sp.XDateFormat = "MMM\nyyyy"; sp.XLabelFormat = "X~~X<b>XXXX</b>"; This can be used with Spanned labelling to generate monthly labels (with the first letter of the month name) and a bolded year centred under the available months. Charts saved as VMLIn this one case, you can use any HTML tags in your text, as they are simply passed directly into the output. However please be aware that SharpPlot will not measure text correctly if you use the <font> tag to change the text size, and as a result captions and Y-Labels may not wrap correctly. For output saved as VML, SVG PDF or XAML, you may include hyperlink references in the text. For PDF and the various raster formats, superscripts and subscripts will not be underlined even if an underlined font is used in the main text. This improves the appearance of footnote references. |