PurePDF Version 2.0
Re: PurePDF Version 2.0
Hi IdeasVacuum,
i have no idea how to solve your feature request in an easy way. Maybe you should intercept the linebreak like in Tutorial04 Pagebreak.pb.
Hi Loopingstar,
please have a look at Tutorial07 Images.pb it uses pdf_Addlink() and pdf_SetLink() as you need it. You can also have a look at Tutorial08 Bookmarks.pb which uses Bookmarks as refences for Navigation inside the document.
Regards Klaus
i have no idea how to solve your feature request in an easy way. Maybe you should intercept the linebreak like in Tutorial04 Pagebreak.pb.
Hi Loopingstar,
please have a look at Tutorial07 Images.pb it uses pdf_Addlink() and pdf_SetLink() as you need it. You can also have a look at Tutorial08 Bookmarks.pb which uses Bookmarks as refences for Navigation inside the document.
Regards Klaus
-
- User
- Posts: 18
- Joined: Tue Oct 01, 2013 12:57 pm
Re: PurePDF Version 2.0
Thank you ABBKlaus...
But i don't understand the mechanics...
I have another question : There is not "pdf_Free" or "pdf_Close" ?
Because, when i call two times "pdf_Create", his not kill the last...
But i don't understand the mechanics...
I have another question : There is not "pdf_Free" or "pdf_Close" ?
Because, when i call two times "pdf_Create", his not kill the last...
Re: PurePDF Version 2.0
an adequate command for pdf_close() would be pdf_Save("") without filename nothing is saved on disk 

-
- User
- Posts: 18
- Joined: Tue Oct 01, 2013 12:57 pm
Re: PurePDF Version 2.0
Okay folks, here my solution (thank you IdeasVacuum for idea):
I create my PDF one time (without saving) and i put in a LinkedList the Y position and the Page number of each chapter "title".
Then, i create second PDF and for each chapter number link (in chapter text), i search in my LinkedList the good one...
ABBKlaus, thank you for the tips, but i lost Bookmarks!
Here the PDF file with links working http://loopingstar.fr/abc/demo2.pdf
I create my PDF one time (without saving) and i put in a LinkedList the Y position and the Page number of each chapter "title".
Then, i create second PDF and for each chapter number link (in chapter text), i search in my LinkedList the good one...
ABBKlaus, thank you for the tips, but i lost Bookmarks!

Here the PDF file with links working http://loopingstar.fr/abc/demo2.pdf
-
- Always Here
- Posts: 6426
- Joined: Fri Oct 23, 2009 2:33 am
- Location: Wales, UK
- Contact:
Re: PurePDF Version 2.0
Hi guys
Oh page breaks are so much fun - not!
Currently, working on a solution where the multi-line cell height is calculated first, then all cells of that row are passed the height.
Edit: Yup, tested a 43-page document, works fine.
Oh page breaks are so much fun - not!
Currently, working on a solution where the multi-line cell height is calculated first, then all cells of that row are passed the height.
Edit: Yup, tested a 43-page document, works fine.
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
If it sounds simple, you have not grasped the complexity.
-
- User
- Posts: 18
- Joined: Tue Oct 01, 2013 12:57 pm
Re: PurePDF Version 2.0
I solved the problem of bookmarks.
When creating the first pass, I do not create bookmarks. I created bookmarks in the second pass, otherwise it bug.
See PDF with links and bookmarks working http://www.loopingstar.fr/abc/demo3.pdf
When creating the first pass, I do not create bookmarks. I created bookmarks in the second pass, otherwise it bug.
See PDF with links and bookmarks working http://www.loopingstar.fr/abc/demo3.pdf
-
- Always Here
- Posts: 6426
- Joined: Fri Oct 23, 2009 2:33 am
- Location: Wales, UK
- Contact:
Re: PurePDF Version 2.0
...working very nicely Loopingstar 

