Class ImageRenderingContext
- java.lang.Object
-
- ro.sync.exml.workspace.api.images.handlers.ImageRenderingContext
-
@API(type=NOT_EXTENDABLE, src=PUBLIC) public class ImageRenderingContext extends java.lang.Object
Contains information about the context in which the image will be rendered..- Since:
- 18
-
-
Constructor Summary
Constructors Constructor Description ImageRenderingContext(Font font)
Constructor.ImageRenderingContext(Font font, int dotsPerInch)
Constructor.ImageRenderingContext(Font font, int dotsPerInch, Rectangle imageInfo)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getDotsPerInch()
Get the current monitor DPI settings.Font
getFont()
Get the font used in the place where the image will be displayed.Dimension
getImageDimensions()
Gets the final dimension of the image that will be painted.
-
-
-
Method Detail
-
getFont
public Font getFont()
Get the font used in the place where the image will be displayed. Some image handlers (for example an SVG or a MathML image handler) might use this information to render and compute the image sizes...- Returns:
- Returns the font used in the place where the image will be displayed.
-
getDotsPerInch
public int getDotsPerInch()
Get the current monitor DPI settings. The default is 96.- Returns:
- Returns the current monitor.
-
getImageDimensions
public Dimension getImageDimensions()
Gets the final dimension of the image that will be painted. Some image handlers (for example an SVG or a MathML image handler) might use this information to scale images without losing accuracy. If the handler does not use this information, the image is automatically scaled by the application to the display dimensions.- Returns:
- Returns The final dimensions of the image, or
null
. - Since:
- 24.0
-
-