Beispiel #1
0
 /// <summary>
 /// Initializes new instance of <see cref="PlotBase"/> class
 /// </summary>
 protected PlotBase()
 {
     XDataTransform = new IdentityDataTransform();
     YDataTransform = new IdentityDataTransform();
     masterField    = this;
     Loaded        += PlotBaseLoaded;
     Unloaded      += PlotBaseUnloaded;
 }
Beispiel #2
0
 /// <summary>
 /// Initializes new instance of <see cref="PlotAxis"/> class
 /// </summary>
 public PlotAxis()
 {
     XDataTransform  = new IdentityDataTransform();
     YDataTransform  = new IdentityDataTransform();
     Ticks           = new double[0];
     DefaultStyleKey = typeof(PlotAxis);
     Loaded         += PlotAxisLoaded;
     Unloaded       += PlotAxisUnloaded;
 }
Beispiel #3
0
        public Axis()
        {
            DataTransform = new IdentityDataTransform();
            Ticks         = new double[0];

            majorTicksPath = new Path();
            minorTicksPath = new Path();
            Children.Add(majorTicksPath);
            Children.Add(minorTicksPath);

            BindingOperations.SetBinding(majorTicksPath, Path.StrokeProperty, new Binding("Foreground")
            {
                Source = this, Mode = BindingMode.TwoWay
            });
            BindingOperations.SetBinding(minorTicksPath, Path.StrokeProperty, new Binding("Foreground")
            {
                Source = this, Mode = BindingMode.TwoWay
            });

            if (ticksProvider == null)
            {
                this.ticksProvider = new TicksProvider();
            }
        }