コード例 #1
0
        public BinaryScaleLabelCreationStrategy(
			DoubleScale scale)
        {
            _scale = scale;
            _scale.ClipLabels = true;

            _lowerSectionLabel = CreateLabel();
            _higherSectionLabel = CreateLabel();

            UpdateSectionLabels();
        }
コード例 #2
0
 private double SetLabelPosition(VSectionLabel label, int labelTop)
 {
     var mappedTop = MapScalePoint(labelTop);
     var middleTop = mappedTop - label.ActualHeight / 2;
     label.Margin = new Thickness(0, middleTop, 0, 0);
     return middleTop;
 }
コード例 #3
0
 private VSectionLabel CreateLabel()
 {
     var label = new VSectionLabel(double.NaN, true);
     _scale.AddLabel(label);
     return label;
 }