This commit is contained in:
Kathy Ruffing 2011-07-14 16:10:45 +00:00
parent 5362b9f4d0
commit f759fe89a7

View File

@ -15,6 +15,8 @@ namespace Volian.Print.Library
{ {
public partial class PrintOverride public partial class PrintOverride
{ {
public static bool CompressSub = false;
public static bool CompressSuper = false;
private static System.Drawing.Color _TextColor = System.Drawing.Color.Empty; private static System.Drawing.Color _TextColor = System.Drawing.Color.Empty;
public static System.Drawing.Color TextColor public static System.Drawing.Color TextColor
{ {
@ -183,9 +185,15 @@ namespace Volian.Print.Library
if (visualText.Format.IsUnderline) if (visualText.Format.IsUnderline)
chk.SetUnderline(font.Color, 0, 0.05F, 0, -.131F, PdfContentByte.LINE_CAP_ROUND); // Relative Based upon font size chk.SetUnderline(font.Color, 0, 0.05F, 0, -.131F, PdfContentByte.LINE_CAP_ROUND); // Relative Based upon font size
if (visualText.Format.SuperScript > 0) if (visualText.Format.SuperScript > 0)
{
chk.SetTextRise(.25F * chk.Font.Size); chk.SetTextRise(.25F * chk.Font.Size);
if (PrintOverride.CompressSuper) chk.Font.Size = 9;
}
else if (visualText.Format.SuperScript < 0) else if (visualText.Format.SuperScript < 0)
{
chk.SetTextRise(-.25F * chk.Font.Size); chk.SetTextRise(-.25F * chk.Font.Size);
if (PrintOverride.CompressSub) chk.Font.Size = 9;
}
else else
chk.SetTextRise(0); chk.SetTextRise(0);
switch (visualText.Format.Alignment) switch (visualText.Format.Alignment)