Package org.eclipse.draw2d
Class ScaledGraphics
java.lang.Object
org.eclipse.draw2d.Graphics
org.eclipse.draw2d.ScaledGraphics
- Direct Known Subclasses:
- PrinterGraphics
A Graphics object able to scale all operations based on the current scale
 factor.
- 
Nested Class SummaryNested ClassesModifier and TypeClassDescriptionprotected static classThe internal state of the scaled graphics.
- 
Field SummaryFields inherited from class org.eclipse.draw2d.GraphicsLINE_CUSTOM, LINE_DASH, LINE_DASHDOT, LINE_DASHDOTDOT, LINE_DOT, LINE_SOLID
- 
Constructor SummaryConstructorsConstructorDescriptionConstructs a new ScaledGraphics based on the given Graphics object.
- 
Method SummaryModifier and TypeMethodDescriptionvoidSets the clip region to the given rectangle.voidSets the clip region to the given rectangle.voiddispose()Disposes this object, releasing any resources.voiddrawArc(int x, int y, int w, int h, int offset, int sweep) Draws the outline of an arc located at (x,y) with width w and height h.voiddrawFocus(int x, int y, int w, int h) Draws a focus rectangle.voidDraws the given Image at the location (x,y).voidDraws a rectangular section of the given Image to the specified rectangular reagion on the canvas.voiddrawLine(int x1, int y1, int x2, int y2) Draws a line between the points(x1,y1)and(x2,y2)using the foreground color.voiddrawOval(int x, int y, int w, int h) Draws the outline of an ellipse that fits inside the rectangle with the given properties using the foreground color.voidDraws the given path.voiddrawPoint(int x, int y) Draws a pixel, using the foreground color, at the specified point (x,y).voiddrawPolygon(int[] points) Draws a closed polygon defined by the given Integer array containing the vertices in x,y order.voiddrawPolygon(PointList points) Draws a closed polygon defined by the givenPointListcontaining the vertices.voiddrawPolyline(int[] points) Draws a polyline defined by the given Integer array containing the vertices in x,y order.voiddrawPolyline(PointList points) Draws a polyline defined by the givenPointListcontaining the vertices.voiddrawRectangle(int x, int y, int w, int h) Draws a rectangle whose top-left corner is located at the point (x,y) with the given width and height.voiddrawRoundRectangle(Rectangle r, int arcWidth, int arcHeight) Draws a rectangle with rounded corners using the foreground color.voiddrawString(String s, int x, int y) Draws the given string using the current font and foreground color.voidDraws the given string using the current font and foreground color.voidDraws a string using the specified styles.voiddrawTextLayout(TextLayout layout, int x, int y, int selectionStart, int selectionEnd, Color selectionForeground, Color selectionBackground) voidfillArc(int x, int y, int w, int h, int offset, int sweep) Fills the interior of an arc located at (x,y) with width w and height h.voidfillGradient(int x, int y, int w, int h, boolean vertical) Fills the the given rectangle with a gradient from the foreground color to the background color.voidfillOval(int x, int y, int w, int h) Fills an ellipse that fits inside the rectangle with the given properties using the background color.voidFills the given path.voidfillPolygon(int[] points) Fills a closed polygon defined by the given Integer array containing the vertices in x,y order.voidfillPolygon(PointList points) Fills a closed polygon defined by the givenPointListcontaining the vertices.voidfillRectangle(int x, int y, int w, int h) Fills a rectangle whose top-left corner is located at the point (x,y) with the given width and height.voidfillRoundRectangle(Rectangle r, int arcWidth, int arcHeight) Fills a rectangle with rounded corners using the background color.voidfillString(String s, int x, int y) Draws the given string using the current font and foreground color.voidDraws the given string using the current font and foreground color.doubleReturns the current absolute scaling which will be applied to the underlying Device when painting to this Graphics.booleanintgetAlpha()Returns the current alpha value of the graphics.intReturns the anti-aliasing setting value, which will be one ofSWT.DEFAULT,SWT.OFForSWT.ON.Returns the background color used for filling.Modifies the given rectangle to match the clip region and returns that rectangle.intReturns the fill rule, which will be one ofSWT.FILL_EVEN_ODDorSWT.FILL_WINDING.getFont()Returns the font used to draw and fill text.Returns the font metrics for the current font.Returns the foreground color used to draw lines and text.intReturns the interpolation setting.Returns the current collection of line attributes.intReturns the current line cap style.intReturns the line join style.floatReturns the line miter limit.intReturns the line style.intReturns the current line width.floatReturns the current line width.intReturns the textual anti-aliasing setting value, which will be one ofSWT.DEFAULT,SWT.OFForSWT.ON.booleanReturnstrueif this graphics object should use XOR mode with painting.voidpopState()Pops the previous state of this graphics object off the stack (ifGraphics.pushState()has previously been called) and restores the current state to that popped state.voidPushes the current state of this graphics object onto a stack.voidRestores the previous state of this graphics object.voidrotate(float degrees) Rotates the coordinates by the given counter-clockwise angle.voidscale(double amount) Scales this graphics object by the given amount.voidsetAdvanced(boolean advanced) Turns advanced graphics mode on or off.voidsetAlpha(int alpha) Sets the alpha to the given value.voidsetAntialias(int value) Sets the anti-aliasing value to the parameter, which must be one ofSWT.DEFAULT,SWT.OFForSWT.ON.voidsetBackgroundColor(Color rgb) Sets the background color.voidsetBackgroundPattern(Pattern pattern) Sets the pattern used for fill-type graphics operations.voidSets the clip rectangle.voidSets the area which can be affected by drawing operations to the specifiedPath.voidsetFillRule(int rule) Sets the fill rule to the given value, which must be one ofSWT.FILL_EVEN_ODDorSWT.FILL_WINDING.voidSets the font.voidsetForegroundColor(Color rgb) Sets the foreground color.voidsetForegroundPattern(Pattern pattern) Sets the foreground pattern for draw and text operations.voidsetInterpolation(int interpolation) Sets the interpolation setting to the given value, which must be one ofSWT.DEFAULT,SWT.NONE,SWT.LOWorSWT.HIGH.voidsetLineAttributes(LineAttributes attributes) Sets all line attributes togethervoidsetLineCap(int cap) Sets the line cap style to the argument, which must be one of the constantsSWT.CAP_FLAT,SWT.CAP_ROUND, orSWT.CAP_SQUARE.voidsetLineDash(float[] dash) Sets the dash pattern when the custom line style is in use.voidsetLineDash(int[] dash) Sets the dash pattern when the custom line style is in use.voidsetLineDashOffset(float value) Sets the line dash offset.voidsetLineJoin(int join) Sets the line join style to the argument, which must be one of the constantsSWT.JOIN_MITER,SWT.JOIN_ROUND, orSWT.JOIN_BEVEL.voidsetLineMiterLimit(float value) voidsetLineStyle(int style) Sets the line style to the argument, which must be one of the constantsSWT.LINE_SOLID,SWT.LINE_DASH,SWT.LINE_DOT,SWT.LINE_DASHDOTorSWT.LINE_DASHDOTDOT.voidsetLineWidth(int width) Sets the line width.voidsetLineWidthFloat(float width) Sets the line width.voidsetTextAntialias(int value) Sets the textual anti-aliasing value to the parameter, which must be one ofSWT.DEFAULT,SWT.OFForSWT.ON.voidsetXORMode(boolean b) Sets the XOR mode.voidtranslate(float dx, float dy) Modifies the current transform by translating the given x and y amounts.voidtranslate(int dx, int dy) Translates the receiver's coordinates by the specified x and y amounts.Methods inherited from class org.eclipse.draw2d.GraphicsdrawArc, drawFocus, drawImage, drawImage, drawLine, drawOval, drawRectangle, drawString, drawText, drawText, drawTextLayout, fillArc, fillGradient, fillOval, fillRectangle, fillString, fillText, scale, shear, translate
- 
Constructor Details- 
ScaledGraphicsConstructs a new ScaledGraphics based on the given Graphics object.- Parameters:
- g- the base graphics object
 
 
- 
- 
Method Details- 
clipRectDescription copied from class:GraphicsSets the clip region to the given rectangle. Anything outside this rectangle will not be drawn.
- 
disposepublic void dispose()Description copied from class:GraphicsDisposes this object, releasing any resources.
- 
drawArcpublic void drawArc(int x, int y, int w, int h, int offset, int sweep) Description copied from class:GraphicsDraws the outline of an arc located at (x,y) with width w and height h. The starting angle of the arc (specified in degrees) is offset and length is the arc's angle (specified in degrees).
- 
drawFocuspublic void drawFocus(int x, int y, int w, int h) Description copied from class:GraphicsDraws a focus rectangle.
- 
drawImageDescription copied from class:GraphicsDraws the given Image at the location (x,y).
- 
drawImagepublic void drawImage(Image srcImage, int sx, int sy, int sw, int sh, int tx, int ty, int tw, int th) Description copied from class:GraphicsDraws a rectangular section of the given Image to the specified rectangular reagion on the canvas. The section of the image bounded by the rectangle (x1,y1,w1,h1) is copied to the section of the canvas bounded by the rectangle (x2,y2,w2,h2). If these two sizes are different, scaling will occur.- Specified by:
- drawImagein class- Graphics
- Parameters:
- srcImage- the image
- sx- the x coordinate of the source
- sy- the y coordinate of the source
- sw- the width of the source
- sh- the height of the source
- tx- the x coordinate of the destination
- ty- the y coordinate of the destination
- tw- the width of the destination
- th- the height of the destination
- See Also:
 
