Package org.gvsig.labeling.symbol
Class SymbolUtils
java.lang.Object
org.gvsig.labeling.symbol.SymbolUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic doublegetCartographicLength(org.gvsig.fmap.mapcontext.rendering.symbols.CartographicSupport cartographicElement, double length, org.gvsig.fmap.mapcontext.ViewPort viewPort, double dpi) Calculates the distance in pixels corresponding to the provided length, according to the current rendering context (output dpi, map scale, map units) and the symbol cartographic settings (unit, size, and unit reference system).
-
Constructor Details
-
SymbolUtils
public SymbolUtils()
-
-
Method Details
-
getCartographicLength
public static double getCartographicLength(org.gvsig.fmap.mapcontext.rendering.symbols.CartographicSupport cartographicElement, double length, org.gvsig.fmap.mapcontext.ViewPort viewPort, double dpi) Calculates the distance in pixels corresponding to the provided length, according to the current rendering context (output dpi, map scale, map units) and the symbol cartographic settings (unit, size, and unit reference system).- Parameters:
cartographicElement- CartographicSupport object which contains the reference system and the measuring units for the provided lengthlength- The length to be computed in pixels. The length is supposed to be provided in the units defined in the cartographicElementviewPort- The viewport, which defines the relationship between pixels and maps unitsdpi- The resolution (dots per inch) of the target display device (printer, screen, etc)- Returns:
- The distance in pixels corresponding to the provided length
-