new FontUnit()

Example

This sample shows how to create and save a BarCode image.

  let generator = new BarcodeGenerator(EncodeTypes.CODE_128);
  generator.getParameters().getCaptionAbove().setText("CAPTION ABOOVE");
  generator.getParameters().getCaptionAbove().setVisible(true);
  generator.getParameters().getCaptionAbove().getFont().setStyle(FontStyle.ITALIC);
  generator.getParameters().getCaptionAbove().getFont().getSize().setPoint(25);

Methods

getFamilyName()

Gets the face name of this Font.

getSize()

Gets size of this FontUnit in Unit value.

Throws

IllegalArgumentException
The Size parameter value is less than or equal to 0.

getStyle()

Gets style information for this FontUnit.

setFamilyName()

Sets the face name of this Font.

setStyle()

Sets style information for this FontUnit.