- 
drawLinepublic void drawLine(int x1, int y1, int x2, int y2) Description copied from class:GraphicsDraws a line between the points(x1,y1)and(x2,y2)using the foreground color.
- 
drawOvalpublic void drawOval(int x, int y, int w, int h) Description copied from class:GraphicsDraws the outline of an ellipse that fits inside the rectangle with the given properties using the foreground color.
- 
drawPathDescription copied from class:GraphicsDraws the given path.
- 
drawPointpublic void drawPoint(int x, int y) Description copied from class:GraphicsDraws a pixel, using the foreground color, at the specified point (x,y).Note that the current line attributes do not affect this operation. 
- 
drawPolygonpublic void drawPolygon(int[] points) Description copied from class:GraphicsDraws a closed polygon defined by the given Integer array containing the vertices in x,y order. The first and last points in the list will be connected.- Overrides:
- drawPolygonin class- Graphics
- Parameters:
- points- the vertices
- See Also:
 
- 
drawPolygonDescription copied from class:GraphicsDraws a closed polygon defined by the givenPointListcontaining the vertices. The first and last points in the list will be connected.- Specified by:
- drawPolygonin class- Graphics
- Parameters:
- points- the vertices
- See Also:
 
- 
drawPolylinepublic void drawPolyline(int[] points) Description copied from class:GraphicsDraws a polyline defined by the given Integer array containing the vertices in x,y order. The first and last points in the list will not be connected.- Overrides:
- drawPolylinein class- Graphics
- Parameters:
- points- the vertices
- See Also:
 
