New to Telerik UI for WinForms? Start a free 30-day trial

Base class for renderer draw parts that operate on a specific chart-element type.

Definition

Constructors

Associates the draw part with the chart element and renderer it uses.

C#
public DrawPart(T element, IChartRenderer renderer)
Parameters:elementT

The chart element to render.

rendererIChartRenderer

The renderer that supplies the drawing surface and context.

Properties

Gets the element.

C#
public T Element { get; }
Property Value:

The element.

Gets the offset X.

C#
public virtual float OffsetX { get; }
Property Value:

The offset X.

Gets the offset Y.

C#
public virtual float OffsetY { get; }
Property Value:

The offset Y.

Gets the renderer.

C#
public IChartRenderer Renderer { get; }
Property Value:

The renderer.

Implements: IDrawPart.Renderer

Gets the view port offset X.

C#
public virtual float ViewportOffsetX { get; }
Property Value:

The view port offset X.

Gets the view port offset Y.

C#
public virtual float ViewportOffsetY { get; }
Property Value:

The view port offset Y.

Methods

Draws this instance.

C#
public abstract void Draw()

Implements: IDrawPart.Draw()

Gets the label position.

C#
public virtual PointF GetLabelPosition(RadSize textSize, RadRect labelSlot)
Parameters:textSizeRadSize

Size of the text.

labelSlotRadRect

The label slot.

Returns:

PointF

Hits the test.

C#
public virtual DataPoint HitTest(Point location)
Parameters:locationPoint

The location.

Returns:

DataPoint

Implements: IDrawPart.HitTest(Point)

Determines whether the element is valid.

C#
protected virtual bool IsElementValid()
Returns:

bool