Package com.pd4ml.pdf.cos.writer
Class HelveticaMetrics
- java.lang.Object
-
- com.pd4ml.pdf.cos.writer.HelveticaMetrics
-
public final class HelveticaMetrics extends java.lang.ObjectCharacter advance widths (per 1000 text-space units, i.e. AFM/PDF glyph metric convention) for the standard 14 font Helvetica, covering ASCII 0x20-0x7E. These are the standard, freely-republished Adobe Core 14 AFM numbers (the same table every PDF library, including PDFBox, ships) -- metric data, not copyrightable expression. Useful whenever code building a COS content stream (an annotation appearance, a signature's visible appearance, ...) needs to word-wrap text without embedding a font program; characters outside this range fall back to the (also standard) 556 average width.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static intcharWidth(char c)Width of one character, in 1000ths of the font size (multiply by fontSize/1000 to get points).static floatstringWidth(java.lang.String text, float fontSize)Width oftextatfontSizepoints, in points.
-