- 
drawPolylineDescription copied from class:GraphicsDraws a polyline defined by the givenPointListcontaining the vertices. The first and last points in the list will not be connected.- Specified by:
- drawPolylinein class- Graphics
- Parameters:
- points- the vertices
- See Also:
 
- 
drawRectanglepublic void drawRectangle(int x, int y, int w, int h) Description copied from class:GraphicsDraws a rectangle whose top-left corner is located at the point (x,y) with the given width and height.- Specified by:
- drawRectanglein class- Graphics
- Parameters:
- x- the x coordinate
- y- the y coordinate
- w- the width
- h- the height
- See Also:
 
- 
drawRoundRectangleDescription copied from class:GraphicsDraws a rectangle with rounded corners using the foreground color. arcWidth and arcHeight represent the horizontal and vertical diameter of the corners.- Specified by:
- drawRoundRectanglein class- Graphics
- Parameters:
- r- the rectangle
- arcWidth- the arc width
- arcHeight- the arc height
- See Also:
 
- 
drawStringDescription copied from class:GraphicsDraws the given string using the current font and foreground color. No tab expansion or carriage return processing will be performed. The background of the string will be transparent.- Specified by:
- drawStringin class- Graphics
- Parameters:
- s- the string
- x- the x coordinate
- y- the y coordinate
- See Also:
 
