Free cookie consent management tool by TermsFeed Policy Generator

Changeset 14796 for stable


Ignore:
Timestamp:
03/30/17 16:44:15 (8 years ago)
Author:
mkommend
Message:

#2663: Merged r14368, r14270, and r14371 to stable.

Location:
stable
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • stable

  • stable/HeuristicLab.DataPreprocessing.Views

  • stable/HeuristicLab.DataPreprocessing.Views/3.4

    • Property svn:ignore
      •  

        old new  
        11ComparisonFilterView.resx
        22FilterView.resx
         3*.user
  • stable/HeuristicLab.DataPreprocessing.Views/3.4/HistogramView.Designer.cs

    r14186 r14796  
    4949      this.label1 = new System.Windows.Forms.Label();
    5050      this.classifierComboBox = new System.Windows.Forms.ComboBox();
     51      ((System.ComponentModel.ISupportInitialize)(this.splitContainer)).BeginInit();
     52      this.splitContainer.Panel1.SuspendLayout();
     53      this.splitContainer.SuspendLayout();
    5154      this.optionsBox.SuspendLayout();
    5255      this.SuspendLayout();
    5356      //
     57      // splitContainer
     58      //
     59      //
     60      // splitContainer.Panel1
     61      //
     62      this.splitContainer.Panel1.Controls.Add(this.optionsBox);
     63      //
    5464      // optionsBox
    5565      //
    56       this.optionsBox.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
     66      this.optionsBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
     67            | System.Windows.Forms.AnchorStyles.Right)));
    5768      this.optionsBox.Controls.Add(this.displayDetailsCheckBox);
    5869      this.optionsBox.Controls.Add(this.label1);
    5970      this.optionsBox.Controls.Add(this.classifierComboBox);
    60       this.optionsBox.Location = new System.Drawing.Point(5, 324);
    61       this.optionsBox.Margin = new System.Windows.Forms.Padding(4);
     71      this.optionsBox.Location = new System.Drawing.Point(4, 262);
    6272      this.optionsBox.Name = "optionsBox";
    63       this.optionsBox.Padding = new System.Windows.Forms.Padding(4);
    64       this.optionsBox.Size = new System.Drawing.Size(203, 165);
     73      this.optionsBox.Size = new System.Drawing.Size(84, 138);
    6574      this.optionsBox.TabIndex = 7;
    6675      this.optionsBox.TabStop = false;
     
    7079      //
    7180      this.displayDetailsCheckBox.AutoSize = true;
    72       this.displayDetailsCheckBox.Location = new System.Drawing.Point(7, 71);
     81      this.displayDetailsCheckBox.Location = new System.Drawing.Point(5, 58);
     82      this.displayDetailsCheckBox.Margin = new System.Windows.Forms.Padding(2);
    7383      this.displayDetailsCheckBox.Name = "displayDetailsCheckBox";
    7484      this.displayDetailsCheckBox.RightToLeft = System.Windows.Forms.RightToLeft.Yes;
    75       this.displayDetailsCheckBox.Size = new System.Drawing.Size(153, 21);
     85      this.displayDetailsCheckBox.Size = new System.Drawing.Size(119, 17);
    7686      this.displayDetailsCheckBox.TabIndex = 3;
    7787      this.displayDetailsCheckBox.Text = "Display value count";
     
    8292      //
    8393      this.label1.AutoSize = true;
    84       this.label1.Location = new System.Drawing.Point(4, 19);
    85       this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
     94      this.label1.Location = new System.Drawing.Point(3, 15);
    8695      this.label1.Name = "label1";
    87       this.label1.Size = new System.Drawing.Size(108, 17);
     96      this.label1.Size = new System.Drawing.Size(81, 13);
    8897      this.label1.TabIndex = 2;
    8998      this.label1.Text = "Target variable:";
     
    91100      // classifierComboBox
    92101      //
     102      this.classifierComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
     103            | System.Windows.Forms.AnchorStyles.Right)));
    93104      this.classifierComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
    94105      this.classifierComboBox.FormattingEnabled = true;
    95       this.classifierComboBox.Location = new System.Drawing.Point(7, 40);
    96       this.classifierComboBox.Margin = new System.Windows.Forms.Padding(4);
     106      this.classifierComboBox.Location = new System.Drawing.Point(5, 32);
    97107      this.classifierComboBox.Name = "classifierComboBox";
    98       this.classifierComboBox.Size = new System.Drawing.Size(160, 24);
     108      this.classifierComboBox.Size = new System.Drawing.Size(73, 21);
    99109      this.classifierComboBox.TabIndex = 1;
    100110      this.classifierComboBox.SelectedIndexChanged += new System.EventHandler(this.classifierComboBox_SelectedIndexChanged);
     
    102112      // HistogramView
    103113      //
    104       this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
     114      this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
    105115      this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
    106       this.Controls.Add(this.optionsBox);
    107       this.Margin = new System.Windows.Forms.Padding(5);
     116      this.Margin = new System.Windows.Forms.Padding(4);
    108117      this.Name = "HistogramView";
    109       this.Controls.SetChildIndex(this.optionsBox, 0);
     118      this.splitContainer.Panel1.ResumeLayout(false);
     119      ((System.ComponentModel.ISupportInitialize)(this.splitContainer)).EndInit();
     120      this.splitContainer.ResumeLayout(false);
    110121      this.optionsBox.ResumeLayout(false);
    111122      this.optionsBox.PerformLayout();
  • stable/HeuristicLab.DataPreprocessing.Views/3.4/LineChartView.Designer.cs

    r14186 r14796  
    4747      this.optionsBox = new System.Windows.Forms.GroupBox();
    4848      this.allInOneCheckBox = new System.Windows.Forms.CheckBox();
     49      ((System.ComponentModel.ISupportInitialize)(this.splitContainer)).BeginInit();
     50      this.splitContainer.Panel1.SuspendLayout();
     51      this.splitContainer.SuspendLayout();
    4952      this.optionsBox.SuspendLayout();
    5053      this.SuspendLayout();
    5154      //
     55      // splitContainer
     56      //
     57      //
     58      // splitContainer.Panel1
     59      //
     60      this.splitContainer.Panel1.Controls.Add(this.optionsBox);
     61      //
    5262      // optionsBox
    5363      //
    54       this.optionsBox.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
     64      this.optionsBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
     65            | System.Windows.Forms.AnchorStyles.Right)));
    5566      this.optionsBox.Controls.Add(this.allInOneCheckBox);
    5667      this.optionsBox.Location = new System.Drawing.Point(4, 262);
    5768      this.optionsBox.Name = "optionsBox";
    58       this.optionsBox.Size = new System.Drawing.Size(151, 134);
     69      this.optionsBox.Size = new System.Drawing.Size(84, 138);
    5970      this.optionsBox.TabIndex = 7;
    6071      this.optionsBox.TabStop = false;
     
    7889      this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
    7990      this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
    80       this.Controls.Add(this.optionsBox);
    8191      this.Name = "LineChartView";
    82       this.Controls.SetChildIndex(this.optionsBox, 0);
     92      this.splitContainer.Panel1.ResumeLayout(false);
     93      ((System.ComponentModel.ISupportInitialize)(this.splitContainer)).EndInit();
     94      this.splitContainer.ResumeLayout(false);
    8395      this.optionsBox.ResumeLayout(false);
    8496      this.optionsBox.PerformLayout();
  • stable/HeuristicLab.DataPreprocessing.Views/3.4/PreprocessingChartView.Designer.cs

    r14186 r14796  
    4545    /// </summary>
    4646    private void InitializeComponent() {
    47       this.dataTableView = new DataPreprocessing.Views.PreprocessingDataTableView();
    4847      this.tableLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
     48      this.dataTableView = new HeuristicLab.DataPreprocessing.Views.PreprocessingDataTableView();
     49      this.splitContainer = new System.Windows.Forms.SplitContainer();
    4950      this.checkedItemList = new HeuristicLab.DataPreprocessing.Views.PreprocessingCheckedItemListView();
    5051      this.tableLayoutPanel.SuspendLayout();
     52      ((System.ComponentModel.ISupportInitialize)(this.splitContainer)).BeginInit();
     53      this.splitContainer.Panel1.SuspendLayout();
     54      this.splitContainer.Panel2.SuspendLayout();
     55      this.splitContainer.SuspendLayout();
    5156      this.SuspendLayout();
     57      //
     58      // tableLayoutPanel
     59      //
     60      this.tableLayoutPanel.ColumnCount = 1;
     61      this.tableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
     62      this.tableLayoutPanel.Controls.Add(this.dataTableView, 0, 0);
     63      this.tableLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
     64      this.tableLayoutPanel.Location = new System.Drawing.Point(0, 0);
     65      this.tableLayoutPanel.Name = "tableLayoutPanel";
     66      this.tableLayoutPanel.RowCount = 1;
     67      this.tableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle());
     68      this.tableLayoutPanel.Size = new System.Drawing.Size(559, 403);
     69      this.tableLayoutPanel.TabIndex = 6;
     70      this.tableLayoutPanel.Layout += new System.Windows.Forms.LayoutEventHandler(this.tableLayoutPanel_Layout);
    5271      //
    5372      // dataTableView
    5473      //
     74      this.dataTableView.AutoScroll = true;
    5575      this.dataTableView.Caption = "DataTable View";
     76      this.dataTableView.Classification = null;
    5677      this.dataTableView.Content = null;
    5778      this.dataTableView.Dock = System.Windows.Forms.DockStyle.Fill;
     79      this.dataTableView.IsDetailedChartViewEnabled = false;
    5880      this.dataTableView.Location = new System.Drawing.Point(3, 3);
    5981      this.dataTableView.Name = "dataTableView";
    6082      this.dataTableView.ReadOnly = false;
    61       this.dataTableView.Size = new System.Drawing.Size(486, 390);
     83      this.dataTableView.Size = new System.Drawing.Size(553, 397);
    6284      this.dataTableView.TabIndex = 0;
    6385      //
    64       // tableLayoutPanel
     86      // splitContainer
    6587      //
    66       this.tableLayoutPanel.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
    67             | System.Windows.Forms.AnchorStyles.Left)
    68             | System.Windows.Forms.AnchorStyles.Right)));
    69       this.tableLayoutPanel.AutoScroll = true;
    70       this.tableLayoutPanel.ColumnCount = 1;
    71       this.tableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
    72       this.tableLayoutPanel.Controls.Add(this.dataTableView, 0, 0);
    73       this.tableLayoutPanel.Location = new System.Drawing.Point(162, 4);
    74       this.tableLayoutPanel.Name = "tableLayoutPanel";
    75       this.tableLayoutPanel.RowCount = 1;
    76       this.tableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle());
    77       this.tableLayoutPanel.Size = new System.Drawing.Size(492, 396);
    78       this.tableLayoutPanel.TabIndex = 6;
    79       this.tableLayoutPanel.Layout += new System.Windows.Forms.LayoutEventHandler(this.tableLayoutPanel_Layout);
     88      this.splitContainer.Dock = System.Windows.Forms.DockStyle.Fill;
     89      this.splitContainer.Location = new System.Drawing.Point(0, 0);
     90      this.splitContainer.Name = "splitContainer";
     91      //
     92      // splitContainer.Panel1
     93      //
     94      this.splitContainer.Panel1.Controls.Add(this.checkedItemList);
     95      //
     96      // splitContainer.Panel2
     97      //
     98      this.splitContainer.Panel2.Controls.Add(this.tableLayoutPanel);
     99      this.splitContainer.Size = new System.Drawing.Size(654, 403);
     100      this.splitContainer.SplitterDistance = 91;
     101      this.splitContainer.TabIndex = 7;
    80102      //
    81103      // checkedItemList
    82104      //
    83       this.checkedItemList.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
    84             | System.Windows.Forms.AnchorStyles.Left)));
     105      this.checkedItemList.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
     106            | System.Windows.Forms.AnchorStyles.Left)
     107            | System.Windows.Forms.AnchorStyles.Right)));
    85108      this.checkedItemList.Caption = "View";
    86109      this.checkedItemList.Content = null;
     
    88111      this.checkedItemList.Name = "checkedItemList";
    89112      this.checkedItemList.ReadOnly = false;
    90       this.checkedItemList.Size = new System.Drawing.Size(152, 252);
     113      this.checkedItemList.Size = new System.Drawing.Size(84, 252);
    91114      this.checkedItemList.TabIndex = 4;
    92115      //
     
    95118      this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
    96119      this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
    97       this.Controls.Add(this.tableLayoutPanel);
    98       this.Controls.Add(this.checkedItemList);
     120      this.Controls.Add(this.splitContainer);
    99121      this.Name = "PreprocessingChartView";
    100122      this.Size = new System.Drawing.Size(654, 403);
    101123      this.tableLayoutPanel.ResumeLayout(false);
     124      this.splitContainer.Panel1.ResumeLayout(false);
     125      this.splitContainer.Panel2.ResumeLayout(false);
     126      ((System.ComponentModel.ISupportInitialize)(this.splitContainer)).EndInit();
     127      this.splitContainer.ResumeLayout(false);
    102128      this.ResumeLayout(false);
    103129
     
    109135    private DataPreprocessing.Views.PreprocessingDataTableView dataTableView;
    110136    private System.Windows.Forms.TableLayoutPanel tableLayoutPanel;
     137    protected System.Windows.Forms.SplitContainer splitContainer;
    111138  }
    112139}
  • stable/HeuristicLab.DataPreprocessing.Views/3.4/PreprocessingChartView.cs

    r14186 r14796  
    5959    //Add or remove data row
    6060    private void CheckedItemsChanged(object sender, CollectionItemsChangedEventArgs<IndexedItem<StringValue>> checkedItems) {
    61 
     61      tableLayoutPanel.SuspendLayout();
    6262      foreach (IndexedItem<StringValue> item in checkedItems.Items) {
    6363        string variableName = item.Value.Value;
    6464
    65         //variable is displayed -> remove
    66         if (VariableIsDisplayed(variableName)) {
    67           dataTable.Rows.Remove(variableName);
     65        // not checked -> remove
     66        if (!VariableIsChecked(variableName)) {
     67          dataTableView.SetRowEnabled(variableName, false);
    6868          dataTable.SelectedRows.Remove(variableName);
    6969          dataTablePerVariable.Remove(dataTablePerVariable.Find(x => (x.Name == variableName)));
    70           //variable isnt't displayed -> add
    7170        } else {
    7271          DataRow row = GetDataRow(variableName);
    7372          DataRow selectedRow = GetSelectedDataRow(variableName);
    74           dataTable.Rows.Add(row);
     73          dataTableView.SetRowEnabled(variableName, true);
    7574
    7675          PreprocessingDataTable pdt = new PreprocessingDataTable(variableName);
    7776          pdt.Rows.Add(row);
    78           dataTablePerVariable.Add(pdt);
     77          // dataTablePerVariable does not contain unchecked variables => reduce insert position by number of unchecked variables to correct the index
     78          int uncheckedUntilVariable = checkedItemList.Content.TakeWhile(x => x.Value != variableName).Count(x => !checkedItemList.Content.ItemChecked(x));
     79          dataTablePerVariable.Insert(item.Index - uncheckedUntilVariable, pdt);
    7980
    8081          //update selection
     
    8990      if (Content != null && !Content.AllInOneMode)
    9091        GenerateChart();
    91 
    92     }
    93 
    94     private bool VariableIsDisplayed(string name) {
    95 
    96       foreach (var item in dataTable.Rows) {
    97         if (item.Name == name)
    98           return true;
    99       }
    100       return false;
     92      tableLayoutPanel.ResumeLayout(true);
     93    }
     94
     95    private bool VariableIsChecked(string name) {
     96      return Content.VariableItemList.CheckedItems.Any(x => x.Value.Value == name);
    10197    }
    10298
     
    158154      dataTable.SelectedRows.Clear();
    159155      foreach (var selectedRow in selectedDataRows) {
    160         if (VariableIsDisplayed(selectedRow.Name))
     156        if (VariableIsChecked(selectedRow.Name))
    161157          dataTable.SelectedRows.Add(selectedRow);
    162158      }
  • stable/HeuristicLab.DataPreprocessing.Views/3.4/PreprocessingDataTableView.cs

    r14186 r14796  
    139139        }
    140140      } else MessageBox.Show("Nothing to configure.");
     141    }
     142
     143    public bool IsRowEnabled(string name) {
     144      return chart.Series.FindByName(name) != null && chart.Series[name].Enabled;
     145    }
     146    public void SetRowEnabled(string name, bool enabled) {
     147      if (chart.Series.FindByName(name) != null)
     148        chart.Series[name].Enabled = enabled;
    141149    }
    142150
Note: See TracChangeset for help on using the changeset viewer.