Package org.apache.hop.ui.hopgui.shared
Class SwtGc
- java.lang.Object
-
- org.apache.hop.ui.hopgui.shared.SwtGc
-
-
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 org.eclipse.swt.graphics.Colorbackgroundprotected org.eclipse.swt.graphics.Colorblackprotected org.eclipse.swt.graphics.Colorblueprotected org.eclipse.swt.graphics.Colorcrystalprotected org.eclipse.swt.graphics.ColordarkGrayprotected org.eclipse.swt.graphics.Colordeprecatedprotected org.eclipse.swt.graphics.Colorgrayprotected org.eclipse.swt.graphics.Colorgreenprotected org.eclipse.swt.graphics.ColorhopDefaultprotected org.eclipse.swt.graphics.ColorhopFalseprotected org.eclipse.swt.graphics.ColorhopTrueprotected org.eclipse.swt.graphics.Colorindigoprotected org.eclipse.swt.graphics.ColorlightBlueprotected org.eclipse.swt.graphics.ColorlightGrayprotected org.eclipse.swt.graphics.Colormagentaprotected org.eclipse.swt.graphics.Colorpurpuleprotected org.eclipse.swt.graphics.Colorredprotected org.eclipse.swt.graphics.Colorwhiteprotected org.eclipse.swt.graphics.Coloryellow
-
Constructor Summary
Constructors Constructor Description SwtGc(org.eclipse.swt.graphics.GC gc, int width, int height, int iconSize)
-
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(IGc.EImage image, int x, int y, int width, int height, float magnification)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()floatgetMagnification()static SwtUniversalImagegetNativeImage(IGc.EImage image)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 org.eclipse.swt.graphics.Color background
-
black
protected org.eclipse.swt.graphics.Color black
-
white
protected org.eclipse.swt.graphics.Color white
-
red
protected org.eclipse.swt.graphics.Color red
-
yellow
protected org.eclipse.swt.graphics.Color yellow
-
hopFalse
protected org.eclipse.swt.graphics.Color hopFalse
-
green
protected org.eclipse.swt.graphics.Color green
-
blue
protected org.eclipse.swt.graphics.Color blue
-
magenta
protected org.eclipse.swt.graphics.Color magenta
-
purpule
protected org.eclipse.swt.graphics.Color purpule
-
indigo
protected org.eclipse.swt.graphics.Color indigo
-
gray
protected org.eclipse.swt.graphics.Color gray
-
lightGray
protected org.eclipse.swt.graphics.Color lightGray
-
darkGray
protected org.eclipse.swt.graphics.Color darkGray
-
lightBlue
protected org.eclipse.swt.graphics.Color lightBlue
-
crystal
protected org.eclipse.swt.graphics.Color crystal
-
hopDefault
protected org.eclipse.swt.graphics.Color hopDefault
-
hopTrue
protected org.eclipse.swt.graphics.Color hopTrue
-
deprecated
protected org.eclipse.swt.graphics.Color deprecated
-
-
Method Detail
-
drawLine
public void drawLine(int x, int y, int x2, int y2)
-
drawImage
public void drawImage(IGc.EImage image, int x, int y, float magnification)
-
drawImage
public void drawImage(IGc.EImage image, int x, int y, int width, int height, float magnification)
-
drawImage
public void drawImage(IGc.EImage image, int x, int y, float magnification, double angle)
-
getNativeImage
public static final SwtUniversalImage getNativeImage(IGc.EImage image)
-
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
-
textExtent
public Point textExtent(String text)
- Specified by:
textExtentin interfaceIGc
-
drawTransformIcon
public void drawTransformIcon(int x, int y, TransformMeta transformMeta, float magnification)- Specified by:
drawTransformIconin interfaceIGc
-
drawActionIcon
public void drawActionIcon(int x, int y, ActionMeta actionMeta, float magnification)- Specified by:
drawActionIconin interfaceIGc
-
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
-
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)
-
switchForegroundBackgroundColors
public void switchForegroundBackgroundColors()
- Specified by:
switchForegroundBackgroundColorsin interfaceIGc
-
-