- 
drawTextDescription copied from class:GraphicsDraws the given string using the current font and foreground color. Tab expansion and carriage return processing are performed. The background of the text will be transparent.
- 
drawTextDescription copied from class:GraphicsDraws a string using the specified styles. The styles are defined byGC.drawText(String, int, int, int).
- 
drawTextLayoutpublic void drawTextLayout(TextLayout layout, int x, int y, int selectionStart, int selectionEnd, Color selectionForeground, Color selectionBackground) - Overrides:
- drawTextLayoutin class- Graphics
- Parameters:
- layout- the TextLayout being rendered
- x- the x location
- y- the y location
- selectionStart- the start of selection
- selectionEnd- the end of selection
- selectionForeground- the foreground selection color
- selectionBackground- the background selection color
- See Also:
 
- 
fillArcpublic void fillArc(int x, int y, int w, int h, int offset, int sweep) Description copied from class:GraphicsFills the interior of an arc located at (x,y) with width w and height h. The starting angle of the arc (specified in degrees) is offset and length is the arc's angle (specified in degrees).
- 
fillGradientpublic void fillGradient(int x, int y, int w, int h, boolean vertical) Description copied from class:GraphicsFills the the given rectangle with a gradient from the foreground color to the background color. If vertical istrue, the gradient will go from top to bottom. Otherwise, it will go from left to right. background color.- Specified by:
- fillGradientin class- Graphics
- Parameters:
- x- the x coordinate
- y- the y coordinate
- w- the width
- h- the height
- vertical- whether the gradient should be vertical
- See Also:
 
- 
fillOvalpublic void fillOval(int x, int y, int w, int h) Description copied from class:GraphicsFills an ellipse that fits inside the rectangle with the given properties using the background color.
- 
fillPathDescription copied from class:GraphicsFills the given path.
- 
fillPolygonpublic void fillPolygon(int[] points) Description copied from class:GraphicsFills a closed polygon defined by the given Integer array containing the vertices in x,y order. The first and last points in the list will be connected.- Overrides:
- fillPolygonin class- Graphics
- Parameters:
- points- the vertices
- See Also:
 
- 
fillPolygonDescription copied from class:GraphicsFills a closed polygon defined by the givenPointListcontaining the vertices. The first and last points in the list will be connected.- Specified by:
- fillPolygonin class- Graphics
- Parameters:
- points- the vertices
- See Also:
 
- 
fillRectanglepublic void fillRectangle(int x, int y, int w, int h) Description copied from class:GraphicsFills a rectangle whose top-left corner is located at the point (x,y) with the given width and height.- Specified by:
- fillRectanglein class- Graphics
- Parameters:
- x- the x coordinate
- y- the y coordinate
- w- the width
- h- the height
- See Also:
 
- 
fillRoundRectangleDescription copied from class:GraphicsFills a rectangle with rounded corners using the background color. arcWidth and arcHeight represent the horizontal and vertical diameter of the corners.- Specified by:
- fillRoundRectanglein class- Graphics
- Parameters:
- r- the rectangle
- arcWidth- the arc width
- arcHeight- the arc height
- See Also:
 
- 
fillStringDescription copied from class:GraphicsDraws the given string using the current font and foreground color. No tab expansion or carriage return processing will be performed. The background of the string will be filled with the current background color.- Specified by:
- fillStringin class- Graphics
- Parameters:
- s- the string
- x- the x coordinate
- y- the y coordinate
- See Also:
 
- 
fillTextDescription copied from class:GraphicsDraws the given string using the current font and foreground color. Tab expansion and carriage return processing are performed. The background of the text will be filled with the current background color.
- 
getAbsoluteScalepublic double getAbsoluteScale()Description copied from class:GraphicsReturns the current absolute scaling which will be applied to the underlying Device when painting to this Graphics. The default value is 1.0.- Overrides:
- getAbsoluteScalein class- Graphics
- Returns:
- the effective absolute scaling factor
- See Also:
 
