PurePDF Version 2.0
Re: PurePDF Version 2.0
Thanks Klaus,
I got the decoding part to work
but i don't understand how to pass the content of a file to encode function
I got the decoding part to work
but i don't understand how to pass the content of a file to encode function
Re: PurePDF Version 2.0
Code: Select all
If ReadFile(0,"C:\somefile.txt")
ASCII85.MEM_DataStructure
ASCII85\pData=AllocateMemory(Lof(0))
ASCII85\lCurSize=Lof(0)
ASCII85\lMaxSize=Lof(0)
ReadData(0,ASCII85\pData,Lof(0))
CloseFile(0)
Characters_per_line=60
If pdf_ASCII85_Encode(@ASCII85,Characters_per_line)
Message$=Chr(13)+Chr(13)+"Buffer = "+Str(ASCII85\lCurSize)+" Bytes !"
Encoded_ASCII85$=PeekS(ASCII85\pData,-1,#PB_Ascii)
MessageRequester("ASCII85 Encode",Encoded_ASCII85$+Message$)
BufferLen=4096
Buffer=AllocateMemory(BufferLen)
If pdf_ASCII85_Decode(ASCII85\pData,ASCII85\lCurSize,Buffer,@OutBufferLen)=0
Message$=Chr(13)+Chr(13)+"Buffer = "+Str(OutBufferLen)+" Bytes !"
Decoded_ASCII85$=PeekS(Buffer,-1,#PB_Ascii)
MessageRequester("ASCII85 Decoded",Decoded_ASCII85$+Message$)
EndIf
EndIf
EndIf
Re: PurePDF Version 2.0
Hi,
I have used the pdf library with a lot of success. Many thanks.
In one application I have a full page background picture over which I print text and also place a logo, which is in PNG format. This works very well except I cannot find how to make the borders to the logo transparent, so my logo appears in a rectangular white box. The docs for pdf_Image() say that I need to specify a transparent colour, but I don't know how to do this. Can it be done with MS Paint or Paint.net?
Any suggestions are most welcome.
RichardL
I have used the pdf library with a lot of success. Many thanks.
In one application I have a full page background picture over which I print text and also place a logo, which is in PNG format. This works very well except I cannot find how to make the borders to the logo transparent, so my logo appears in a rectangular white box. The docs for pdf_Image() say that I need to specify a transparent colour, but I don't know how to do this. Can it be done with MS Paint or Paint.net?
Any suggestions are most welcome.
RichardL
Re: PurePDF Version 2.0
i think the documenation is wrong on that part because it says :
BR Klausbut are not supported:
- interlacing
- alpha channel
Re: PurePDF Version 2.0
Regarding the images I have some questions and ideas:
- Is it possible to add a paperless format or is something like this already implemented?
- We can add images by full filename or memory address, I think it would be good to just pass a PureBasic ImageNr as well. Is there a restriction or could this be done easily?
- How can I add an image so that it always fits best the paper size and without loss of resolution?
- Is it possible to add a paperless format or is something like this already implemented?
- We can add images by full filename or memory address, I think it would be good to just pass a PureBasic ImageNr as well. Is there a restriction or could this be done easily?
- How can I add an image so that it always fits best the paper size and without loss of resolution?
If any of you native English speakers have any suggestions for the above text, please let me know (via PM). Thanks!
Re: PurePDF Version 2.0
How to change a space between lines in PurePDF? I want to change a space between lines in document with PurePDF but i cannot find a way to do it. I used Chunk and Paragraph for output text but they haven't any properties to change space between lines. Please help.
Sorry for my bad English =)
Sorry for my bad English =)
Re: PurePDF Version 2.0
With this PurePDF it could look like this :
But i guess you are looking for the purepdf Flash/Actionscript library for creating PDF files
http://code.google.com/p/purepdf/
Code: Select all
pdf_Create()
pdf_AddPage()
pdf_SetMargins(30,10,30)
pdf_SetFont("Arial","",12)
txt$ = "Test"
pdf_SetX(30)
pdf_Write(5,txt$)
pdf_Ln(4)
pdf_Write(5,txt$)
pdf_Ln(5)
pdf_Write(5,txt$)
pdf_Ln(6)
pdf_Write(5,txt$)
pdf_Ln(7)
pdf_Write(5,txt$)
pdf_Save("Test.pdf")
http://code.google.com/p/purepdf/
- DoubleDutch
- Addict
- Posts: 3219
- Joined: Thu Aug 07, 2003 7:01 pm
- Location: United Kingdom
- Contact:
Re: PurePDF Version 2.0
lol
https://deluxepixel.com <- My Business website
https://reportcomplete.com <- School end of term reports system
https://reportcomplete.com <- School end of term reports system
Re: PurePDF Version 2.0
small update, PurePDF V2.20 :
PurePDF V2.20 (for PB4.5x x86)
Download :- added pdf_GetMultiCellNewLines()
- fixed pdf_Cell() removes newlines and linefeeds at the end of each line
PurePDF V2.20 (for PB4.5x x86)
- Thorsten1867
- Addict
- Posts: 1366
- Joined: Wed Aug 24, 2005 4:02 pm
- Location: Germany
Re: PurePDF Version 2.0
Super! Danke, das sollte meine Probleme beheben.
Translated with http://www.DeepL.com/Translator
Download of PureBasic - Modules
Download of PureBasic - Programs
[Windows 11 x64] [PB V5.7x]
Download of PureBasic - Modules
Download of PureBasic - Programs
[Windows 11 x64] [PB V5.7x]
-
- Addict
- Posts: 1482
- Joined: Tue Feb 22, 2011 1:16 pm
Re: PurePDF Version 2.0
I downloaded this version, but the Help file for it says it's V2.08 still.ABBKlaus wrote:small update, PurePDF V2.20
Also, got a question: I used this code to add a very tall image (5000 pixels high) to a new PDF file, but the image only went on the first page, and not continued over any next pages. How could I do that?
Code: Select all
pdf_Create()
pdf_AddPage()
pdf_Image("1280x5000.png",0,0,200)
pdf_Save("test.pdf")
Microsoft Visual Basic only lasted 7 short years: 1991 to 1998.
PureBasic: Born in 1998 and still going strong to this very day!
PureBasic: Born in 1998 and still going strong to this very day!
-
- Addict
- Posts: 1482
- Joined: Tue Feb 22, 2011 1:16 pm
Re: PurePDF Version 2.0
Is it possible to open a PDF with this lib and save the doc as plain text back to disk?
Microsoft Visual Basic only lasted 7 short years: 1991 to 1998.
PureBasic: Born in 1998 and still going strong to this very day!
PureBasic: Born in 1998 and still going strong to this very day!
Re: PurePDF Version 2.0
Hi, I just tested this lib and I find it very useful, but I am unable to create a PDF with an RTF file and its formatting. Is this possible? and if yes, how to do that? Thanks.
PureBasicien tu es, PureBasicien tu resteras.
-
- Enthusiast
- Posts: 772
- Joined: Tue May 20, 2008 2:12 am
- Location: Cologne, Germany
- Contact:
Re: PurePDF Version 2.0
Hi ABBKlaus,
any change to have this Lib for Mac OS X also???
Edit: Please
any change to have this Lib for Mac OS X also???
Edit: Please
Regards,
JamiroKwai
JamiroKwai
- DoubleDutch
- Addict
- Posts: 3219
- Joined: Thu Aug 07, 2003 7:01 pm
- Location: United Kingdom
- Contact:
Re: PurePDF Version 2.0
I've tried outputing unicode text using PurePDF and although it writes the ascii characters correctly, the unicode characters out of the normal ascii range are not displayed.
Is this a bug or a known restriction?
Is this a bug or a known restriction?
https://deluxepixel.com <- My Business website
https://reportcomplete.com <- School end of term reports system
https://reportcomplete.com <- School end of term reports system