Subscribe for automatic updates: RSS icon RSS

Login icon Sign in for full access | Help icon Help
Advanced search

Pages: [1]
  Reply  |  Print  
Author Topic: text allignment  (Read 13238 times)
Joseph M.
Posts: 18


« on: July 08, 2009, 05:07:12 pm »

Hello,

I am having problems with text allignment. I the report designer my test looks perfictly aligned. When I run the report I get the following warning messages from the runtime system and my text is misaligned.

The bottom line in the report has the problem.

Please see attachments. report design document mg1_new.4rp and report output mg1_new.pdf

* mg1_new.4rp (14.63 KB - downloaded 1051 times.)
* mg1_new.pdf (27.4 KB - downloaded 1124 times.)
Romain W.
Four Js
Posts: 48


« Reply #1 on: July 09, 2009, 02:47:08 pm »

Hi,

You said the problem appears in the last line, so I guess you are telling about the horizontal alignment of the elements in Mini Page 'pps_50', right? This problem is due to property 'Y-size' set on both WordWrap boxes 'WordWrapBox40' and 'WordWrapBox42'. The other WordWrap boxes of this container don't have 'Y-size' set. If you unset 'Y-size' on both elements above (clicking on the 'reset' button), the problem should disappear.

Actually, you should't set a 'Y-size' (height) on a WordWarp box, because the element should typically grow according to its content. If you set a fixed 'Y-size', you'll forbid that automatic enlargement. In your case, you combine WordWrap boxes having 'Y-size' set and WordWrap boxes having "dynamic" 'Y-size'. The baseline alignment will be badly interpreted in this case and will drive to bad horizontal text alignment.

Now the behaviour might be a bit unexpected. We'll have a deeper look on this...
Thanks.

Best regards,
Romain W.
Joseph M.
Posts: 18


« Reply #2 on: July 09, 2009, 03:41:19 pm »

Thanks for the reply Romain,

Changing the Y-size corrected the alignment.

I have a follow-up question about wrodwrap boxes. Wordwrap boxes expand to accommodate the text passed. How do you expand the parent container to accommodate the expanded wordwrap box when you don't know how large the word wrap box will become?

Thank You

Joe
Romain W.
Four Js
Posts: 48


« Reply #3 on: July 09, 2009, 05:21:45 pm »

Hi,

To make the parent size grow automatically, just set the 'X-size' property of the parent container in a dynamic way, to 'min'. Then it will grow according to the content of the WordWrap box.

Regards,
Romain
Joseph M.
Posts: 18


« Reply #4 on: July 09, 2009, 05:35:00 pm »

I don't understand your reply. Can you please provide an example.

Thank you

Joe Miller
Romain W.
Four Js
Posts: 48


« Reply #5 on: July 09, 2009, 05:46:04 pm »

Ok, I mean in the report file you sent ('mg1_new.4rp'), the WordWrap boxes involved in the bad alignment problem are located in a parent container which is a 'Mini Page' called 'pps_50'. On this 'Mini Page', you have set property 'X-size' (height) to a fixed value (52.7739). All you have to do is to set it to 'min'.
I made the modification in the file attached (and also the ones about the alignment issue).

Best regards,
Romain

* mg1_new_modified.4rp (13.94 KB - downloaded 1031 times.)
Pages: [1]
  Reply  |  Print  
 
Jump to:  

Powered by SMF 1.1.21 | SMF © 2015, Simple Machines