Changeset 9835 for branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews
- Timestamp:
- 08/01/13 13:01:40 (11 years ago)
- Location:
- branches/HeuristicLab.EvolutionaryTracking
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.EvolutionaryTracking
- Property svn:ignore
-
old new 1 *.suo 2 _ReSharper.HeuristicLab.Tracking 1 _ReSharper.Sliding Window GP 3 2 bin
-
- Property svn:mergeinfo changed
/branches/Sliding Window GP (added) merged: 7820,7837,7845,7850,9047,9126,9145,9162-9165 -
Property
svn:global-ignores
set to
_ReSharper.HeuristicLab.Tracking
- Property svn:ignore
-
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Optimization.Views merged: 9435,9438,9441,9447-9448,9456,9462,9474,9476-9477,9506,9613
- Property svn:mergeinfo changed
-
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews/RunCollectionBoxPlotView.Designer.cs
r7967 r9835 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2013 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 61 61 this.tooltip = new System.Windows.Forms.ToolTip(this.components); 62 62 ((System.ComponentModel.ISupportInitialize)(this.chart)).BeginInit(); 63 ((System.ComponentModel.ISupportInitialize)(this.splitContainer)).BeginInit(); 63 64 this.splitContainer.Panel1.SuspendLayout(); 64 65 this.splitContainer.Panel2.SuspendLayout(); … … 71 72 this.xAxisLabel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 72 73 this.xAxisLabel.AutoSize = true; 73 this.xAxisLabel.Location = new System.Drawing.Point( 298, 256);74 this.xAxisLabel.Location = new System.Drawing.Point(363, 345); 74 75 this.xAxisLabel.Name = "xAxisLabel"; 75 76 this.xAxisLabel.Size = new System.Drawing.Size(15, 13); … … 83 84 this.xAxisComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 84 85 this.xAxisComboBox.FormattingEnabled = true; 85 this.xAxisComboBox.Location = new System.Drawing.Point(3 19, 253);86 this.xAxisComboBox.Location = new System.Drawing.Point(384, 342); 86 87 this.xAxisComboBox.Name = "xAxisComboBox"; 87 this.xAxisComboBox.Size = new System.Drawing.Size( 221, 21);88 this.xAxisComboBox.Size = new System.Drawing.Size(600, 21); 88 89 this.xAxisComboBox.TabIndex = 11; 89 90 this.xAxisComboBox.SelectedIndexChanged += new System.EventHandler(this.AxisComboBox_SelectedIndexChanged); … … 105 106 this.yAxisComboBox.Location = new System.Drawing.Point(24, 3); 106 107 this.yAxisComboBox.Name = "yAxisComboBox"; 107 this.yAxisComboBox.Size = new System.Drawing.Size( 221, 21);108 this.yAxisComboBox.Size = new System.Drawing.Size(600, 21); 108 109 this.yAxisComboBox.TabIndex = 9; 109 110 this.yAxisComboBox.SelectedIndexChanged += new System.EventHandler(this.AxisComboBox_SelectedIndexChanged); … … 111 112 // chart 112 113 // 113 this.chart.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 114 | System.Windows.Forms.AnchorStyles.Left)115 114 this.chart.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 115 | System.Windows.Forms.AnchorStyles.Left) 116 | System.Windows.Forms.AnchorStyles.Right))); 116 117 chartArea1.Name = "ChartArea1"; 117 118 this.chart.ChartAreas.Add(chartArea1); 118 this.chart.Location = new System.Drawing.Point( 6, 30);119 this.chart.Location = new System.Drawing.Point(-1, 30); 119 120 this.chart.Name = "chart"; 120 121 series1.ChartArea = "ChartArea1"; … … 125 126 series1.YValuesPerPoint = 6; 126 127 this.chart.Series.Add(series1); 127 this.chart.Size = new System.Drawing.Size( 534, 217);128 this.chart.Size = new System.Drawing.Size(989, 306); 128 129 this.chart.TabIndex = 17; 129 130 this.chart.Text = "chart"; … … 135 136 this.noRunsLabel.Anchor = System.Windows.Forms.AnchorStyles.None; 136 137 this.noRunsLabel.AutoSize = true; 137 this.noRunsLabel.Location = new System.Drawing.Point( 212, 122);138 this.noRunsLabel.Location = new System.Drawing.Point(434, 167); 138 139 this.noRunsLabel.Name = "noRunsLabel"; 139 140 this.noRunsLabel.Size = new System.Drawing.Size(138, 13); … … 161 162 // 162 163 this.splitContainer.Panel2.Controls.Add(this.statisticsGroupBox); 163 this.splitContainer.Size = new System.Drawing.Size( 543, 416);164 this.splitContainer.SplitterDistance = 277;164 this.splitContainer.Size = new System.Drawing.Size(987, 550); 165 this.splitContainer.SplitterDistance = 366; 165 166 this.splitContainer.TabIndex = 23; 166 167 // … … 172 173 this.showStatisticsCheckBox.CheckState = System.Windows.Forms.CheckState.Checked; 173 174 this.showStatisticsCheckBox.Image = HeuristicLab.Common.Resources.VSImageLibrary.Properties; 174 this.showStatisticsCheckBox.Location = new System.Drawing.Point( 6, 245);175 this.showStatisticsCheckBox.Location = new System.Drawing.Point(3, 339); 175 176 this.showStatisticsCheckBox.Name = "showStatisticsCheckBox"; 176 177 this.showStatisticsCheckBox.Size = new System.Drawing.Size(24, 24); … … 182 183 // statisticsGroupBox 183 184 // 184 this.statisticsGroupBox.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 185 | System.Windows.Forms.AnchorStyles.Left)186 185 this.statisticsGroupBox.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 186 | System.Windows.Forms.AnchorStyles.Left) 187 | System.Windows.Forms.AnchorStyles.Right))); 187 188 this.statisticsGroupBox.Controls.Add(this.statisticsMatrixView); 188 189 this.statisticsGroupBox.Location = new System.Drawing.Point(3, 3); 189 190 this.statisticsGroupBox.Name = "statisticsGroupBox"; 190 this.statisticsGroupBox.Size = new System.Drawing.Size( 534, 129);191 this.statisticsGroupBox.Size = new System.Drawing.Size(981, 174); 191 192 this.statisticsGroupBox.TabIndex = 1; 192 193 this.statisticsGroupBox.TabStop = false; … … 203 204 this.statisticsMatrixView.ShowRowsAndColumnsTextBox = false; 204 205 this.statisticsMatrixView.ShowStatisticalInformation = false; 205 this.statisticsMatrixView.Size = new System.Drawing.Size( 528, 110);206 this.statisticsMatrixView.Size = new System.Drawing.Size(975, 155); 206 207 this.statisticsMatrixView.TabIndex = 0; 207 208 // 208 209 // RunCollectionBoxPlotView 209 210 // 210 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);211 211 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Inherit; 212 212 this.BackColor = System.Drawing.SystemColors.Window; … … 214 214 this.Controls.Add(this.splitContainer); 215 215 this.Name = "RunCollectionBoxPlotView"; 216 this.Size = new System.Drawing.Size( 543, 416);216 this.Size = new System.Drawing.Size(987, 550); 217 217 ((System.ComponentModel.ISupportInitialize)(this.chart)).EndInit(); 218 218 this.splitContainer.Panel1.ResumeLayout(false); 219 219 this.splitContainer.Panel1.PerformLayout(); 220 220 this.splitContainer.Panel2.ResumeLayout(false); 221 ((System.ComponentModel.ISupportInitialize)(this.splitContainer)).EndInit(); 221 222 this.splitContainer.ResumeLayout(false); 222 223 this.statisticsGroupBox.ResumeLayout(false); -
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews/RunCollectionBoxPlotView.cs
r9421 r9835 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2013 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 328 328 if (!this.categoricalMapping.ContainsKey(dimension)) { 329 329 this.categoricalMapping[dimension] = new Dictionary<object, double>(); 330 var orderedCategories = Content.Where(r=> r.Visible).Select(r => Content.GetValue(r, dimension).ToString()) 331 .Distinct() 332 .OrderBy(x => x, new NaturalStringComparer()); 330 var orderedCategories = Content.Where(r => r.Visible && Content.GetValue(r, dimension) != null).Select(r => Content.GetValue(r, dimension).ToString()) 331 .Distinct().OrderBy(x => x, new NaturalStringComparer()); 333 332 int count = 1; 334 333 foreach (var category in orderedCategories) { … … 389 388 axis.CustomLabels.Clear(); 390 389 if (categoricalMapping.ContainsKey(dimension)) { 391 foreach (var pair in categoricalMapping[dimension]) { 390 int position = 1; 391 foreach (var pair in categoricalMapping[dimension].Where(x => seriesCache.ContainsKey(x.Value))) { 392 392 string labelText = pair.Key.ToString(); 393 393 CustomLabel label = new CustomLabel(); … … 397 397 label.Text = labelText; 398 398 label.GridTicks = GridTickTypes.TickMark; 399 label.FromPosition = p air.Value- 0.5;400 label.ToPosition = p air.Value+ 0.5;399 label.FromPosition = position - 0.5; 400 label.ToPosition = position + 0.5; 401 401 axis.CustomLabels.Add(label); 402 position++; 402 403 } 403 404 } else if (dimension > 0 && Content.GetValue(0, dimension) is TimeSpanValue) { -
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews/RunCollectionBubbleChartView.Designer.cs
r9421 r9835 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2013 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 61 61 this.chart = new HeuristicLab.Visualization.ChartControlsExtensions.EnhancedChart(); 62 62 this.openBoxPlotViewToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 63 this.hideRun ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();63 this.hideRunsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 64 64 this.zoomButton = new System.Windows.Forms.RadioButton(); 65 65 this.selectButton = new System.Windows.Forms.RadioButton(); 66 66 this.radioButtonGroup = new System.Windows.Forms.GroupBox(); 67 this.color DialogButton = new System.Windows.Forms.Button();67 this.colorRunsButton = new System.Windows.Forms.Button(); 68 68 this.colorDialog = new System.Windows.Forms.ColorDialog(); 69 69 this.tooltip = new System.Windows.Forms.ToolTip(this.components); 70 70 this.colorXAxisButton = new System.Windows.Forms.Button(); 71 71 this.colorYAxisButton = new System.Windows.Forms.Button(); 72 this.transparencyTrackBar = new System.Windows.Forms.TrackBar(); 73 this.hideRunsButton = new System.Windows.Forms.Button(); 74 this.colorDialogButton = new System.Windows.Forms.Button(); 72 75 this.noRunsLabel = new System.Windows.Forms.Label(); 73 76 this.sizeTrackBar = new System.Windows.Forms.TrackBar(); 74 77 this.getDataAsMatrixToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 75 this.transparencyTrackBar = new System.Windows.Forms.TrackBar();76 78 this.transparencyLabel = new System.Windows.Forms.Label(); 77 this. colorRunsButton = new System.Windows.Forms.Button();78 this. hideRunsButton = new System.Windows.Forms.Button();79 this.unhideAllRunToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 80 this.colorResetToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 79 81 ((System.ComponentModel.ISupportInitialize)(this.xTrackBar)).BeginInit(); 80 82 ((System.ComponentModel.ISupportInitialize)(this.yTrackBar)).BeginInit(); 81 83 ((System.ComponentModel.ISupportInitialize)(this.chart)).BeginInit(); 82 84 this.radioButtonGroup.SuspendLayout(); 85 ((System.ComponentModel.ISupportInitialize)(this.transparencyTrackBar)).BeginInit(); 83 86 ((System.ComponentModel.ISupportInitialize)(this.sizeTrackBar)).BeginInit(); 84 ((System.ComponentModel.ISupportInitialize)(this.transparencyTrackBar)).BeginInit();85 87 this.SuspendLayout(); 86 88 // … … 88 90 // 89 91 this.yJitterLabel.AutoSize = true; 90 this.yJitterLabel.Location = new System.Drawing.Point( 278, 6);92 this.yJitterLabel.Location = new System.Drawing.Point(457, 6); 91 93 this.yJitterLabel.Name = "yJitterLabel"; 92 94 this.yJitterLabel.Size = new System.Drawing.Size(32, 13); … … 98 100 this.xJitterlabel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 99 101 this.xJitterlabel.AutoSize = true; 100 this.xJitterlabel.Location = new System.Drawing.Point( 749, 472);102 this.xJitterlabel.Location = new System.Drawing.Point(893, 719); 101 103 this.xJitterlabel.Name = "xJitterlabel"; 102 104 this.xJitterlabel.Size = new System.Drawing.Size(32, 13); … … 108 110 this.xTrackBar.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 109 111 this.xTrackBar.Enabled = false; 110 this.xTrackBar.Location = new System.Drawing.Point( 787, 469);112 this.xTrackBar.Location = new System.Drawing.Point(919, 715); 111 113 this.xTrackBar.Maximum = 100; 112 114 this.xTrackBar.Name = "xTrackBar"; … … 120 122 this.xAxisLabel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 121 123 this.xAxisLabel.AutoSize = true; 122 this.xAxisLabel.Location = new System.Drawing.Point(4 71, 472);124 this.xAxisLabel.Location = new System.Drawing.Point(439, 719); 123 125 this.xAxisLabel.Name = "xAxisLabel"; 124 126 this.xAxisLabel.Size = new System.Drawing.Size(15, 13); … … 131 133 this.xAxisComboBox.BackColor = System.Drawing.SystemColors.ControlLightLight; 132 134 this.xAxisComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 135 this.xAxisComboBox.DropDownWidth = 500; 133 136 this.xAxisComboBox.FormattingEnabled = true; 134 this.xAxisComboBox.Location = new System.Drawing.Point(4 92, 469);137 this.xAxisComboBox.Location = new System.Drawing.Point(460, 715); 135 138 this.xAxisComboBox.Name = "xAxisComboBox"; 136 this.xAxisComboBox.Size = new System.Drawing.Size( 221, 21);139 this.xAxisComboBox.Size = new System.Drawing.Size(400, 21); 137 140 this.xAxisComboBox.TabIndex = 7; 138 141 this.xAxisComboBox.SelectedValueChanged += new System.EventHandler(this.AxisComboBox_SelectedValueChanged); … … 151 154 this.yAxisComboBox.BackColor = System.Drawing.SystemColors.ControlLightLight; 152 155 this.yAxisComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 156 this.yAxisComboBox.DropDownWidth = 800; 153 157 this.yAxisComboBox.FormattingEnabled = true; 154 158 this.yAxisComboBox.Location = new System.Drawing.Point(24, 3); 155 159 this.yAxisComboBox.Name = "yAxisComboBox"; 156 this.yAxisComboBox.Size = new System.Drawing.Size( 221, 21);160 this.yAxisComboBox.Size = new System.Drawing.Size(400, 21); 157 161 this.yAxisComboBox.TabIndex = 5; 158 162 this.yAxisComboBox.SelectedValueChanged += new System.EventHandler(this.AxisComboBox_SelectedValueChanged); … … 161 165 // 162 166 this.yTrackBar.Enabled = false; 163 this.yTrackBar.Location = new System.Drawing.Point( 312, 3);167 this.yTrackBar.Location = new System.Drawing.Point(483, 3); 164 168 this.yTrackBar.Maximum = 100; 165 169 this.yTrackBar.Name = "yTrackBar"; … … 174 178 this.sizeComboBox.BackColor = System.Drawing.SystemColors.ControlLightLight; 175 179 this.sizeComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 180 this.sizeComboBox.DropDownWidth = 400; 176 181 this.sizeComboBox.FormattingEnabled = true; 177 this.sizeComboBox.Location = new System.Drawing.Point( 560, 4);182 this.sizeComboBox.Location = new System.Drawing.Point(613, 3); 178 183 this.sizeComboBox.Name = "sizeComboBox"; 179 this.sizeComboBox.Size = new System.Drawing.Size( 221, 21);184 this.sizeComboBox.Size = new System.Drawing.Size(300, 21); 180 185 this.sizeComboBox.TabIndex = 14; 181 186 this.sizeComboBox.SelectedValueChanged += new System.EventHandler(this.AxisComboBox_SelectedValueChanged); … … 185 190 this.sizeLabel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 186 191 this.sizeLabel.AutoSize = true; 187 this.sizeLabel.Location = new System.Drawing.Point( 489, 7);192 this.sizeLabel.Location = new System.Drawing.Point(541, 6); 188 193 this.sizeLabel.Name = "sizeLabel"; 189 194 this.sizeLabel.Size = new System.Drawing.Size(66, 13); … … 193 198 // chart 194 199 // 195 this.chart.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 196 | System.Windows.Forms.AnchorStyles.Left) 200 this.chart.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 201 | System.Windows.Forms.AnchorStyles.Left) 197 202 | System.Windows.Forms.AnchorStyles.Right))); 198 203 chartArea1.Name = "ChartArea1"; 199 204 this.chart.ChartAreas.Add(chartArea1); 200 this.chart.Location = new System.Drawing.Point( 6, 30);205 this.chart.Location = new System.Drawing.Point(-1, 30); 201 206 this.chart.Name = "chart"; 202 207 series1.ChartArea = "ChartArea1"; … … 207 212 series1.YValuesPerPoint = 2; 208 213 this.chart.Series.Add(series1); 209 this.chart.Size = new System.Drawing.Size( 843, 425);214 this.chart.Size = new System.Drawing.Size(988, 681); 210 215 this.chart.TabIndex = 16; 211 216 this.chart.Text = "chart"; … … 222 227 this.openBoxPlotViewToolStripMenuItem.Click += new System.EventHandler(this.openBoxPlotViewToolStripMenuItem_Click); 223 228 // 224 // hideRun ToolStripMenuItem225 // 226 this.hideRun ToolStripMenuItem.Name = "hideRunToolStripMenuItem";227 this.hideRun ToolStripMenuItem.Size = new System.Drawing.Size(256, 22);228 this.hideRun ToolStripMenuItem.Text = "Hide Run";229 this.hideRun ToolStripMenuItem.Click += new System.EventHandler(this.hideRunToolStripMenuItem_Click);229 // hideRunsToolStripMenuItem 230 // 231 this.hideRunsToolStripMenuItem.Name = "hideRunsToolStripMenuItem"; 232 this.hideRunsToolStripMenuItem.Size = new System.Drawing.Size(256, 22); 233 this.hideRunsToolStripMenuItem.Text = "Hide selected Runs"; 234 this.hideRunsToolStripMenuItem.Click += new System.EventHandler(this.hideRunsToolStripMenuItem_Click); 230 235 // 231 236 // zoomButton … … 234 239 this.zoomButton.AutoSize = true; 235 240 this.zoomButton.Checked = true; 236 this.zoomButton.Location = new System.Drawing.Point(6, 1 0);241 this.zoomButton.Location = new System.Drawing.Point(6, 11); 237 242 this.zoomButton.Name = "zoomButton"; 238 243 this.zoomButton.Size = new System.Drawing.Size(52, 17); … … 247 252 this.selectButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 248 253 this.selectButton.AutoSize = true; 249 this.selectButton.Location = new System.Drawing.Point(6 4, 9);254 this.selectButton.Location = new System.Drawing.Point(61, 11); 250 255 this.selectButton.Name = "selectButton"; 251 256 this.selectButton.Size = new System.Drawing.Size(55, 17); … … 259 264 this.radioButtonGroup.Controls.Add(this.zoomButton); 260 265 this.radioButtonGroup.Controls.Add(this.selectButton); 261 this.radioButtonGroup.Location = new System.Drawing.Point( 2, 461);266 this.radioButtonGroup.Location = new System.Drawing.Point(3, 704); 262 267 this.radioButtonGroup.Name = "radioButtonGroup"; 263 268 this.radioButtonGroup.Size = new System.Drawing.Size(122, 32); … … 265 270 this.radioButtonGroup.TabStop = false; 266 271 // 267 // colorDialogButton 268 // 269 this.colorDialogButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 270 this.colorDialogButton.Enabled = false; 271 this.colorDialogButton.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; 272 this.colorDialogButton.Location = new System.Drawing.Point(130, 469); 273 this.colorDialogButton.Name = "colorDialogButton"; 274 this.colorDialogButton.Size = new System.Drawing.Size(21, 21); 275 this.colorDialogButton.TabIndex = 20; 276 this.colorDialogButton.TextAlign = System.Drawing.ContentAlignment.MiddleRight; 277 this.tooltip.SetToolTip(this.colorDialogButton, "Choose color"); 278 this.colorDialogButton.UseVisualStyleBackColor = true; 279 this.colorDialogButton.Click += new System.EventHandler(this.colorDialogButton_Click); 272 // colorRunsButton 273 // 274 this.colorRunsButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 275 this.colorRunsButton.Enabled = false; 276 this.colorRunsButton.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; 277 this.colorRunsButton.Location = new System.Drawing.Point(131, 713); 278 this.colorRunsButton.Name = "colorRunsButton"; 279 this.colorRunsButton.Size = new System.Drawing.Size(21, 21); 280 this.colorRunsButton.TabIndex = 20; 281 this.tooltip.SetToolTip(this.colorRunsButton, "Color all selected runs"); 282 this.colorRunsButton.UseVisualStyleBackColor = true; 283 this.colorRunsButton.Click += new System.EventHandler(this.colorRunsButton_Click); 280 284 // 281 285 // colorDialog … … 289 293 this.colorXAxisButton.Enabled = false; 290 294 this.colorXAxisButton.Image = HeuristicLab.Common.Resources.VSImageLibrary.DisplayInColorVertical; 291 this.colorXAxisButton.Location = new System.Drawing.Point( 719, 469);295 this.colorXAxisButton.Location = new System.Drawing.Point(866, 715); 292 296 this.colorXAxisButton.Name = "colorXAxisButton"; 293 297 this.colorXAxisButton.Size = new System.Drawing.Size(21, 21); … … 301 305 this.colorYAxisButton.Enabled = false; 302 306 this.colorYAxisButton.Image = HeuristicLab.Common.Resources.VSImageLibrary.DisplayInColor; 303 this.colorYAxisButton.Location = new System.Drawing.Point( 251, 3);307 this.colorYAxisButton.Location = new System.Drawing.Point(430, 3); 304 308 this.colorYAxisButton.Name = "colorYAxisButton"; 305 309 this.colorYAxisButton.Size = new System.Drawing.Size(21, 21); … … 309 313 this.colorYAxisButton.Click += new System.EventHandler(this.colorYAxisButton_Click); 310 314 // 315 // transparencyTrackBar 316 // 317 this.transparencyTrackBar.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 318 this.transparencyTrackBar.LargeChange = 16; 319 this.transparencyTrackBar.Location = new System.Drawing.Point(302, 715); 320 this.transparencyTrackBar.Maximum = 254; 321 this.transparencyTrackBar.Name = "transparencyTrackBar"; 322 this.transparencyTrackBar.Size = new System.Drawing.Size(64, 45); 323 this.transparencyTrackBar.TabIndex = 24; 324 this.transparencyTrackBar.TickStyle = System.Windows.Forms.TickStyle.None; 325 this.tooltip.SetToolTip(this.transparencyTrackBar, "Sets the transparency of the colors"); 326 this.transparencyTrackBar.ValueChanged += new System.EventHandler(this.transparencyTrackBar_ValueChanged); 327 // 328 // hideRunsButton 329 // 330 this.hideRunsButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 331 this.hideRunsButton.Enabled = false; 332 this.hideRunsButton.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; 333 this.hideRunsButton.Location = new System.Drawing.Point(172, 713); 334 this.hideRunsButton.Name = "hideRunsButton"; 335 this.hideRunsButton.Size = new System.Drawing.Size(43, 21); 336 this.hideRunsButton.TabIndex = 26; 337 this.hideRunsButton.Text = "Hide"; 338 this.tooltip.SetToolTip(this.hideRunsButton, "Hides all selected runs"); 339 this.hideRunsButton.UseVisualStyleBackColor = true; 340 this.hideRunsButton.Click += new System.EventHandler(this.hideRunsButton_Click); 341 // 342 // colorDialogButton 343 // 344 this.colorDialogButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 345 this.colorDialogButton.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink; 346 this.colorDialogButton.Enabled = false; 347 this.colorDialogButton.Font = new System.Drawing.Font("Microsoft Sans Serif", 6.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 348 this.colorDialogButton.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; 349 this.colorDialogButton.Location = new System.Drawing.Point(152, 713); 350 this.colorDialogButton.Name = "colorDialogButton"; 351 this.colorDialogButton.Size = new System.Drawing.Size(14, 21); 352 this.colorDialogButton.TabIndex = 25; 353 this.colorDialogButton.Text = "v"; 354 this.tooltip.SetToolTip(this.colorDialogButton, "Choose color"); 355 this.colorDialogButton.UseVisualStyleBackColor = true; 356 this.colorDialogButton.Click += new System.EventHandler(this.colorDialogButton_Click); 357 // 311 358 // noRunsLabel 312 359 // 313 360 this.noRunsLabel.Anchor = System.Windows.Forms.AnchorStyles.None; 314 361 this.noRunsLabel.AutoSize = true; 315 this.noRunsLabel.Location = new System.Drawing.Point( 366, 228);362 this.noRunsLabel.Location = new System.Drawing.Point(432, 350); 316 363 this.noRunsLabel.Name = "noRunsLabel"; 317 364 this.noRunsLabel.Size = new System.Drawing.Size(138, 13); … … 322 369 // 323 370 this.sizeTrackBar.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 324 this.sizeTrackBar.Location = new System.Drawing.Point( 787, 3);371 this.sizeTrackBar.Location = new System.Drawing.Point(919, 3); 325 372 this.sizeTrackBar.Maximum = 20; 326 373 this.sizeTrackBar.Minimum = -20; … … 339 386 this.getDataAsMatrixToolStripMenuItem.Click += new System.EventHandler(this.getDataAsMatrixToolStripMenuItem_Click); 340 387 // 341 // transparencyTrackBar342 //343 this.transparencyTrackBar.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));344 this.transparencyTrackBar.LargeChange = 16;345 this.transparencyTrackBar.Location = new System.Drawing.Point(359, 470);346 this.transparencyTrackBar.Maximum = 254;347 this.transparencyTrackBar.Name = "transparencyTrackBar";348 this.transparencyTrackBar.Size = new System.Drawing.Size(64, 45);349 this.transparencyTrackBar.TabIndex = 24;350 this.transparencyTrackBar.TickStyle = System.Windows.Forms.TickStyle.None;351 this.tooltip.SetToolTip(this.transparencyTrackBar, "Sets the transparency of the colors");352 this.transparencyTrackBar.ValueChanged += new System.EventHandler(this.transparencyTrackBar_ValueChanged);353 //354 388 // transparencyLabel 355 389 // 356 390 this.transparencyLabel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 357 391 this.transparencyLabel.AutoSize = true; 358 this.transparencyLabel.Location = new System.Drawing.Point(2 78, 475);392 this.transparencyLabel.Location = new System.Drawing.Point(233, 717); 359 393 this.transparencyLabel.Name = "transparencyLabel"; 360 394 this.transparencyLabel.Size = new System.Drawing.Size(75, 13); … … 362 396 this.transparencyLabel.Text = "Transparency:"; 363 397 // 364 // colorRunsButton 365 // 366 this.colorRunsButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 367 this.colorRunsButton.Enabled = false; 368 this.colorRunsButton.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; 369 this.colorRunsButton.Location = new System.Drawing.Point(151, 469); 370 this.colorRunsButton.Name = "colorRunsButton"; 371 this.colorRunsButton.Size = new System.Drawing.Size(43, 21); 372 this.colorRunsButton.TabIndex = 25; 373 this.colorRunsButton.Text = "Color"; 374 this.colorRunsButton.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 375 this.tooltip.SetToolTip(this.colorRunsButton, "Color all selected runs"); 376 this.colorRunsButton.UseVisualStyleBackColor = true; 377 this.colorRunsButton.Click += new System.EventHandler(this.colorRunsButton_Click); 378 // 379 // hideRunsButton 380 // 381 this.hideRunsButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 382 this.hideRunsButton.Enabled = false; 383 this.hideRunsButton.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; 384 this.hideRunsButton.Location = new System.Drawing.Point(194, 469); 385 this.hideRunsButton.Name = "hideRunsButton"; 386 this.hideRunsButton.Size = new System.Drawing.Size(43, 21); 387 this.hideRunsButton.TabIndex = 26; 388 this.hideRunsButton.Text = "Hide"; 389 this.hideRunsButton.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 390 this.tooltip.SetToolTip(this.hideRunsButton, "Hides all selected runs"); 391 this.hideRunsButton.UseVisualStyleBackColor = true; 392 this.hideRunsButton.Click += new System.EventHandler(this.hideRunsButton_Click); 398 // unhideAllRunToolStripMenuItem 399 // 400 this.unhideAllRunToolStripMenuItem.Name = "unhideAllRunToolStripMenuItem"; 401 this.unhideAllRunToolStripMenuItem.Size = new System.Drawing.Size(256, 22); 402 this.unhideAllRunToolStripMenuItem.Text = "Unhide all"; 403 this.unhideAllRunToolStripMenuItem.Click += new System.EventHandler(this.unhideAllRunToolStripMenuItem_Click); 404 // 405 // colorResetToolStripMenuItem 406 // 407 this.colorResetToolStripMenuItem.Name = "colorResetToolStripMenuItem"; 408 this.colorResetToolStripMenuItem.Size = new System.Drawing.Size(256, 22); 409 this.colorResetToolStripMenuItem.Text = "Color reset"; 410 this.colorResetToolStripMenuItem.Click += new System.EventHandler(this.colorResetToolStripMenuItem_Click); 393 411 // 394 412 // RunCollectionBubbleChartView … … 398 416 this.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 399 417 this.Controls.Add(this.hideRunsButton); 400 this.Controls.Add(this.colorRunsButton);401 this.Controls.Add(this.transparencyTrackBar);402 418 this.Controls.Add(this.sizeTrackBar); 403 419 this.Controls.Add(this.colorYAxisButton); 404 420 this.Controls.Add(this.colorXAxisButton); 405 421 this.Controls.Add(this.noRunsLabel); 406 this.Controls.Add(this.color DialogButton);422 this.Controls.Add(this.colorRunsButton); 407 423 this.Controls.Add(this.radioButtonGroup); 408 this.Controls.Add(this.chart);409 this.Controls.Add(this.sizeLabel);410 this.Controls.Add(this.sizeComboBox);411 424 this.Controls.Add(this.yJitterLabel); 412 425 this.Controls.Add(this.transparencyLabel); … … 418 431 this.Controls.Add(this.yAxisComboBox); 419 432 this.Controls.Add(this.yTrackBar); 433 this.Controls.Add(this.colorDialogButton); 434 this.Controls.Add(this.chart); 435 this.Controls.Add(this.transparencyTrackBar); 436 this.Controls.Add(this.sizeLabel); 437 this.Controls.Add(this.sizeComboBox); 420 438 this.Name = "RunCollectionBubbleChartView"; 421 this.Size = new System.Drawing.Size( 854, 496);439 this.Size = new System.Drawing.Size(986, 741); 422 440 ((System.ComponentModel.ISupportInitialize)(this.xTrackBar)).EndInit(); 423 441 ((System.ComponentModel.ISupportInitialize)(this.yTrackBar)).EndInit(); … … 425 443 this.radioButtonGroup.ResumeLayout(false); 426 444 this.radioButtonGroup.PerformLayout(); 445 ((System.ComponentModel.ISupportInitialize)(this.transparencyTrackBar)).EndInit(); 427 446 ((System.ComponentModel.ISupportInitialize)(this.sizeTrackBar)).EndInit(); 428 ((System.ComponentModel.ISupportInitialize)(this.transparencyTrackBar)).EndInit();429 447 this.ResumeLayout(false); 430 448 this.PerformLayout(); … … 447 465 private System.Windows.Forms.RadioButton selectButton; 448 466 private System.Windows.Forms.GroupBox radioButtonGroup; 449 private System.Windows.Forms.Button color DialogButton;467 private System.Windows.Forms.Button colorRunsButton; 450 468 private System.Windows.Forms.ColorDialog colorDialog; 451 469 private System.Windows.Forms.ToolTip tooltip; 452 470 private System.Windows.Forms.Label noRunsLabel; 453 471 private System.Windows.Forms.ToolStripMenuItem openBoxPlotViewToolStripMenuItem; 454 private System.Windows.Forms.ToolStripMenuItem hideRun ToolStripMenuItem;472 private System.Windows.Forms.ToolStripMenuItem hideRunsToolStripMenuItem; 455 473 private System.Windows.Forms.Button colorXAxisButton; 456 474 private System.Windows.Forms.Button colorYAxisButton; … … 459 477 private System.Windows.Forms.TrackBar transparencyTrackBar; 460 478 private System.Windows.Forms.Label transparencyLabel; 461 private System.Windows.Forms.Button colorRunsButton;462 479 private System.Windows.Forms.Button hideRunsButton; 480 private System.Windows.Forms.ToolStripMenuItem unhideAllRunToolStripMenuItem; 481 private System.Windows.Forms.ToolStripMenuItem colorResetToolStripMenuItem; 482 private System.Windows.Forms.Button colorDialogButton; 463 483 } 464 484 } -
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews/RunCollectionBubbleChartView.cs
r9421 r9835 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2013 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 56 56 private bool suppressUpdates = false; 57 57 58 private RunCollectionContentConstraint visibilityConstraint = new RunCollectionContentConstraint() { Active = true }; 58 59 59 60 public RunCollectionBubbleChartView() { 60 61 InitializeComponent(); 61 62 62 chart.ContextMenuStrip.Items.Insert(0, hideRunToolStripMenuItem); 63 chart.ContextMenuStrip.Items.Insert(1, openBoxPlotViewToolStripMenuItem); 64 chart.ContextMenuStrip.Items.Add(getDataAsMatrixToolStripMenuItem); 63 chart.ContextMenuStrip.Items.Insert(0, openBoxPlotViewToolStripMenuItem); 64 chart.ContextMenuStrip.Items.Insert(1, getDataAsMatrixToolStripMenuItem); 65 chart.ContextMenuStrip.Items.Insert(2, new ToolStripSeparator()); 66 chart.ContextMenuStrip.Items.Insert(3, hideRunsToolStripMenuItem); 67 chart.ContextMenuStrip.Items.Insert(4, unhideAllRunToolStripMenuItem); 68 chart.ContextMenuStrip.Items.Insert(5, colorResetToolStripMenuItem); 69 chart.ContextMenuStrip.Items.Insert(6, new ToolStripSeparator()); 65 70 chart.ContextMenuStrip.Opening += new System.ComponentModel.CancelEventHandler(ContextMenuStrip_Opening); 66 71 67 colorDialog.Color = Color. Black;68 color DialogButton.Image = this.GenerateImage(16, 16, this.colorDialog.Color);72 colorDialog.Color = Color.Orange; 73 colorRunsButton.Image = this.GenerateImage(16, 16, this.colorDialog.Color); 69 74 isSelecting = false; 70 75 … … 167 172 point.MarkerStyle = MarkerStyle.Cross; 168 173 } else { 169 point.Color = Color.FromArgb(255 - transparencyTrackBar.Value, ((IRun)point.Tag).Color);174 point.Color = Color.FromArgb(255 - LogTransform(transparencyTrackBar.Value), ((IRun)point.Tag).Color); 170 175 point.MarkerStyle = MarkerStyle.Circle; 171 176 } … … 310 315 double sizeRange = maxSizeValue - minSizeValue; 311 316 312 const int smallestBubbleSize = 5;317 const int smallestBubbleSize = 7; 313 318 314 319 foreach (DataPoint point in series.Points) { … … 331 336 var yAxis = this.chart.ChartAreas[0].AxisY; 332 337 333 SetAutomaticUpdateOfAxis(xAxis, false);334 SetAutomaticUpdateOfAxis(yAxis, false);335 336 338 double xAxisRange = xAxis.Maximum - xAxis.Minimum; 337 339 double yAxisRange = yAxis.Maximum - yAxis.Minimum; … … 351 353 } 352 354 355 if (xJitterFactor.IsAlmost(0.0) && yJitterFactor.IsAlmost(0.0)) { 356 SetAutomaticUpdateOfAxis(xAxis, true); 357 SetAutomaticUpdateOfAxis(yAxis, true); 358 chart.ChartAreas[0].RecalculateAxesScale(); 359 } else { 360 SetAutomaticUpdateOfAxis(xAxis, false); 361 SetAutomaticUpdateOfAxis(yAxis, false); 362 } 353 363 } 354 364 … … 431 441 if (!this.categoricalMapping.ContainsKey(dimension)) { 432 442 this.categoricalMapping[dimension] = new Dictionary<object, double>(); 433 var orderedCategories = Content.Where(r => r.Visible).Select(r => Content.GetValue(r, dimension).ToString()) 434 .Distinct() 435 .OrderBy(x => x, new NaturalStringComparer()); 443 var orderedCategories = Content.Where(r => r.Visible && Content.GetValue(r, dimension) != null).Select(r => Content.GetValue(r, dimension).ToString()) 444 .Distinct().OrderBy(x => x, new NaturalStringComparer()); 436 445 int count = 1; 437 446 foreach (var category in orderedCategories) { … … 535 544 double maxY = Math.Max(yCursor.SelectionStart, yCursor.SelectionEnd); 536 545 546 if (Control.ModifierKeys != Keys.Control) { 547 ClearSelectedRuns(); 548 } 549 537 550 //check for click to select a single model 538 551 if (minX == maxX && minY == maxY) { … … 542 555 var point = chart.Series[0].Points[pointIndex]; 543 556 IRun run = (IRun)point.Tag; 544 point.Color = Color.Red; 545 point.MarkerStyle = MarkerStyle.Cross; 546 selectedRuns.Add(run); 547 548 } else ClearSelectedRuns(); 557 if (selectedRuns.Contains(run)) { 558 point.MarkerStyle = MarkerStyle.Circle; 559 point.Color = Color.FromArgb(255 - LogTransform(transparencyTrackBar.Value), run.Color); 560 selectedRuns.Remove(run); 561 } else { 562 point.Color = Color.Red; 563 point.MarkerStyle = MarkerStyle.Cross; 564 selectedRuns.Add(run); 565 } 566 } 549 567 } else { 550 568 foreach (DataPoint point in this.chart.Series[0].Points) { 551 if (point.XValue < minX || point.XValue > =maxX) continue;552 if (point.YValues[0] < minY || point.YValues[0] > =maxY) continue;569 if (point.XValue < minX || point.XValue > maxX) continue; 570 if (point.YValues[0] < minY || point.YValues[0] > maxY) continue; 553 571 point.MarkerStyle = MarkerStyle.Cross; 554 572 point.Color = Color.Red; … … 688 706 private void zoomButton_CheckedChanged(object sender, EventArgs e) { 689 707 this.isSelecting = selectButton.Checked; 708 this.colorRunsButton.Enabled = this.isSelecting; 690 709 this.colorDialogButton.Enabled = this.isSelecting; 691 this.colorRunsButton.Enabled = this.isSelecting;692 710 this.hideRunsButton.Enabled = this.isSelecting; 693 711 this.chart.ChartAreas[0].AxisX.ScaleView.Zoomable = !isSelecting; … … 696 714 } 697 715 698 private IRun runToHide = null;699 716 private void ContextMenuStrip_Opening(object sender, System.ComponentModel.CancelEventArgs e) { 700 var pos = Control.MousePosition; 701 var chartPos = chart.PointToClient(pos); 702 703 HitTestResult h = this.chart.HitTest(chartPos.X, chartPos.Y); 704 if (h.ChartElementType == ChartElementType.DataPoint) { 705 runToHide = (IRun)((DataPoint)h.Object).Tag; 706 hideRunToolStripMenuItem.Visible = true; 707 } else { 708 runToHide = null; 709 hideRunToolStripMenuItem.Visible = false; 710 } 711 712 } 713 private void hideRunToolStripMenuItem_Click(object sender, EventArgs e) { 714 var constraint = Content.Constraints.OfType<RunCollectionContentConstraint>().FirstOrDefault(c => c.Active); 715 if (constraint == null) { 716 constraint = new RunCollectionContentConstraint(); 717 Content.Constraints.Add(constraint); 718 constraint.Active = true; 719 } 720 constraint.ConstraintData.Add(runToHide); 717 hideRunsToolStripMenuItem.Visible = selectedRuns.Any(); 718 } 719 720 private void unhideAllRunToolStripMenuItem_Click(object sender, EventArgs e) { 721 visibilityConstraint.ConstraintData.Clear(); 722 if (Content.Constraints.Contains(visibilityConstraint)) Content.Constraints.Remove(visibilityConstraint); 723 } 724 private void hideRunsToolStripMenuItem_Click(object sender, EventArgs e) { 725 HideRuns(selectedRuns); 726 //could not use ClearSelectedRuns as the runs are not visible anymore 727 selectedRuns.Clear(); 721 728 } 722 729 private void hideRunsButton_Click(object sender, EventArgs e) { 723 if (!selectedRuns.Any()) return; 724 var constraint = new RunCollectionContentConstraint(); 725 constraint.ConstraintData = new ItemSet<IRun>(selectedRuns); 726 Content.Constraints.Add(constraint); 727 ClearSelectedRuns(); 728 constraint.Active = true; 730 HideRuns(selectedRuns); 731 //could not use ClearSelectedRuns as the runs are not visible anymore 732 selectedRuns.Clear(); 733 } 734 735 private void HideRuns(IEnumerable<IRun> runs) { 736 visibilityConstraint.Active = false; 737 if (!Content.Constraints.Contains(visibilityConstraint)) Content.Constraints.Add(visibilityConstraint); 738 foreach (var run in runs) { 739 visibilityConstraint.ConstraintData.Add(run); 740 } 741 visibilityConstraint.Active = true; 729 742 } 730 743 … … 744 757 double max = transparencyTrackBar.Maximum; 745 758 double r = (x - min) / (max - min); // r \in [0..1] 746 double l = Math. Log(r + 1) / Math.Log(2.0); // l \in [0..1]759 double l = Math.Max(Math.Min((1.0 - Math.Pow(0.05, r)) / 0.95, 1), 0); // l \in [0..1] 747 760 return (int)Math.Round(255.0 * l); 748 761 } … … 800 813 801 814 #region coloring 815 private void colorResetToolStripMenuItem_Click(object sender, EventArgs e) { 816 Content.UpdateOfRunsInProgress = true; 817 818 IEnumerable<IRun> runs; 819 if (selectedRuns.Any()) runs = selectedRuns; 820 else runs = Content; 821 822 foreach (var run in runs) 823 run.Color = Color.Black; 824 ClearSelectedRuns(); 825 826 Content.UpdateOfRunsInProgress = false; 827 } 802 828 private void colorDialogButton_Click(object sender, EventArgs e) { 803 829 if (colorDialog.ShowDialog(this) == DialogResult.OK) { 804 this.colorDialogButton.Image = this.GenerateImage(16, 16, this.colorDialog.Color); 830 this.colorRunsButton.Image = this.GenerateImage(16, 16, this.colorDialog.Color); 831 colorRunsButton_Click(sender, e); 805 832 } 806 833 } -
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews/RunCollectionDataTableView.Designer.cs
r9240 r9835 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2013 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews/RunCollectionDataTableView.cs
r9240 r9835 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2013 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews/RunCollectionTabularView.Designer.cs
r7469 r9835 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2013 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews/RunCollectionTabularView.cs
r8962 r9835 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2013 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 101 101 } 102 102 private void run_Changed(object sender, EventArgs e) { 103 if (suppressUpdates) return; 103 104 if (InvokeRequired) 104 105 this.Invoke(new EventHandler(run_Changed), sender, e); … … 199 200 runIndex++; 200 201 } 202 rowsTextBox.Text = dataGridView.Rows.GetRowCount(DataGridViewElementStates.Visible).ToString(); 201 203 UpdateRowHeaders(); 202 204 } -
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews/RunCollectionView.Designer.cs
r7469 r9835 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2013 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/HeuristicLab.EvolutionaryTracking/HeuristicLab.Optimization.Views/3.3/RunCollectionViews/RunCollectionView.cs
r7469 r9835 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 2Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2013 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 255 255 if (e.KeyCode == Keys.Delete) { 256 256 if ((itemsListView.SelectedItems.Count > 0) && !Content.IsReadOnly && !ReadOnly) { 257 foreach (ListViewItem item in itemsListView.SelectedItems) 258 Content.Remove((IRun)item.Tag); 257 if (RunCollection != null) { 258 RunCollection.RemoveRange(itemsListView.SelectedItems.Cast<ListViewItem>().Select(i => (IRun)i.Tag)); 259 } else { 260 foreach (ListViewItem item in itemsListView.SelectedItems) 261 Content.Remove((IRun)item.Tag); 262 } 259 263 } 260 264 } … … 350 354 private void removeButton_Click(object sender, EventArgs e) { 351 355 if (itemsListView.SelectedItems.Count > 0) { 352 foreach (ListViewItem item in itemsListView.SelectedItems) 353 Content.Remove((IRun)item.Tag); 356 if (RunCollection != null) { 357 RunCollection.RemoveRange(itemsListView.SelectedItems.Cast<ListViewItem>().Select(i => (IRun)i.Tag)); 358 } else { 359 foreach (ListViewItem item in itemsListView.SelectedItems) 360 Content.Remove((IRun)item.Tag); 361 } 354 362 itemsListView.SelectedItems.Clear(); 355 363 } … … 377 385 try { 378 386 RunCollection.Modify(); 379 } finally { 387 } 388 finally { 380 389 ReadOnly = false; 381 390 }
Note: See TracChangeset
for help on using the changeset viewer.