- 
getAlphapublic int getAlpha()Description copied from class:GraphicsReturns the current alpha value of the graphics.
- 
getAntialiaspublic int getAntialias()Description copied from class:GraphicsReturns the anti-aliasing setting value, which will be one ofSWT.DEFAULT,SWT.OFForSWT.ON. Note that this controls anti-aliasing for all non-text drawing operations.- Overrides:
- getAntialiasin class- Graphics
- Returns:
- the anti-alias setting
- See Also:
 
- 
getBackgroundColorDescription copied from class:GraphicsReturns the background color used for filling.- Specified by:
- getBackgroundColorin class- Graphics
- Returns:
- the background color
- See Also:
 
- 
getClipDescription copied from class:GraphicsModifies the given rectangle to match the clip region and returns that rectangle.
- 
getAdvancedpublic boolean getAdvanced()- Overrides:
- getAdvancedin class- Graphics
- Returns:
- true if the underlying graphics device is using advanced graphics mode.
- See Also:
 
- 
getFillRulepublic int getFillRule()Description copied from class:GraphicsReturns the fill rule, which will be one ofSWT.FILL_EVEN_ODDorSWT.FILL_WINDING.- Overrides:
- getFillRulein class- Graphics
- Returns:
- the fill rule
- See Also:
 
- 
getFontDescription copied from class:GraphicsReturns the font used to draw and fill text.
- 
getFontMetricsDescription copied from class:GraphicsReturns the font metrics for the current font.- Specified by:
- getFontMetricsin class- Graphics
- Returns:
- the font metrics
- See Also:
 
- 
getForegroundColorDescription copied from class:GraphicsReturns the foreground color used to draw lines and text.- Specified by:
- getForegroundColorin class- Graphics
- Returns:
- the foreground color
- See Also:
 
- 
getInterpolationpublic int getInterpolation()Description copied from class:GraphicsReturns the interpolation setting.- Overrides:
- getInterpolationin class- Graphics
- Returns:
- the interpolation setting
- See Also:
 
- 
getLineCappublic int getLineCap()Description copied from class:GraphicsReturns the current line cap style.- Overrides:
- getLineCapin class- Graphics
- Returns:
- the cap style used for drawing lines
- See Also:
 
- 
getLineJoinpublic int getLineJoin()Description copied from class:GraphicsReturns the line join style.- Overrides:
- getLineJoinin class- Graphics
- Returns:
- the join style used for drawing lines
- See Also:
 
- 
getLineStylepublic int getLineStyle()Description copied from class:GraphicsReturns the line style.- Specified by:
- getLineStylein class- Graphics
- Returns:
- the line style
- See Also:
 
- 
getLineMiterLimitpublic float getLineMiterLimit()Description copied from class:GraphicsReturns the line miter limit.- Overrides:
- getLineMiterLimitin class- Graphics
- Returns:
- miter limit
- See Also:
 
- 
getLineWidthpublic int getLineWidth()Description copied from class:GraphicsReturns the current line width.- Specified by:
- getLineWidthin class- Graphics
- Returns:
- the line width
- See Also:
 
- 
getLineWidthFloatpublic float getLineWidthFloat()Description copied from class:GraphicsReturns the current line width.- Specified by:
- getLineWidthFloatin class- Graphics
- Returns:
- the line width
- See Also:
 
- 
getLineAttributesDescription copied from class:GraphicsReturns the current collection of line attributes.- Overrides:
- getLineAttributesin class- Graphics
- Returns:
- all attributes used for line drawing
- See Also:
 
- 
getTextAntialiaspublic int getTextAntialias()Description copied from class:GraphicsReturns the textual anti-aliasing setting value, which will be one ofSWT.DEFAULT,SWT.OFForSWT.ON. Note that this controls anti-aliasing only for text drawing operations.- Overrides:
- getTextAntialiasin class- Graphics
- Returns:
- the anti-aliasing setting
- See Also:
 
