menu

WPF

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

    Show / Hide Table of Contents

    Class LinearMarkTick

    Represents the Major/Minor tick of the linear scale. The Major/Minor ticks are set by using the TickStyle property.

    Inheritance
    System.Object
    GaugeElement
    TickBase
    LinearMarkTick
    Inherited Members
    GaugeElement.BackgroundBrush
    GaugeElement.BackgroundBrushProperty
    GaugeElement.BorderBrush
    GaugeElement.BorderBrushProperty
    GaugeElement.BorderWidth
    GaugeElement.BorderWidthProperty
    TickBase.Angle
    TickBase.AngleChanged
    TickBase.AngleProperty
    TickBase.DistanceFromScale
    TickBase.DistanceFromScaleChanged
    TickBase.DistanceFromScaleProperty
    TickBase.OnAngleChanged(DependencyPropertyChangedEventArgs)
    TickBase.OnDistanceFromScaleChanged(DependencyPropertyChangedEventArgs)
    TickBase.OnTickPlacementChanged(DependencyPropertyChangedEventArgs)
    TickBase.OnTickStyleChanged(DependencyPropertyChangedEventArgs)
    TickBase.RangedBrush
    TickBase.RangedBrushEndValue
    TickBase.RangedBrushEndValueProperty
    TickBase.RangedBrushProperty
    TickBase.RangedBrushStartValue
    TickBase.RangedBrushStartValueProperty
    TickBase.TickPlacement
    TickBase.TickPlacementChanged
    TickBase.TickPlacementProperty
    TickBase.TickStyle
    TickBase.TickStyleChanged
    TickBase.TickStyleProperty
    TickBase.YDistanceFromScale
    TickBase.YDistanceFromScaleProperty
    Namespace: Syncfusion.Windows.Gauge
    Assembly: Syncfusion.Gauge.WPF.dll
    Syntax
    public class LinearMarkTick : TickBase
    Examples
    
    
    
    
    
    
    
    
     
    
    
    
    
    
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Windows;
    using System.Windows.Media;
    using System.Windows.Controls;
    using System.Windows.Data;
    using Syncfusion.Windows.Shared;
    using Syncfusion.Windows.Gauge;

    namespace LinearMarkTickSample { public partial class Window1 : Window { private LinearGauge linearGauge1;

    public Window1() { InitializeComponent();

    linearGauge1 = new LinearGauge(); this.linearGauge1.CenterFrameFillColor = Colors.Brown;

    LinearScale scale = new LinearScale(); scale.Minimum = 0; scale.Maximum = 100; scale.MinorIntervalValue = 2; scale.MajorIntervalValue = 10; scale.ScaleBarSize = 20; scale.ScaleBarLength = 260; linearGauge1.Scales.Add(scale);

    LinearMarkTick markTick1 = new LinearMarkTick(); markTick1.TickHeight = 9; markTick1.TickShape = TickShape.Rectangle; markTick1.TickStyle = TickStyle.MajorTick; markTick1.TickWidth = 4; markTick1.BackgroundBrush = new SolidColorBrush(Colors.Pink); scale.Ticks.Add(markTick1); LinearMarkTick markTick2 = new LinearMarkTick(); markTick2.TickHeight = 4; markTick2.TickWidth = 1; markTick2.TickStyle = TickStyle.MinorTick; markTick2.BackgroundBrush = new SolidColorBrush(Colors.White); scale.Ticks.Add(markTick2);

    this.Content = linearGauge1; } } }

    Constructors

    LinearMarkTick()

    Initializes a new instance of the LinearMarkTick class.

    Declaration
    public LinearMarkTick()

    Fields

    TickHeightProperty

    Identifies the TickHeight dependency property.

    Declaration
    public static readonly DependencyProperty TickHeightProperty
    Field Value
    Type
    System.Windows.DependencyProperty

    TickShapeProperty

    Identifies the TickShape dependency property.

    Declaration
    public static readonly DependencyProperty TickShapeProperty
    Field Value
    Type
    System.Windows.DependencyProperty

    TickWidthProperty

    Identifies the TickWidth dependency property.

    Declaration
    public static readonly DependencyProperty TickWidthProperty
    Field Value
    Type
    System.Windows.DependencyProperty

    Properties

    TickHeight

    Gets or sets the height of the mark tick. This is a dependency property.

    Declaration
    public double TickHeight { get; set; }
    Property Value
    Type Description
    System.Double

    Type: System.Double Default value is 0.

    See Also
    TickWidth

    TickShape

    Gets or sets the shapes of the mark tick. This is a dependency property.

    Declaration
    public TickShape TickShape { get; set; }
    Property Value
    Type Description
    TickShape

    Type: TickShape Default value is TickShape.Rectangle.

    TickWidth

    Gets or sets the width of the mark tick. This is a dependency property.

    Declaration
    public double TickWidth { get; set; }
    Property Value
    Type Description
    System.Double

    Type: System.Double Default value is 0.

    See Also
    TickHeight

    Methods

    ArrangeOverride(Size)

    Positions child elements and determines a size for the element.

    Declaration
    protected override Size ArrangeOverride(Size finalSize)
    Parameters
    Type Name Description
    System.Windows.Size finalSize

    The final area within the parent that this element should use to arrange itself and its children.

    Returns
    Type Description
    System.Windows.Size

    The actual size used.

    MeasureOverride(Size)

    Measures the size in layout required for child elements and determines a size for the element.

    Declaration
    protected override Size MeasureOverride(Size constraint)
    Parameters
    Type Name Description
    System.Windows.Size constraint

    The available size that this element can give to child elements.

    Returns
    Type Description
    System.Windows.Size

    The size that this element determines it needs during layout.

    OnInitialized(EventArgs)

    Raises the System.Windows.FrameworkElement.Initialized event. This method is invoked whenever System.Windows.FrameworkElement.IsInitialized property is set to true internally.

    Declaration
    protected override void OnInitialized(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    The System.EventArgs that contains the event data.

    OnRender(DrawingContext)

    Participates in rendering operations that are directed by the layout system.

    Declaration
    protected override void OnRender(DrawingContext drawingContext)
    Parameters
    Type Name Description
    System.Windows.Media.DrawingContext drawingContext

    The drawing instructions for a specific element.

    Remarks

    • ratiostores the number of segments(relative to Maximum and Minimum values), that can be formed,each of "valueInterval" length.
    • intervalStores the length of one such segment(relative to ScaleBarLength deducting YDistanceFromScale.

    OnTickHeightChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises TickHeightChanged event.

    Declaration
    protected virtual void OnTickHeightChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property change details, such as old value and new value.

    OnTickShapeChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises TickShapeChanged event.

    Declaration
    protected virtual void OnTickShapeChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property change details, such as old value and new value.

    OnTickWidthChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises TickWidthChanged event.

    Declaration
    protected virtual void OnTickWidthChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property change details, such as old value and new value.

    Events

    TickHeightChanged

    Event that is raised when TickHeight property is changed.

    Declaration
    public event PropertyChangedCallback TickHeightChanged
    Event Type
    Type
    System.Windows.PropertyChangedCallback

    TickShapeChanged

    Event that is raised when TickShape property is changed.

    Declaration
    public event PropertyChangedCallback TickShapeChanged
    Event Type
    Type
    System.Windows.PropertyChangedCallback

    TickWidthChanged

    Event that is raised when TickWidth property is changed.

    Declaration
    public event PropertyChangedCallback TickWidthChanged
    Event Type
    Type
    System.Windows.PropertyChangedCallback
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved