Vertically top align text

Knowledge exchange related to the VPE Report Engine and PDF Library

Moderator: IDEAL Software Support

Vertically top align text

Postby AndersOhrt » Mon Feb 02, 2009 3:46 pm

I'm porting some of our reports to VPE and found one problem. We often write a label in a smaller font size and then the value in a larger size. For example, first we write "Name:" in font size 8 and then "Anders" in font size 12.

In our old printing tool, these where then vertically bottom aligned, so they look like they "stand" on the same line. In VPE they are vertically top aligned, so they instead look like they are "hanging" from the same line (compare a HTML table with valign bottom vs. top).

If this something I can easily fix in VPE?
AndersOhrt
 
Posts: 5
Joined: Mon Feb 02, 2009 3:35 pm

Postby IDEAL Software Support » Tue Feb 03, 2009 12:14 pm

Use RTF (Richt Text) to bottom align text of different font sizes (or font types). The RTF Object is provided by VPE Professional Edition and higher.
IDEAL Software Support
 
Posts: 1633
Joined: Thu Nov 18, 2004 4:03 pm

Postby AndersOhrt » Tue Feb 03, 2009 1:11 pm

Thank you for the tip. I'll see if this is a possible solution for us.
AndersOhrt
 
Posts: 5
Joined: Mon Feb 02, 2009 3:35 pm

Postby AndersOhrt » Fri Feb 13, 2009 8:50 am

Unfortunatly RTF was not an option, so I buffer all text that is written and when a line feed is written I calculate the line heights and base line. It's pretty messy but it's the only way I can see.
AndersOhrt
 
Posts: 5
Joined: Mon Feb 02, 2009 3:35 pm

Postby IDEAL Software Support » Fri Feb 13, 2009 10:17 am

RTF is a solution. I do not see any reason why it should not work. RTF does automatically the basline-alignment.
IDEAL Software Support
 
Posts: 1633
Joined: Thu Nov 18, 2004 4:03 pm

Postby AndersOhrt » Fri Feb 13, 2009 1:04 pm

Yes, RTF is _a_ solution, but it did not solve our problem unfortunately. I don't remember the exact reason why it did not fit our need, I think the problems was that we mix multiline and single line text.
AndersOhrt
 
Posts: 5
Joined: Mon Feb 02, 2009 3:35 pm


Return to VPE Open Forum

Who is online

Users browsing this forum: No registered users and 14 guests

cron