PaintingContext
Provides shared clip-bound and scale state while leaving drawing operations to derived contexts.
Definition
Namespace:Telerik.WinControls.UI.Diagrams
Assembly:Telerik.WinControls.RadDiagram.dll
Syntax:
public abstract class PaintingContext : IPaintingContext
Inheritance: objectPaintingContext
Derived Classes:
Implements:
Constructors
protected PaintingContext()
Properties
Gets or sets the clip bounds reported by this context. The base class stores this value but does not apply clipping.
public RectangleF ClipBounds { get; set; }
Implements:
Gets the most recent scale factors supplied to ScaleTransformation(float, float).
public SizeF ScaleFactor { get; protected set; }
Implements:
Methods
Outlines an ellipse inscribed in the specified rectangle.
public abstract void DrawEllipse(RectangleF rectangle, Pen pen)
The rectangle that bounds the ellipse.
penPenThe pen used to draw the outline.
Implements:
Draws an image into the specified destination rectangle using the requested opacity.
public abstract void DrawImage(Image image, RectangleF rectangle, double opacity)
The image to draw.
rectangleRectangleFThe destination rectangle.
opacitydoubleThe opacity factor passed to the drawing implementation.
Implements:
Outlines a rectangle with a pen.
public abstract void DrawRectangle(RectangleF rectangle, Pen pen)
The rectangle to outline.
penPenThe pen used to draw the outline.
Implements:
Fills an ellipse inscribed in the specified rectangle.
public abstract void FillEllipse(RectangleF rectanlge, Brush color)
Implements:
Fills a rectangle with a brush.
public abstract void FillRectangle(RectangleF rectanlge, Brush color)
Implements:
Inverts the colors in the specified rectangle.
public abstract void InvertRectangle(RectangleF rectangle)
The rectangle whose colors are inverted.
Implements:
Resets ScaleFactor to (1, 1) and asks the derived context to reset its drawing transformation.
public void ResetTransformation()
Implements:
Resets the derived drawing surface's transformation.
protected abstract void ResetTransformationOverride()
Updates ScaleFactor and applies the scale through the derived context.