Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
06/27/17 10:06:34 (7 years ago)
Author:
pfleck
Message:

#2715 Moved the histogram properties (nr of bins, exact/approximate bins, aggregation) from DataRowVisualProperties to DataTableVisualProperties

  • Adapted DataRow/TableVisualPropertiesControl
  • Backwards compatability is handled in the DataTable (DataTableVisualProperties has no access to the DataRowVisualProperties)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Analysis/3.3/DataVisualization/DataRowVisualProperties.cs

    r14582 r15068  
    5252    }
    5353    #endregion
    54     #region Histogram Aggregation
    55     public enum DataRowHistogramAggregation {
    56       Overlapping,
    57       SideBySide,
    58       Stacked
    59     }
    60     #endregion
    6154
    6255    private DataRowChartType chartType;
     
    130123      }
    131124    }
    132     private int bins;
    133     public int Bins {
    134       get { return bins; }
    135       set {
    136         if (bins != value) {
    137           bins = value;
    138           OnPropertyChanged("Bins");
    139         }
    140       }
    141     }
    142     private bool exactBins;
    143     public bool ExactBins {
    144       get { return exactBins; }
    145       set {
    146         if (exactBins != value) {
    147           exactBins = value;
    148           OnPropertyChanged("ExactBins");
    149         }
    150       }
    151     }
    152     private DataRowHistogramAggregation aggregation;
    153     public DataRowHistogramAggregation Aggregation {
    154       get { return aggregation; }
    155       set {
    156         if (aggregation != value) {
    157           aggregation = value;
    158           OnPropertyChanged("Aggregation");
    159         }
    160       }
    161     }
     125
    162126    private double scaleFactor;
    163127    public double ScaleFactor {
     
    232196      set { lineWidth = value; }
    233197    }
    234     [Storable(Name = "Bins")]
    235     private int StorableBins {
    236       get { return bins; }
    237       set { bins = value; }
    238     }
    239     [Storable(Name = "ExactBins")]
    240     private bool StorableExactBins {
    241       get { return exactBins; }
    242       set { exactBins = value; }
    243     }
    244     [Storable(Name = "Aggregation", DefaultValue = DataRowHistogramAggregation.Overlapping)]
    245     private DataRowHistogramAggregation StorableAggregation {
    246       get { return aggregation; }
    247       set { aggregation = value; }
    248     }
    249198    [Storable(Name = "ScaleFactor")]
    250199    private double StorableScaleFactor {
     
    262211      set { displayName = value; }
    263212    }
     213    #endregion
     214
     215    #region Histogram Properties - Backwards Compatability
     216    internal enum DataRowHistogramAggregation {
     217      Overlapping,
     218      SideBySide,
     219      Stacked
     220    }
     221
     222    internal int? Bins { get; private set; }
     223    internal bool? ExactBins { get; private set; }
     224    internal DataRowHistogramAggregation? Aggregation { get; private set; }
     225
     226    [Storable(Name = "Bins", AllowOneWay = true)]
     227    private int StorableBins { set { Bins = value; } }
     228    [Storable(Name = "ExactBins", AllowOneWay = true)]
     229    private bool StorableExactBins { set { ExactBins = value; } }
     230    [Storable(Name = "Aggregation", AllowOneWay = true)]
     231    private DataRowHistogramAggregation StorableAggregation { set { Aggregation = value; } }
    264232    #endregion
    265233
     
    275243      this.startIndexZero = original.startIndexZero;
    276244      this.lineWidth = original.lineWidth;
    277       this.bins = original.bins;
    278       this.exactBins = original.exactBins;
    279       this.aggregation = original.aggregation;
    280245      this.scaleFactor = original.scaleFactor;
    281246      this.displayName = original.displayName;
     
    290255      startIndexZero = false;
    291256      lineWidth = 1;
    292       bins = 10;
    293       exactBins = false;
    294       aggregation = DataRowHistogramAggregation.Overlapping;
    295257      scaleFactor = 1.0;
    296258      displayName = String.Empty;
     
    318280      if (secondXAxis == default(bool)
    319281        && lineStyle == default(DataRowLineStyle)
    320         && lineWidth == default(int) && bins == default(int) && exactBins == default(bool)
    321282        && displayName == default(string)) {
    322283        secondXAxis = false;
    323284        lineStyle = DataRowLineStyle.Solid;
    324285        lineWidth = 1;
    325         bins = 10;
    326         exactBins = false;
    327286        displayName = String.Empty;
    328287      }
Note: See TracChangeset for help on using the changeset viewer.