Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Textfield Spacing with "Stretch on Overflow" buggy?

I am currently designing a report using iReport 4.7.0. At the moment I am trying to figure out how to dynamically adjust the height of a textField, if its contents is too big for the initial height. It seems, that the option Stretch on overflow achieves this. But I am having problems with that.

If a textField is not stretched, the spacing before and after the text is good, because its achieved by setting the textField height higher than the font size. But if the textField gets dynamically bigger because the containing text is to long to display with the initial height, the lines seem awfully packed, there is no spacing whatsoever.

I tried so resolve this by setting Spacing before and Spacing after for the specific textField but this seems to end in JasperReports thinking, that the textField doesn't need to re-size at all, even if the text is not fitting.

Is it possible, that the size created by the Spacing before and Spacing after option is taken into account on calculating, if a textField needs to be resized on overflow? Or am I doing something wrong here?

like image 853
padde Avatar asked Sep 24 '12 09:09

padde


1 Answers

Use padding:

  1. Right-click an element
  2. Select Padding and Borders

-or-

  1. Right-click an element
  2. Select Show Properties
  3. Click the Borders tab
  4. Set padding values as required

Example Padding

This should provide a constant spacing even if box resizes. For complex layouts, experiment with float position of elements, as described here.

like image 62
T.Z. Avatar answered Sep 25 '22 13:09

T.Z.