menu

WPF

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class ChartSeriesPresenter.ChartSegmentPresenter - WPF API Reference | Syncfusion

    Show / Hide Table of Contents

    Class ChartSeriesPresenter.ChartSegmentPresenter

    Represents ChartSegmentPresenter class

    Inheritance
    System.Object
    ChartSeriesPresenter.ChartSegmentPresenter
    Implements
    System.IDisposable
    Namespace: Syncfusion.Windows.Chart
    Assembly: Syncfusion.Chart.Wpf.dll
    Syntax
    public class ChartSegmentPresenter : ContentPresenter, IDisposable
    Examples

    The below given code illustrates how Chartsegment could be selected when the user mouse downs on a data point segment.

    private void Canvas_MouseDown(object sender, MouseButtonEventArgs e)
    {
        // Get the corresponding ChartSegment
        ChartSegment seg =
    ((ChartSeriesPresenter.ChartSegmentPresenter)(((Canvas)sender).TemplatedParent)).Segment;
        // Get the corresponding bound CollectionView
        CollectionView cv = seg.Series.DataSource as CollectionView;
        // Set the CurrentItem in the CollectionView
        cv.MoveCurrentToPosition(seg.CorrespondingPoints[0].Index);
    }

    Constructors

    ChartSegmentPresenter(ChartSegment)

    Initializes a new instance of the ChartSeriesPresenter.ChartSegmentPresenter class.

    Declaration
    public ChartSegmentPresenter(ChartSegment segment)
    Parameters
    Type Name Description
    ChartSegment segment

    The segment.

    Properties

    Segment

    Gets the segment.

    Declaration
    public ChartSegment Segment { get; }
    Property Value
    Type Description
    ChartSegment

    The segment.

    Methods

    Dispose()

    Clean up any resources being used.

    Declaration
    public void Dispose()

    Implements

    System.IDisposable
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved