CreateFormattedTextWithWrap
(
String sText,
Color oColor,
Double dFontSize
)
{
Debug.Assert(sText != null);
Debug.Assert(dFontSize >= 0);
FormattedText oFormattedText =
m_oFormattedTextManager.CreateFormattedText(sText, oColor,
dFontSize, m_dGraphScale);
if (this.m_bLabelWrapText)
{
oFormattedText.MaxTextWidth =
m_dLabelWrapMaxTextWidth * m_dGraphScale;
oFormattedText.MaxTextHeight = MaximumLabelHeight * m_dGraphScale;
}
else
{
oFormattedText.MaxLineCount = 1;
// (Leave the MaxTextWidth property set to the default value of 0.)
}
return (oFormattedText);
}