skip navigation
  • Product Bundles

    DevCraft

    All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:

    • AI Coding Assistants
    • Embedded Reporting
    • Document Processing Libraries
    • SSO Account Sign-in

    Web

    Kendo UI UI for Angular UI for Vue UI for jQuery KendoReact UI for Blazor UI for ASP.NET Core UI for ASP.NET MVC UI for ASP.NET AJAX

    Mobile

    UI for .NET MAUI

    Document Management

    Telerik Document Processing

    Desktop

    UI for .NET MAUI UI for WinUI UI for WinForms UI for WPF

    Reporting

    Telerik Reporting Telerik Report Server

    Testing & Mocking

    Test Studio Telerik JustMock

    CMS

    Sitefinity

    AI Productivity Tools

    AI Coding Assistants

    UI/UX Tools

    ThemeBuilder Design System Kit Templates and Building Blocks

    Debugging

    Fiddler Fiddler Everywhere Fiddler Classic Fiddler Everywhere Reporter FiddlerCore

    Free Tools

    KendoReact Free VB.NET to C# Converter Testing Framework
    View all products
  • Overview
  • Demos
    • What's New
    • Roadmap
    • Release History
  • Support and Learning

    • Support and Learning Hub
    • First Steps
    • Docs
    • Demos
    • Virtual Classroom
    • Forums
    • Videos
    • Blogs
    • Accessibility
    • Submit a Ticket

    Productivity and Design Tools

    • Visual Studio Extensions
    • Visual Studio Templates
    • Embedded Reporting
  • Pricing
  • Shopping cart
    • Account Overview
    • Your Licenses
    • Downloads
    • Support Center
    • Forum Profile
    • Payment Methods
    • Edit Profile
    • Log out
  • Login
  • Contact Us
  • Try now

Class VerticalAdjusmentLabelsStrategy

A SmartLabelsStrategyBase that adjusts the labels vertically.

Inheritance
System.Object
SmartLabelsStrategyBase
VerticalAdjusmentLabelsStrategy
Inherited Members
SmartLabelsStrategyBase.DistanceToLabel
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Telerik.WinControls.UI
Assembly: Telerik.WinControls.ChartView.dll

Syntax

public class VerticalAdjusmentLabelsStrategy : SmartLabelsStrategyBase

Constructors

VerticalAdjusmentLabelsStrategy()

Declaration
public VerticalAdjusmentLabelsStrategy()

Properties

DistanceBetweenLabels

Gets or sets the distance between labels.

Declaration
public int DistanceBetweenLabels { get; set; }
Property Value
System.Int32

The distance between labels.

Methods

CalculateLocations(ChartSeriesCollection, Rectangle)

Within this method labels' positions are calculated and are set to the SmartLocation property of each label.

Declaration
public override void CalculateLocations(ChartSeriesCollection series, Rectangle plotArea)
Parameters
ChartSeriesCollection series

All the series in the current chart view.

System.Drawing.Rectangle plotArea

The plot area.

Overrides
SmartLabelsStrategyBase.CalculateLocations(ChartSeriesCollection, Rectangle)

FinalPositionsOptimization(List<LabelElement>)

Optimizes label positions after all labels have been processed.

Declaration
protected virtual void FinalPositionsOptimization(List<LabelElement> labels)
Parameters
System.Collections.Generic.List<LabelElement> labels

The labels.

GetBestPositionInDownwardDirection(List<LabelElement>, LabelElement, CartesianSeries)

Gets the best position in downward direction.

Declaration
protected virtual Rectangle GetBestPositionInDownwardDirection(List<LabelElement> labels, LabelElement labelToMove, CartesianSeries series)
Parameters
System.Collections.Generic.List<LabelElement> labels

The labels.

LabelElement labelToMove

The label to move.

CartesianSeries series

The series.

Returns
System.Drawing.Rectangle

GetBestPositionInLeftDirection(List<LabelElement>, LabelElement, CartesianSeries)

Gets the best position in left direction.

Declaration
protected virtual Rectangle GetBestPositionInLeftDirection(List<LabelElement> labels, LabelElement labelToMove, CartesianSeries series)
Parameters
System.Collections.Generic.List<LabelElement> labels

The labels.

LabelElement labelToMove

The label to move.

CartesianSeries series

The series.

Returns
System.Drawing.Rectangle

GetBestPositionInRightDirection(List<LabelElement>, LabelElement, CartesianSeries)

Gets the best position in right direction.

