Package org.pentaho.di.core
Class SwingUniversalImage
java.lang.Object
org.pentaho.di.core.SwingUniversalImage
- Direct Known Subclasses:
SwingUniversalImageBitmap
,SwingUniversalImageSvg
Universal image storage for Swing processing. It contains SVG or bitmap image depends on file and settings.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic BufferedImage
createBitmap
(int width, int height) Create bitmap with specified size and full colorspace.static BufferedImage
createDoubleBitmap
(int width, int height) Create bitmap with double of specified size and full colorspace.static Graphics2D
createGraphics
(BufferedImage area) Create Graphics2D for specified bitmap with rendering hints.void
drawToGraphics
(Graphics2D gc, int locationX, int locationY, int width, int height) void
drawToGraphics
(Graphics2D gc, int centerX, int centerY, int width, int height, double angleRadians) getAsBitmapForSize
(int width, int height) Get scaled image.getAsBitmapForSize
(int width, int height, double angleRadians) Draw rotated image on double canvas size.abstract boolean
isBitmap()
protected abstract void
render
(Graphics2D gc, int centerX, int centerY, int width, int height, double angleRadians) Render with scale, at specified position, with possible rotation.protected abstract void
renderSimple
(BufferedImage area) Just scale for area's size.
-
Constructor Details
-
SwingUniversalImage
public SwingUniversalImage()
-
-
Method Details
-
isBitmap
public abstract boolean isBitmap() -
renderSimple
Just scale for area's size. -
render
protected abstract void render(Graphics2D gc, int centerX, int centerY, int width, int height, double angleRadians) Render with scale, at specified position, with possible rotation. -
getAsBitmapForSize
Get scaled image. -
getAsBitmapForSize
Draw rotated image on double canvas size. It required against lost corners on rotate. -
drawToGraphics
-
drawToGraphics
public void drawToGraphics(Graphics2D gc, int centerX, int centerY, int width, int height, double angleRadians) -
createBitmap
Create bitmap with specified size and full colorspace. -
createDoubleBitmap
Create bitmap with double of specified size and full colorspace. Used for rotated images. -
createGraphics
Create Graphics2D for specified bitmap with rendering hints.
-