예제 #1
0
        private static void OnPointChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            PivotSegmentEditor owner = (PivotSegmentEditor)d;

            owner.CoerceValue(LeftYProperty);
            owner.CoerceValue(RightYProperty);
            owner.OnPointChanged();
        }
예제 #2
0
        private static object OnRightYCoerce(DependencyObject source, object value)
        {
            PivotSegmentEditor editor = (PivotSegmentEditor)source;

            if (editor.plotter == null)
            {
                return(value);
            }

            Func <double, double> func = editor.GetLineFunc();
            double xmax   = editor.plotter.Viewport.Visible.XMax;
            double result = func(xmax);

            return(result);
        }