Package org.apache.hop.core.gui
Class SvgGc
- java.lang.Object
-
- org.apache.hop.core.gui.SvgGc
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.hop.core.gui.IGc
IGc.EColor, IGc.EFont, IGc.EImage, IGc.ELineStyle
-
-
Field Summary
Fields Modifier and Type Field Description protected Colorbackgroundprotected Colorblackprotected Colorblueprotected Colorcrystalprotected ColordarkGrayprotected Colordeprecatedprotected Colorgrayprotected Colorgreenprotected ColorhopDefaultprotected ColorhopFalseprotected ColorhopTrueprotected Colorindigoprotected ColorlightBlueprotected ColorlightGrayprotected Colormagentaprotected Colorpurpuleprotected Colorredprotected Coloryellow
-
Constructor Summary
Constructors Constructor Description SvgGc(HopSvgGraphics2D gc, Point area, int iconSize, int xOffset, int yOffset)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddispose()voiddrawActionIcon(int x, int y, ActionMeta actionMeta, float magnification)voiddrawImage(IGc.EImage image, int x, int y, float magnification)voiddrawImage(IGc.EImage image, int x, int y, float magnification, double angle)voiddrawImage(SvgFile svgFile, int x, int y, int desiredWidth, int desiredHeight, float magnification, double angle)voiddrawLine(int x, int y, int x2, int y2)voiddrawPoint(int x, int y)voiddrawPolygon(int[] polygon)voiddrawPolyline(int[] polyline)voiddrawRectangle(int x, int y, int width, int height)voiddrawRoundRectangle(int x, int y, int width, int height, int circleWidth, int circleHeight)voiddrawText(String text, int x, int y)voiddrawText(String text, int x, int y, boolean transparent)voiddrawTransformIcon(int x, int y, TransformMeta transformMeta, float magnification)voidfillGradientRectangle(int x, int y, int width, int height, boolean vertical)voidfillPolygon(int[] polygon)voidfillRectangle(int x, int y, int width, int height)voidfillRoundRectangle(int x, int y, int width, int height, int circleWidth, int circleHeight)intgetAlpha()PointgetArea()PointgetDeviceBounds()ObjectgetImage()floatgetMagnification()static SvgFilegetNativeImage(IGc.EImage image)AffineTransformgetTransform()voidsetAlpha(int alpha)voidsetAntialias(boolean antiAlias)voidsetBackground(int r, int g, int b)voidsetBackground(IGc.EColor color)voidsetFont(String fontName, int fontSize, boolean fontBold, boolean fontItalic)voidsetFont(IGc.EFont font)voidsetForeground(int r, int g, int b)voidsetForeground(IGc.EColor color)voidsetLineStyle(IGc.ELineStyle lineStyle)voidsetLineWidth(int width)voidsetTransform(float translationX, float translationY, float magnification)voidswitchForegroundBackgroundColors()PointtextExtent(String text)
-
-
-
Field Detail
-
background
protected Color background
-
black
protected Color black
-
red
protected Color red
-
yellow
protected Color yellow
-
green
protected Color green
-
blue
protected Color blue
-
magenta
protected Color magenta
-
purpule
protected Color purpule
-
indigo
protected Color indigo
-
gray
protected Color gray
-
lightGray
protected Color lightGray
-
darkGray
protected Color darkGray
-
lightBlue
protected Color lightBlue
-
crystal
protected Color crystal
-
hopDefault
protected Color hopDefault
-
hopTrue
protected Color hopTrue
-
hopFalse
protected Color hopFalse
-
deprecated
protected Color deprecated
-
-
Constructor Detail
-
SvgGc
public SvgGc(HopSvgGraphics2D gc, Point area, int iconSize, int xOffset, int yOffset) throws HopException
- Throws:
HopException
-
-
Method Detail
-
drawLine
public void drawLine(int x, int y, int x2, int y2)
-
drawPolygon
public void drawPolygon(int[] polygon)
- Specified by:
drawPolygonin interfaceIGc
-
drawPolyline
public void drawPolyline(int[] polyline)
- Specified by:
drawPolylinein interfaceIGc
-
drawRectangle
public void drawRectangle(int x, int y, int width, int height)- Specified by:
drawRectanglein interfaceIGc
-
drawRoundRectangle
public void drawRoundRectangle(int x, int y, int width, int height, int circleWidth, int circleHeight)- Specified by:
drawRoundRectanglein interfaceIGc
-
drawText
public void drawText(String text, int x, int y, boolean transparent)
-
fillPolygon
public void fillPolygon(int[] polygon)
- Specified by:
fillPolygonin interfaceIGc
-
fillRectangle
public void fillRectangle(int x, int y, int width, int height)- Specified by:
fillRectanglein interfaceIGc
-
fillGradientRectangle
public void fillGradientRectangle(int x, int y, int width, int height, boolean vertical)- Specified by:
fillGradientRectanglein interfaceIGc
-
fillRoundRectangle
public void fillRoundRectangle(int x, int y, int width, int height, int circleWidth, int circleHeight)- Specified by:
fillRoundRectanglein interfaceIGc
-
getDeviceBounds
public Point getDeviceBounds()
- Specified by:
getDeviceBoundsin interfaceIGc
-
setBackground
public void setBackground(IGc.EColor color)
- Specified by:
setBackgroundin interfaceIGc
-
setForeground
public void setForeground(IGc.EColor color)
- Specified by:
setForegroundin interfaceIGc
-
setLineStyle
public void setLineStyle(IGc.ELineStyle lineStyle)
- Specified by:
setLineStylein interfaceIGc
-
setLineWidth
public void setLineWidth(int width)
- Specified by:
setLineWidthin interfaceIGc
-
setTransform
public void setTransform(float translationX, float translationY, float magnification)- Specified by:
setTransformin interfaceIGc
-
getMagnification
public float getMagnification()
- Specified by:
getMagnificationin interfaceIGc
-
getTransform
public AffineTransform getTransform()
-
textExtent
public Point textExtent(String text)
- Specified by:
textExtentin interfaceIGc
-
setAntialias
public void setAntialias(boolean antiAlias)
- Specified by:
setAntialiasin interfaceIGc
-
setBackground
public void setBackground(int r, int g, int b)- Specified by:
setBackgroundin interfaceIGc
-
setForeground
public void setForeground(int r, int g, int b)- Specified by:
setForegroundin interfaceIGc
-
setFont
public void setFont(String fontName, int fontSize, boolean fontBold, boolean fontItalic)
-
getImage
public Object getImage()
-
switchForegroundBackgroundColors
public void switchForegroundBackgroundColors()
- Specified by:
switchForegroundBackgroundColorsin interfaceIGc
-
getNativeImage
public static final SvgFile getNativeImage(IGc.EImage image)
-
drawImage
public void drawImage(IGc.EImage image, int x, int y, float magnification) throws HopException
- Specified by:
drawImagein interfaceIGc- Throws:
HopException
-
drawImage
public void drawImage(IGc.EImage image, int x, int y, float magnification, double angle) throws HopException
- Specified by:
drawImagein interfaceIGc- Throws:
HopException
-
drawTransformIcon
public void drawTransformIcon(int x, int y, TransformMeta transformMeta, float magnification) throws HopException- Specified by:
drawTransformIconin interfaceIGc- Throws:
HopException
-
drawActionIcon
public void drawActionIcon(int x, int y, ActionMeta actionMeta, float magnification) throws HopException- Specified by:
drawActionIconin interfaceIGc- Throws:
HopException
-
drawImage
public void drawImage(SvgFile svgFile, int x, int y, int desiredWidth, int desiredHeight, float magnification, double angle) throws HopException
- Specified by:
drawImagein interfaceIGc- Throws:
HopException
-
-