Print Page | Close Window

Mirrored text when add text to PDF 1.7

Printed From: Debenu Quick PDF Library - PDF SDK Community Forum
Category: For Users of the Library
Forum Name: I need help - I can help
Forum Description: Problems and solutions while programming with the Debenu Quick PDF Library and Debenu PDF Viewer SDK
URL: http://www.quickpdf.org/forum/forum_posts.asp?TID=3440
Printed Date: 06 May 24 at 12:49AM
Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com


Topic: Mirrored text when add text to PDF 1.7
Posted By: Quick PDF user_12
Subject: Mirrored text when add text to PDF 1.7
Date Posted: 14 Feb 17 at 10:59AM
Hello,

I have an issue with converting from PDF 1.7 saved in acrobat 8x.
I am user of Quick pdf ver 8, 10 and already 13 and the issue is the same in all of them. Text is mirrored so cannod be read.
When I convert PDF 1.4 saved in acrobat 5x everything is ok.
In ver 13 new PDF give 0 all the time. Cannot get proper value when page is rotated. This is a problem also.

Please find formula below:
procedure TForm1.Button12Click(Sender: TObject);
var wydawanie:boolean;
b:integer;
begin
wydawanie:=false;

pdflibrary1:=TDebenuPDFLibrary.Create;
if not boolean(pdflibrary1.UnlockKey(V13_Version_Key)) then showmessage('BAD Version QPDF');

pdflibrary1.LoadFromFile(extractfilepath(application.exename)+'PDF 1.7 (Acrobat 8.x).pdf','');
pdflibrary1.SetTextSize(12);
pdflibrary1.DrawRotatedText(20,60,90,rec.rITEM+', DATA WAZNOSCI: '+DOKWAZNYINFO.DATAW+', NUMER EGZ.:'+DOKWAZNYINFO.NUMERDOK_EGZEMP+', OBSZAR: '+DOKWAZNYINFO.LASTObszarprodukcyjny);
pdflibrary1.DrawRotatedText(32,60,90,'DATA ZATWIERDZENIA: '+DOKWAZNYINFO.DATAZAT+', ZATWIERDZONE PRZEZ: '+DOKWAZNYINFO.OSOBA+' .................');

label37.caption:=inttostr(pdflibrary1.PageRotation);    //WHY ALWAYS 0 for 1.5 and 1.7 PDF ?

if not WYDAWANIE then begin
pdflibrary1.SetTextSize(14);
pdflibrary1.DrawRotatedText(580,800,270,'SYMULACJA WYDRUKU ! DOKUMENT NIE PRZEZNACZONY NA PRODUKCJE !');
pdflibrary1.DrawText(10,10,'SYMULACJA WYDRUKU ! DOKUMENT NIE PRZEZNACZONY NA PRODUKCJE !');
pdflibrary1.DrawText(10,830,'SYMULACJA WYDRUKU ! DOKUMENT NIE PRZEZNACZONY NA PRODUKCJE !');
pdflibrary1.SetTextSize(12);
end;

for b:=1 to pdflibrary1.PageCount do begin
pdflibrary1.SelectPage(b);               
pdflibrary1.SetTextSize(12);
pdflibrary1.DrawRotatedText(20,60,90,rec.rITEM+', DATA WAZNOSCI: '+DOKWAZNYINFO.DATAW+', NUMER EGZ.:'+DOKWAZNYINFO.NUMERDOK_EGZEMP+', OBSZAR: '+DOKWAZNYINFO.LASTObszarprodukcyjny);
pdflibrary1.DrawRotatedText(32,60,90,'DATA ZATWIERDZENIA: '+DOKWAZNYINFO.DATAZAT+', ZATWIERDZONE PRZEZ: '+DOKWAZNYINFO.OSOBA+' .................');
if not WYDAWANIE then begin

pdflibrary1.SetTextSize(14);
pdflibrary1.DrawRotatedText(580,800,270,'SYMULACJA WYDRUKU ! DOKUMENT NIE PRZEZNACZONY NA PRODUKCJE !');
pdflibrary1.DrawText(10,10,'SYMULACJA WYDRUKU ! DOKUMENT NIE PRZEZNACZONY NA PRODUKCJE !');
pdflibrary1.DrawText(10,830,'SYMULACJA WYDRUKU ! DOKUMENT NIE PRZEZNACZONY NA PRODUKCJE !');
pdflibrary1.SetTextSize(12);
end;

end;

application.ProcessMessages;
if pdflibrary1.SaveToFile(extractfilepath(application.exename)+'PDF 1.7 (Acrobat 8.x).pdf') = 0 then begin
showmessage('Save error!');
end;

try
pdflibrary1.free;
except
end;


end;

Please tell me if I am doing smth wrong.
Regards




Replies:
Posted By: Wheeley
Date Posted: 15 Feb 17 at 12:34AM
Have you checked the drawing origin (GetOrigin/SetOrigin) of the PDF? It is probably not what you are expecting.

Wheeley


Posted By: Quick PDF user_12
Date Posted: 15 Feb 17 at 6:26AM
Yes, it is ok, PDF itself is ok but mirrored is only text I want to add extra using quick PDF library on page sides. I use this in PDF 1.4 by years and everything was OK. I am not sure if it is bug or new functionality I am not aware of.


Posted By: Quick PDF user_12
Date Posted: 15 Feb 17 at 9:53AM
http://pl.tinypic.com/view.php?pic=206fvyg&s=9

Picture of faulty result linked above.


Posted By: Ingo
Date Posted: 15 Feb 17 at 7:24PM
Hi Number 12 ;-)

you should try combinecontentstreams and normalizepage.
Read about it in the online reference then you know what i mean.

Cheers and welcome here,
Ingo



-------------
Cheers,
Ingo



Posted By: Quick PDF user_12
Date Posted: 16 Feb 17 at 10:13AM
It looks like finction normalizepage have to be used in all versions >1.6. I didn't know about that. It for sure helps but I will check if all issues are solved using it.

Thank You very much for Your help.


Posted By: HIolemis1
Date Posted: 26 May 17 at 9:38AM
Thanks for the sharing. http://qingzhiliao.com/unblocked-hacked-game.html" rel="nofollow - unblocked game I have been looking for them for a long time.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 11.01 - http://www.webwizforums.com
Copyright ©2001-2014 Web Wiz Ltd. - http://www.webwiz.co.uk