- 
getXORModepublic boolean getXORMode()Description copied from class:GraphicsReturnstrueif this graphics object should use XOR mode with painting.- Specified by:
- getXORModein class- Graphics
- Returns:
- whether XOR mode is turned on
- See Also:
 
- 
popStatepublic void popState()Description copied from class:GraphicsPops the previous state of this graphics object off the stack (ifGraphics.pushState()has previously been called) and restores the current state to that popped state.
- 
pushStatepublic void pushState()Description copied from class:GraphicsPushes the current state of this graphics object onto a stack.
- 
restoreStatepublic void restoreState()Description copied from class:GraphicsRestores the previous state of this graphics object.- Specified by:
- restoreStatein class- Graphics
- See Also:
 
- 
rotatepublic void rotate(float degrees) Description copied from class:GraphicsRotates the coordinates by the given counter-clockwise angle. All subsequent painting will be performed in the resulting coordinates. Some functions are illegal when a rotated coordinates system is in use. To restore access to those functions, it is necessary to call restore or pop to return to a non rotated state.
- 
scalepublic void scale(double amount) Description copied from class:GraphicsScales this graphics object by the given amount.
- 
setAdvancedpublic void setAdvanced(boolean advanced) Description copied from class:GraphicsTurns advanced graphics mode on or off.- Overrides:
- setAdvancedin class- Graphics
- Parameters:
- advanced-
- See Also:
 
- 
setAlphapublic void setAlpha(int alpha) Description copied from class:GraphicsSets the alpha to the given value. Values may range from 0 to 255. A value of 0 is completely transparent.
- 
setAntialiaspublic void setAntialias(int value) Description copied from class:GraphicsSets the anti-aliasing value to the parameter, which must be one ofSWT.DEFAULT,SWT.OFForSWT.ON. Note that this controls anti-aliasing for all non-text drawing operations.- Overrides:
- setAntialiasin class- Graphics
- Parameters:
- value- the anti-alias value
- See Also:
 
- 
setBackgroundColorDescription copied from class:GraphicsSets the background color.- Specified by:
- setBackgroundColorin class- Graphics
- Parameters:
- rgb- the new background color
- See Also:
 
- 
setClipDescription copied from class:GraphicsSets the area which can be affected by drawing operations to the specifiedPath.
- 
setBackgroundPatternDescription copied from class:GraphicsSets the pattern used for fill-type graphics operations. The pattern must not be disposed while it is being used by the graphics.- Overrides:
- setBackgroundPatternin class- Graphics
- Parameters:
- pattern- the background pattern
- See Also:
 
- 
setClipDescription copied from class:GraphicsSets the clip rectangle. Painting will not occur outside this area.
- 
clipPathDescription copied from class:GraphicsSets the clip region to the given rectangle. Anything outside this rectangle will not be drawn. Takes into account current clipping area set on the graphics.
- 
setFillRulepublic void setFillRule(int rule) Description copied from class:GraphicsSets the fill rule to the given value, which must be one ofSWT.FILL_EVEN_ODDorSWT.FILL_WINDING.- Overrides:
- setFillRulein class- Graphics
- Parameters:
- rule- the fill rule
- See Also:
 
- 
setFontDescription copied from class:GraphicsSets the font.
- 
setForegroundColorDescription copied from class:GraphicsSets the foreground color.- Specified by:
- setForegroundColorin class- Graphics
- Parameters:
- rgb- the new foreground color
- See Also:
 
- 
setForegroundPatternDescription copied from class:GraphicsSets the foreground pattern for draw and text operations. The pattern must not be disposed while it is being referenced by the graphics.- Overrides:
- setForegroundPatternin class- Graphics
- Parameters:
- pattern- the foreground pattern
- See Also:
 
- 
setInterpolationpublic void setInterpolation(int interpolation) Description copied from class:GraphicsSets the interpolation setting to the given value, which must be one ofSWT.DEFAULT,SWT.NONE,SWT.LOWorSWT.HIGH. This setting is relevant when working with Images.- Overrides:
- setInterpolationin class- Graphics
- Parameters:
- interpolation- the interpolation
- See Also:
 
