|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.jgoodies.forms.util.AbstractUnitConverter
public abstract class AbstractUnitConverter
An abstract implementation of the UnitConverter that minimizes
the effort required to convert font-dependent sizes to pixels.
DefaultUnitConverter,
Size,
Sizes| Constructor Summary | |
|---|---|
AbstractUnitConverter()
|
|
| Method Summary | |
|---|---|
int |
centimeterAsPixel(double cm,
java.awt.Component component)
Converts Centimeters and answers pixels using the resolution of the given component's graphics object. |
int |
dialogUnitXAsPixel(int dluX,
java.awt.Component c)
Converts horizontal dialog units and answers pixels. |
int |
dialogUnitYAsPixel(int dluY,
java.awt.Component c)
Converts vertical dialog units and answers pixels. |
int |
inchAsPixel(double in,
java.awt.Component component)
Converts Inches and answers pixels using the specified resolution. |
int |
millimeterAsPixel(double mm,
java.awt.Component component)
Converts Millimeters and answers pixels using the resolution of the given component's graphics object. |
int |
pointAsPixel(int pt,
java.awt.Component component)
Converts DTP Points and answers pixels using the resolution of the given component's graphics object. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AbstractUnitConverter()
| Method Detail |
|---|
public int inchAsPixel(double in,
java.awt.Component component)
inchAsPixel in interface UnitConverterin - the Inchescomponent - the component that provides the graphics object
public int millimeterAsPixel(double mm,
java.awt.Component component)
millimeterAsPixel in interface UnitConvertermm - Millimeterscomponent - the component that provides the graphics object
public int centimeterAsPixel(double cm,
java.awt.Component component)
centimeterAsPixel in interface UnitConvertercm - Centimeterscomponent - the component that provides the graphics object
public int pointAsPixel(int pt,
java.awt.Component component)
pointAsPixel in interface UnitConverterpt - DTP Pointscomponent - the component that provides the graphics object
public int dialogUnitXAsPixel(int dluX,
java.awt.Component c)
dialogUnitXAsPixel in interface UnitConverterdluX - the horizontal dialog unitsc - a Component that provides the font and graphics
public int dialogUnitYAsPixel(int dluY,
java.awt.Component c)
dialogUnitYAsPixel in interface UnitConverterdluY - the vertical dialog unitsc - a Component that provides the font and graphics
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||