Declaration
protected virtual Rectangle GetBestPositionInRightDirection(List<LabelElement> labels, LabelElement labelToMove, CartesianSeries series)
Parameters
System.Collections.Generic.List<LabelElement> labels

The labels.

LabelElement labelToMove

The label to move.

CartesianSeries series

The series.

Returns
System.Drawing.Rectangle

GetBestPositionInUpwardDirection(List<LabelElement>, LabelElement, CartesianSeries)

Gets the best position in upward direction.

Declaration
protected virtual Rectangle GetBestPositionInUpwardDirection(List<LabelElement> labels, LabelElement labelToMove, CartesianSeries series)
Parameters
System.Collections.Generic.List<LabelElement> labels

The labels.

LabelElement labelToMove

The label to move.

CartesianSeries series

The series.

Returns
System.Drawing.Rectangle

GetElementWithMostOverlaps(List<LabelElement>, ChartSeriesCollection)

Gets the element with most overlaps.

Declaration
protected virtual LabelElement GetElementWithMostOverlaps(List<LabelElement> labels, ChartSeriesCollection series)
Parameters
System.Collections.Generic.List<LabelElement> labels

The labels.

ChartSeriesCollection series

The series.

Returns
LabelElement

HasCollisions(List<LabelElement>, LabelElement, Rectangle)

Determines whether the specified label rectangle has collisions with the rest of the labels.

Declaration
protected virtual bool HasCollisions(List<LabelElement> labels, LabelElement labelToMove, Rectangle currentRect)
Parameters
System.Collections.Generic.List<LabelElement> labels

The labels.

LabelElement labelToMove

The label to move.

System.Drawing.Rectangle currentRect

The current rect for the label being moved.

Returns
System.Boolean

true if the specified rect has collisions; otherwise, false.

LineIntersectsLine(Point, Point, Point, Point)

Returns a value indicating whether two lines intersect.

Declaration
protected virtual bool LineIntersectsLine(Point l1p1, Point l1p2, Point l2p1, Point l2p2)
Parameters
System.Drawing.Point l1p1

The begin point of the first line.

System.Drawing.Point l1p2

The end point of the first line

System.Drawing.Point l2p1

The begin point of the second line.

System.Drawing.Point l2p2

The end point of the second line.

Returns
System.Boolean

LineIntersectsRect(Point, Point, Rectangle)

Returns a value indicating whether a line represented with two points intersects the given rectangle.

Declaration
protected virtual bool LineIntersectsRect(Point p1, Point p2, Rectangle r)
Parameters
System.Drawing.Point p1

The begin point of the line.

System.Drawing.Point p2

The end point of the line.

System.Drawing.Rectangle r

The rectangle.

Returns
System.Boolean

RestrictWithinAxes(List<LabelElement>, CartesianSeries)

Restricts rectangles within the chart axes.

Declaration
protected virtual void RestrictWithinAxes(List<LabelElement> labels, CartesianSeries series)
Parameters
System.Collections.Generic.List<LabelElement> labels

The labels.

CartesianSeries series

The series.

SeriesLineIntersectsLine(ChartSeries, Point, Point)

Returns a value indicating whether the series line intersects with the given line.

Declaration
protected virtual bool SeriesLineIntersectsLine(ChartSeries chartSeries, Point p1, Point p2)
Parameters
ChartSeries chartSeries

The chart series.

System.Drawing.Point p1

The begin point of the line.

System.Drawing.Point p2

The end point of the line.

Returns
System.Boolean

SeriesLineIntersectsRect(ChartSeries, Rectangle)

Returns a value indicating whether the series line intersects with the rectangle.

Declaration
protected virtual bool SeriesLineIntersectsRect(ChartSeries chartSeries, Rectangle rect)
Parameters
ChartSeries chartSeries

The chart series.

System.Drawing.Rectangle rect

The rect.

Returns
System.Boolean

Extension Methods

SvgExtentions.Traverse<T>(T, Func<T, IEnumerable<T>>)
SvgExtentions.TraverseDepthFirst<T>(T, Func<T, IEnumerable<T>>)
Getting Started
  • Install Now
  • Demos
  • Step-by-Step Tutorial
  • Sample Applications
  • SDK Samples
  • Visual Studio Extensions
Support Resources
  • Code Library
  • Knowledge Base
  • Videos
Community
  • Forums
  • Blogs
  • Feedback Portal
  • Document Processing Feedback Portal

Copyright © 2018 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.