i have to
build one PDF file from many RTF files placed somewhere on the storage. So I
used the Aspose.Words package to convert the RTF content to a PDF file.
Furthermore
I build a new PDF file with a background with the Aspose.Pdf package with the text content of the converted RTF file (this is a pdf File) before. This final PDF
file has watermarks and backgrounds but the RTF file not.
And now the
problem is that the text parts in the final PDF file were horizontally
mirrored. The question is, why is that so?? I have spent hours for debugging
and looking for any wrong configured parameter in the TextInfo or Font
namespace, but I've found nothing.
The
steps in pseudo code briefly:
1 Create a
PDF with background
2 Convert a
RTF file to a PDF file to the variable “RTFfile”
3 Place the
PDF Text from the converted RTFfile to the PDF File with the background as created in step 1
Do steps 2
and 3 n times.
Used
code:
For step 1:
The
background file is placed with the FloatingBox and the
Adobe.Pdf.Generator.Pdf.Watermarks object.
For step 2:
I used the
Aspose.Words.Document Save method, to save the RTF file as a PDF file.
For step 3:
I used the
Aspose.Pdf.Document Object, the Aspose.Pdf.Text.TextFragmentAbsorber to find
all the phrases in the pdf file. (The constructor is also empty and has no
string). To insert all the new Text Fragments I used the textFragmentCollection
and TextBuilder to Append the content to
the PDF file with background and watermarks. In all the steps I append the new
Text phrases to the PDF with the background.
My question
is, why are the new inserted text fragments horizontally mirrored without having
setting this option. Is this a bug?
I have tested there scenario where I have used Aspose.Words for .NET 11.10.0 and Aspose.Pdf for .NET 8.1.0 and I am unable to notice any problem. Can you please share the resource files which you are using so that we can test the scenario at our end.
In order to add Image/text watermark while creating PDF file, I have used code snippet present over Customizing Watermark
The target is to maintain the font style with text color and so on...
With your solution i only have the text.
When i implement the method with the TextFragmentAbsorber Class and add the textfragments objects to the existing pdf File, i have the right text with the right format but horizontally mirrored ;)
I am using Aspose.Words for .NET 13.5 and Aspose.Pdf .NET 8.1
Can you please share the source PDF files and the code snippet that you are using so that we can test the scenario at our end. We apologize for this inconvenience.
I have tested the scenario and I am able to
notice the same problem. For the sake of correction, I have logged this issue
as PDFNEWNET-35544 in our issue tracking system. We will
further look into the details of this problem and will keep you updated on the
status of correction. Please be patient and spare us little time. We are sorry
for this inconvenience.
Thanks for your inquiry. I’m afraid your reported issue has not been resolved completely. We’ve requested our development team to share an ETA at their earliest. We will update you as soon as we get a feedback.
We are sorry that earlier logged issue could not get resolved due to other high priority implementations in the API. Furthermore, the specific document provided with the issue had some concrete features which need to be investigated in details. Nevertheless, we have recorded your concerns and will let you know in case some certain progress is made towards issue resolution. Please spare us little time.