B2019-052: Pdf Links for each Referenced Object and Transition within a Step

This commit is contained in:
2019-04-25 13:07:19 +00:00
parent 456909e848
commit cd3656c955
3 changed files with 154 additions and 75 deletions

View File

@@ -130,7 +130,7 @@ namespace Volian.Print.Library
// B2018-034 Attributes were being lost when the IsCompressed flag was true.
// CopyAttributesToNewIParagraph retains any attribute which have been set
Paragraph oldParagraph = _IParagraph;
_IParagraph = RtfToParagraph(myRtf, HasIndent);
_IParagraph = RtfToParagraph(myRtf, HasIndent, MyPageHelper.MyPromsPrinter.SaveLinks);
// B2018-034 Attributes were being lost when the IsCompressed flag was true.
// CopyAttributesToNewIParagraph retains any attribute which have been set
CopyAttributesToNewIParagraph(oldParagraph, _IParagraph);
@@ -433,9 +433,9 @@ namespace Volian.Print.Library
}
public static iTextSharp.text.Paragraph RtfToParagraph(string rtf)
{
return RtfToParagraph(rtf, false);
return RtfToParagraph(rtf, false, false);
}
public static iTextSharp.text.Paragraph RtfToParagraph(string rtf, bool hasIndent)
public static iTextSharp.text.Paragraph RtfToParagraph(string rtf, bool hasIndent, bool doPdfLinks)
{
if (hasIndent)
{
@@ -446,6 +446,7 @@ namespace Volian.Print.Library
IRtfDocument rtfDoc = RtfInterpreterTool.BuildDoc(rtf);
Rtf2iTextSharp rtf2IText = new Rtf2iTextSharp(rtfDoc);
rtf2IText.DoPdfLinks = doPdfLinks;
rtf2IText.HasIndent = hasIndent;
iTextSharp.text.Paragraph para = rtf2IText.Convert();
para.SetLeading(_SixLinesPerInch, 0);