This is an example of printing text using the jFX8 Print library with TextFlow and Text class objects.
By parsing the text and measuring and creating text classes per line as required by wrapping it creates multiple pages and prints them to one print job.
There are also options to break on word, highlight alternate rows with color, underline rows solid or dashed, remove double empty lines and add audit columns to enable simple auditing tasks.
Provided that the textflow is the top most view in the printed node, the text is selectable in a PDF viewer.
This example was printed to PDF and the annotations added with Foxit pdf reader. I am all in favour of saving paper.
A straight forward print of text from a String variable. It will also print from a file.
Dependencies:
jFX8Print Library - B4xlib
TextFlow Library - B4xlib
jReflection
I haven't created a gui for it I may do it later but if anyone fancies it, feel free.
Let me know how you get on with it.
By parsing the text and measuring and creating text classes per line as required by wrapping it creates multiple pages and prints them to one print job.
There are also options to break on word, highlight alternate rows with color, underline rows solid or dashed, remove double empty lines and add audit columns to enable simple auditing tasks.
Provided that the textflow is the top most view in the printed node, the text is selectable in a PDF viewer.
This example was printed to PDF and the annotations added with Foxit pdf reader. I am all in favour of saving paper.
A straight forward print of text from a String variable. It will also print from a file.
Dependencies:
jFX8Print Library - B4xlib
TextFlow Library - B4xlib
jReflection
I haven't created a gui for it I may do it later but if anyone fancies it, feel free.
Let me know how you get on with it.
Attachments
Last edited: