sysalto / ReactiveReports

Reactive Reports - a framework developed in Scala, designed for generating reports from code.
Other
16 stars 4 forks source link

can I print text to the PDF report in original format/layout? #4

Closed happyworkoncode closed 6 years ago

happyworkoncode commented 6 years ago

I'm wondering if I can read text from a file and print out on the report. I would like to keep the text in original format including spaces between text. For example, I want to print the following text with leading spaces and spaces between words on the report:

{some spaces} Today is {some spaces} a good {some spaces} day.

my code is something like this:

ReportCell cell= new ReportCell(new ReportTxt(my text)) report.print(cell);

but it looks like the leading spaces and the spaces in the middle are all get stripped out. Do you have any idea why all the spaces get stripped out? Thanks.