- 
setLineCappublic void setLineCap(int cap) Description copied from class:GraphicsSets the line cap style to the argument, which must be one of the constantsSWT.CAP_FLAT,SWT.CAP_ROUND, orSWT.CAP_SQUARE.- Overrides:
- setLineCapin class- Graphics
- Parameters:
- cap- the line cap
- See Also:
 
- 
setLineDashpublic void setLineDash(int[] dash) Description copied from class:GraphicsSets the dash pattern when the custom line style is in use. Because this feature is rarely used, the dash pattern may not be preserved when callingGraphics.pushState()andGraphics.popState().- Overrides:
- setLineDashin class- Graphics
- Parameters:
- dash- the pixel pattern
- See Also:
 
- 
setLineDashpublic void setLineDash(float[] dash) Description copied from class:GraphicsSets the dash pattern when the custom line style is in use.- Overrides:
- setLineDashin class- Graphics
- Parameters:
- dash- the pixel pattern.
- See Also:
 
- 
setLineDashOffsetpublic void setLineDashOffset(float value) Description copied from class:GraphicsSets the line dash offset.- Overrides:
- setLineDashOffsetin class- Graphics
- Parameters:
- value-
- See Also:
 
- 
setLineJoinpublic void setLineJoin(int join) Description copied from class:GraphicsSets the line join style to the argument, which must be one of the constantsSWT.JOIN_MITER,SWT.JOIN_ROUND, orSWT.JOIN_BEVEL.- Overrides:
- setLineJoinin class- Graphics
- Parameters:
- join- the join type
- See Also:
 
- 
setLineStylepublic void setLineStyle(int style) Description copied from class:GraphicsSets the line style to the argument, which must be one of the constantsSWT.LINE_SOLID,SWT.LINE_DASH,SWT.LINE_DOT,SWT.LINE_DASHDOTorSWT.LINE_DASHDOTDOT.- Specified by:
- setLineStylein class- Graphics
- Parameters:
- style- the new style
- See Also:
 
- 
setLineMiterLimitpublic void setLineMiterLimit(float value) - Specified by:
- setLineMiterLimitin class- Graphics
- Parameters:
- value-
- See Also:
 
- 
setLineWidthpublic void setLineWidth(int width) Description copied from class:GraphicsSets the line width.- Specified by:
- setLineWidthin class- Graphics
- Parameters:
- width- the new width
- See Also:
 
- 
setLineWidthFloatpublic void setLineWidthFloat(float width) Description copied from class:GraphicsSets the line width.- Specified by:
- setLineWidthFloatin class- Graphics
- Parameters:
- width- the new width
- See Also:
 
- 
setLineAttributesDescription copied from class:GraphicsSets all line attributes together- Overrides:
- setLineAttributesin class- Graphics
- Parameters:
- attributes- the line attributes
- See Also:
 
- 
setTextAntialiaspublic void setTextAntialias(int value) Description copied from class:GraphicsSets the textual anti-aliasing value to the parameter, which must be one ofSWT.DEFAULT,SWT.OFForSWT.ON. Note that this controls anti-aliasing only for all text drawing operations.- Overrides:
- setTextAntialiasin class- Graphics
- Parameters:
- value- the textual anti-alias setting
- See Also:
 
- 
setXORModepublic void setXORMode(boolean b) Description copied from class:GraphicsSets the XOR mode.- Specified by:
- setXORModein class- Graphics
- Parameters:
- b- the new XOR mode
- See Also:
 
- 
translatepublic void translate(int dx, int dy) Description copied from class:GraphicsTranslates the receiver's coordinates by the specified x and y amounts. All subsequent painting will be performed in the resulting coordinate system. Integer translation used by itself does not require or start the use of the advanced graphics system in SWT. It is emulated until advanced graphics are triggered.
- 
translatepublic void translate(float dx, float dy) Description copied from class:GraphicsModifies the current transform by translating the given x and y amounts. All subsequent painting will be performed in the resulting coordinate system.
 
-