Class EmptyFontMetrics
java.lang.Object
org.pentaho.reporting.libraries.fonts.registry.EmptyFontMetrics
- All Implemented Interfaces:
 FontMetrics
An placeholder metrics for buggy fonts.
- Author:
 - Thomas Morgner
 
- 
Constructor Summary
ConstructorsConstructorDescriptionEmptyFontMetrics(FontNativeContext record, double baseWidth, double baseHeight) EmptyFontMetrics(FontNativeContext record, long baseWidth, long baseHeight)  - 
Method Summary
Modifier and TypeMethodDescriptionlongFrom the baseline to thegetBaselines(int c, BaselineInfo info) Baselines are defined for scripts, not glyphs.longgetCharWidth(int codePoint) longThe font descent is the distance from the font's baseline to the bottom of most alphanumeric characters.longlonggetKerning(int previous, int codePoint) longThe standard leading, or interline spacing, is the logical amount of space to be reserved between the descent of one line of text and the ascent of the next line.longlonglonglonglonglonglonglongThe height of the lowercase 'x'.booleanIs it guaranteed that the font always returns the same baseline info objct? 
- 
Constructor Details
- 
EmptyFontMetrics
 - 
EmptyFontMetrics
 
 - 
 - 
Method Details
- 
isUniformFontMetrics
public boolean isUniformFontMetrics()Is it guaranteed that the font always returns the same baseline info objct?- Specified by:
 isUniformFontMetricsin interfaceFontMetrics- Returns:
 - true, if the baseline info in question is always the same, false otherwise.
 
 - 
getAscent
public long getAscent()From the baseline to the- Specified by:
 getAscentin interfaceFontMetrics- Returns:
 
 - 
getDescent
public long getDescent()Description copied from interface:FontMetricsThe font descent is the distance from the font's baseline to the bottom of most alphanumeric characters. The descent is always a positive number.- Specified by:
 getDescentin interfaceFontMetrics- Returns:
 - the descent.
 
 - 
getLeading
public long getLeading()Description copied from interface:FontMetricsThe standard leading, or interline spacing, is the logical amount of space to be reserved between the descent of one line of text and the ascent of the next line. The height metric is calculated to include this extra space. The leading is always a positive number.- Specified by:
 getLeadingin interfaceFontMetrics- Returns:
 - the leading.
 
 - 
getXHeight
public long getXHeight()The height of the lowercase 'x'. This is used as hint, which size the lowercase characters will have.- Specified by:
 getXHeightin interfaceFontMetrics- Returns:
 
 - 
getOverlinePosition
public long getOverlinePosition()- Specified by:
 getOverlinePositionin interfaceFontMetrics
 - 
getUnderlinePosition
public long getUnderlinePosition()- Specified by:
 getUnderlinePositionin interfaceFontMetrics
 - 
getStrikeThroughPosition
public long getStrikeThroughPosition()- Specified by:
 getStrikeThroughPositionin interfaceFontMetrics
 - 
getMaxAscent
public long getMaxAscent()- Specified by:
 getMaxAscentin interfaceFontMetrics
 - 
getMaxDescent
public long getMaxDescent()- Specified by:
 getMaxDescentin interfaceFontMetrics
 - 
getMaxHeight
public long getMaxHeight()- Specified by:
 getMaxHeightin interfaceFontMetrics
 - 
getMaxCharAdvance
public long getMaxCharAdvance()- Specified by:
 getMaxCharAdvancein interfaceFontMetrics
 - 
getCharWidth
public long getCharWidth(int codePoint) - Specified by:
 getCharWidthin interfaceFontMetrics
 - 
getKerning
public long getKerning(int previous, int codePoint) - Specified by:
 getKerningin interfaceFontMetrics
 - 
getBaselines
Baselines are defined for scripts, not glyphs. A glyph carries script information most of the time (unless it is a neutral characters or just weird).- Specified by:
 getBaselinesin interfaceFontMetrics- Parameters:
 c-- Returns:
 
 - 
getItalicAngle
public long getItalicAngle()- Specified by:
 getItalicAnglein interfaceFontMetrics
 - 
getNativeContext
- Specified by:
 getNativeContextin interfaceFontMetrics
 
 -