XTextStyle Size Property. The current text size. ABCpdf .NET PDF Library.

ABCpdf .net

 
   

 

Type Default Read Only Description
[C#] double

[Visual Basic]
Double
10.0 No The current text size.

 

   

Notes
 

This property determines the size of text that is added to the document using methods like AddText.

The Size property is equivalent to the the Doc.FontSize property but unlike the FontSize property it allows fractional point sizes to be specified.

The font size is measured in units.

 

   

Example
 

The following example adds two blocks of styled text to a document. The first block is in 96.5 point type and the second is in 192.5 point type.

[C#]
Doc theDoc = new Doc();
theDoc.TextStyle.Size = 96.5;
theDoc.AddText("Small ");
theDoc.TextStyle.Size = 192.5;
theDoc.AddText("Big");
theDoc.Save(Server.MapPath("stylesize.pdf"));
theDoc.Clear();

[Visual Basic]
Dim theDoc As Doc = New Doc()
theDoc.TextStyle.Size = 96.5
theDoc.AddText("Small ")
theDoc.TextStyle.Size = 192.5
theDoc.AddText("Big")
theDoc.Save(Server.MapPath("stylesize.pdf"))
theDoc.Clear()


stylesize.pdf