This commit is contained in:
Kathy Ruffing 2012-05-03 12:47:43 +00:00
parent b76d2a0c46
commit 079a0ef80e

View File

@ -170,12 +170,27 @@ namespace Volian.Print.Library
}
// if this tab was underlined, we may need to add partial underlining back in, if it was
// removed when the bullet was added.
// removed when the bullet was added. This handles the case where the bullet was appended
// to the tab, for example "NOTE: o".
if (removedUnderline)
{
int sep = origTab.IndexOfAny(". ".ToCharArray());
origTab = @"\ul " + origTab.Substring(0, sep-1) + @"\ulnone" + origTab.Substring(sep-1);
}
// if this tab is underlined, the underlining should not underline the ':'. Check for "NOTE:"
// or "CAUTION:", i.e. only underline up to ':'
if (myparent.MyItemInfo.IsStep && ((myparent.MyItemInfo.FormatStepData.AlwaysTab || myparent.MyItemInfo.MyPrevious == null)
&& ((vFont.Style & E_Style.Underline) > 0) && (origTab.ToUpper().Contains("NOTE:") ||
origTab.ToUpper().Contains("CAUTION:"))))
{
FontStyle style = FontStyle.Regular;
if ((vFont.Style & E_Style.Bold) > 0) style |= FontStyle.Bold;
if ((vFont.Style & E_Style.Italics) > 0) style |= FontStyle.Italic;
vFont.WindowsFont = new System.Drawing.Font(vFont.Family, (float)vFont.Size, style);
int indxC = origTab.IndexOf(":");
origTab = @"\ul " + origTab.Substring(0, indxC) + @"\ulnone" + origTab.Substring(indxC);
}
Rtf = GetRtf(origTab, vFont);
Rtf = Rtf.Replace("\u0394", @"\f1\u916?\f0 "); // delta 0x0394
if (ScriptCaution)