Closed tan-wei closed 4 years ago
Quite easy to get the result with the code:
require 'thinreports'
report = Thinreports::Report.new layout: 'align_test.tlf'
report.start_new_page do |page|
page.item(:text_block).set("Text Box")
end
report.generate filename: 'align_test.pdf'
And the TLF file: align_test.zip
Sorry for late reply.
You will be able to solve you issue in the following ways:
Multiple Line
property of text_block
Vertical Align
property of text_block
to Align Middle
The PDF output with a template with the above settings is as follows:
Thanks very much!
I find it hard to align a text block to a text. For example, a layout is created as following:
We can see in the editor, the top location of "Text Block" is equal to the top location of "Text". However, the output PDF is:
Is there an easy way to align them? I can't find an easy way in examples.
estimate-ja
provides a pretty result, but how?Thanks very much!