public class SVGImageWorker extends ImageWorker
ImageWorker handles inline style
reduction; SVG element grouping is handled by postProcessSvg consolidation in SVGGraphics2D.| Constructor and Description |
|---|
SVGImageWorker(int width,
int height)Image width in pixels. |
SVGImageWorker(int width,
int height,
boolean glow)Image width in pixels. |
| Modifier and Type | Method and Description |
|---|---|
(package private) void | drawString(String text,
int x,
int y,
Font font,
Paint paint)Draw string |
(package private) double | getStringWidth(String text,
Font font)Get the width of the given text in the specified font. |
(package private) void | makeImage(OutputStream os)Make image |
protected void | reset(Graphics2D g2d)Reset the allocator state |
(package private) void | resize(int width,
int height)Resize |
clip, dispose, drawLine, drawPolyline, fillPolygon, fillPolygon, fillRect, getFontAscent, getFontHeight, getImageBytes, loadImage, makeImage, reset, resetState, saveImage, setAntiAliasing, setG2d, setTextAntiAliasing, transformpublic SVGImageWorker(int width,
int height)width - image width in pixelsheight - image height in pixelspublic SVGImageWorker(int width,
int height,
boolean glow)width - image width in pixelsheight - image height in pixelsglow - whether to enable glow effectvoid drawString(String text, int x, int y, Font font, Paint paint)
drawString in class ImageWorkertext - the text to drawx - the x coordinatey - the y coordinatefont - the fontpaint - the paintdouble getStringWidth(String text, Font font)
ImageWorkergetStringWidth in class ImageWorkertext - the textfont - the fontvoid makeImage(OutputStream os) throws IOException
makeImage in class ImageWorkeros - the output streamIOException - if an I/O error occursprotected void reset(Graphics2D g2d)
reset in class ImageWorkerg2d - the graphics contextvoid resize(int width,
int height)resize in class ImageWorkerwidth - the new widthheight - the new height