IdeasVacuum
If it sounds simple, you have not grasped the complexity.
If it sounds simple, you have not grasped the complexity.
-
- User
- Posts: 18
- Joined: Tue Oct 01, 2013 12:57 pm
Re: PurePDF Version 2.0
I have another problem wirth PurePDF 2.08...
When i use pdf_Image(), it does not work with JPEG images.
The file "Tutorial07 Images.pb" dont work in the same manner.
Only PNG file is showing, the last page is blank. TEST > http://loopingstar.fr/abc/Tutorial07%20Images.pdf
Can anyone help me please ?
When i use pdf_Image(), it does not work with JPEG images.
The file "Tutorial07 Images.pb" dont work in the same manner.
Only PNG file is showing, the last page is blank. TEST > http://loopingstar.fr/abc/Tutorial07%20Images.pdf
Can anyone help me please ?
-
- User
- Posts: 18
- Joined: Tue Oct 01, 2013 12:57 pm
Re: PurePDF Version 2.0
Please, anyone can help me ?
i have Purebasic 5.20 TLS X64 (on Windows Seven Pro 64 bits)
pdf_Image() don't work with JPEG pictures.
I have declared UseJPEGImageDecoder() and UseJPEGImageEncoder() without success
I have another problem wirth PurePDF 2.08...
When i use pdf_Image(), it does not work with JPEG images.
The file "Tutorial07 Images.pb" dont work in the same manner.
Only PNG file is showing, the last page is blank. TEST > http://loopingstar.fr/abc/Tutorial07%20Images.pdf
i have Purebasic 5.20 TLS X64 (on Windows Seven Pro 64 bits)
pdf_Image() don't work with JPEG pictures.
I have declared UseJPEGImageDecoder() and UseJPEGImageEncoder() without success
I have another problem wirth PurePDF 2.08...
When i use pdf_Image(), it does not work with JPEG images.
The file "Tutorial07 Images.pb" dont work in the same manner.
Only PNG file is showing, the last page is blank. TEST > http://loopingstar.fr/abc/Tutorial07%20Images.pdf
-
- Always Here
- Posts: 6426
- Joined: Fri Oct 23, 2009 2:33 am
- Location: Wales, UK
- Contact:
Re: PurePDF Version 2.0
Well, personally I only work with PNG images - the quality is superior to JPG for similar file size, especially so if the image has to be re-sized. Why not simply convert your original JPG's to PNG?
irfanview image converter
irfanview image converter
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
If it sounds simple, you have not grasped the complexity.
-
- User
- Posts: 18
- Joined: Tue Oct 01, 2013 12:57 pm
Re: PurePDF Version 2.0
Because the PDF is generated on the fly by the user.
And, in the software, is accepted PNG and JPEG images (PNG format is not widely known by users in general)
and they mostly use the JPEG.
And, in the software, is accepted PNG and JPEG images (PNG format is not widely known by users in general)
and they mostly use the JPEG.
Re: PurePDF Version 2.0
It was a bug !
Thanks for reporting 
Its fixed now : http://www.purebasicpower.de/?download= ... B52X86.zip
Code: Select all
;Check JPEG / PNG
Select PeekL(vData\pData) & $FFFFFFFF

Its fixed now : http://www.purebasicpower.de/?download= ... B52X86.zip
-
- Always Here
- Posts: 6426
- Joined: Fri Oct 23, 2009 2:33 am
- Location: Wales, UK
- Contact:
Re: PurePDF Version 2.0
Well, you have a fix now from KlausBecause the PDF is generated on the fly by the user.

In your code though, you will produce a better PDF using PNG if the image has to be resized. So even if the original image is JPG, your code can internally use PNG before resizing.
That used to be true, but it's the defacto web standard now. Practically everyone that uses a computer should be aware of PNG these days - certainly, you could recommend PNG to your Users for best quality.PNG format is not widely known by users in general
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
If it sounds simple, you have not grasped the complexity.
- StarBootics
- Addict
- Posts: 1006
- Joined: Sun Jul 07, 2013 11:35 am
- Location: Canada
Re: PurePDF Version 2.0
Hello everyone,
A simple technical question : Is there a limit in size for a picture that can be inserted into a pdf file ?
I ask this because I'm trying to replace a the original logo of 102 X 46 pixel used in the "Tutorial07 Images.pb" by a logo 438 X 200 pixel but it's not working.
Regards
StarBootics
A simple technical question : Is there a limit in size for a picture that can be inserted into a pdf file ?
I ask this because I'm trying to replace a the original logo of 102 X 46 pixel used in the "Tutorial07 Images.pb" by a logo 438 X 200 pixel but it's not working.
Regards
StarBootics
The Stone Age did not end due to a shortage of stones !
-
- User
- Posts: 18
- Joined: Tue Oct 01, 2013 12:57 pm
Re: PurePDF Version 2.0
Thank you for this change, ABBKlaus.
I installed the new version of the lib.
But I found a new bug:
According to my tests, if the size (width, height) of the JPEG image is less than the page size, it works.
But if the size of JPEG image is larger than the page size, the image is not displayed.
This problem does not exist with PNG images.
I installed the new version of the lib.
But I found a new bug:
According to my tests, if the size (width, height) of the JPEG image is less than the page size, it works.
But if the size of JPEG image is larger than the page size, the image is not displayed.
This problem does not exist with PNG images.