Slider.TickFrequency Slider.TickFrequency Slider.TickFrequency Slider.TickFrequency Property

定義

目盛りの間隔を取得または設定します。Gets or sets the interval between tick marks.

public:
 property double TickFrequency { double get(); void set(double value); };
[System.ComponentModel.Bindable(true)]
public double TickFrequency { get; set; }
member this.TickFrequency : double with get, set
Public Property TickFrequency As Double

プロパティ値

目盛り間の距離。The distance between tick marks. 既定値は (1.0) です。The default is (1.0).

TickFrequency プロパティを設定する方法を次の例に示します。The following example shows how to set the TickFrequency property.

Slider hslider = new Slider();
hslider.Width = 100;
hslider.Orientation = Orientation.Horizontal;
hslider.IsSnapToTickEnabled = true;
hslider.Minimum = 1;
hslider.Maximum = 20;
hslider.TickPlacement = TickPlacement.Both;
hslider.TickFrequency = 2;
hslider.AutoToolTipPlacement =
  AutoToolTipPlacement.BottomRight;
cv1.Children.Add(hslider);
Dim hslider As New Slider()
hslider.Width = 100
hslider.Orientation = Orientation.Horizontal
hslider.IsSnapToTickEnabled = True
hslider.Minimum = 1
hslider.Maximum = 20
hslider.TickPlacement = TickPlacement.Both
hslider.TickFrequency = 2
hslider.AutoToolTipPlacement = AutoToolTipPlacement.BottomRight
cv1.Children.Add(hslider)
<Slider Name="slider1" 
        Width="100" 
        Orientation="Horizontal" HorizontalAlignment="Left" 
        IsSnapToTickEnabled="True" Minimum="1" Maximum="20" 
        TickPlacement="Both"  TickFrequency="2"
        AutoToolTipPlacement="BottomRight"/>

注釈

場合、Ticksはない値に設定されてnullTickFrequencyプロパティは使用されません。If the Ticks property is set to a value that is not null, the TickFrequency property is not used.

TickPlacementプロパティを以外の値に設定する必要がありますNoneに沿って表示するの目盛り、Sliderします。The TickPlacement property must be set to a value other than None for tick marks to appear along the Slider.

指定された間隔で目盛りが描画されます、TickFrequencyプロパティ。Tick marks are drawn at an interval that is specified by the TickFrequency property. 値に目盛りマーク開始、Minimumプロパティの値になるまで続行し、Maximumプロパティに到達します。The tick marks start at the value of the Minimum property and continue until the value of the Maximum property is reached.

依存プロパティ情報Dependency Property Information

識別子フィールドです。Identifier field TickFrequencyProperty
メタデータのプロパティを設定するには trueMetadata properties set to true なしNone

適用対象

こちらもご覧ください