pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Maruan Sahyoun <sahy...@fileaffairs.de>
Subject Re: Font Size in 2.0?
Date Tue, 28 Apr 2015 18:07:49 GMT
Hi,

> Am 28.04.2015 um 16:48 schrieb Richard Johnson <richard@ytivarg.com>:
> 
> Oops, more specifically ...
> 
> I need to change font sizes for the text I'm auto-entering into fields in 
> forms.  (Just in case it matters.)
> 
> 

Yes, it does matter. To change the size of the font for a field you need to set the fields
default appearance setDefaultAppeance(String devalue). The default appearance string will
look similar to 

"/Helv 12.0 Tf … " 

where the name entry before the Tf operator points to the font resource and the number is
the font size.

Make sure that you do set the value prior to setting the field value as the visual appearance
of the field will be calculated from that setting.

BR
Maruan


> 
> On Tuesday, April 28, 2015 07:47:02 AM Richard Johnson wrote:
>> Hi all,
>> 
>> Would someone please point me to a quick example of altering font size in 
> 2.0?
>> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: users-help@pdfbox.apache.org


Mime
View raw message