- Timestamp:
- 04/19/16 12:40:40 (9 years ago)
- Location:
- branches/PerformanceComparison/HeuristicLab.OptimizationExpertSystem/3.3
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/PerformanceComparison/HeuristicLab.OptimizationExpertSystem/3.3/Docking/AlgorithmControlForm.cs
r13722 r13774 119 119 120 120 #region Algorithm Events 121 private void AlgorithmOnExecutionStateChanged(object sender, EventArgs eventArgs) { 121 private void AlgorithmOnExecutionStateChanged(object sender, EventArgs e) { 122 if (InvokeRequired) { Invoke((Action<object, EventArgs>)AlgorithmOnExecutionStateChanged, sender, e); return; } 122 123 if (ShowOnlyFinalResult && (Algorithm.ExecutionState == ExecutionState.Stopped 123 124 || Algorithm.ExecutionState == ExecutionState.Paused)) -
branches/PerformanceComparison/HeuristicLab.OptimizationExpertSystem/3.3/Plugin.cs.frame
r13722 r13774 20 20 #endregion 21 21 22 using HeuristicLab.Clients.Access; 23 using HeuristicLab.Common; 24 using HeuristicLab.Core; 25 using HeuristicLab.PluginInfrastructure; 22 26 using System.Windows.Forms; 23 using HeuristicLab.Clients.Access;24 using HeuristicLab.PluginInfrastructure;25 27 26 28 namespace HeuristicLab.OptimizationExpertSystem { … … 50 52 ClientInformation.InitializeAsync(); 51 53 UserInformation.InitializeAsync(); 52 54 ContentManager.Initialize(new PersistenceContentManager()); 53 55 mainForm.ShowContentInViewHost = true; 54 56 Application.Run(mainForm); -
branches/PerformanceComparison/HeuristicLab.OptimizationExpertSystem/3.3/Views/KnowledgeCenterAllinOneView.cs
r13751 r13774 78 78 #region Event Registration 79 79 protected override void DeregisterContentEvents() { 80 Content. SuggestedInstances.CollectionReset -= SuggestedInstancesOnChanged;81 Content. SuggestedInstances.ItemsAdded -= SuggestedInstancesOnChanged;82 Content. SuggestedInstances.ItemsMoved -= SuggestedInstancesOnChanged;83 Content. SuggestedInstances.ItemsRemoved -= SuggestedInstancesOnChanged;84 Content. SuggestedInstances.ItemsReplaced -= SuggestedInstancesOnChanged;80 Content.AlgorithmInstances.CollectionReset -= SuggestedInstancesOnChanged; 81 Content.AlgorithmInstances.ItemsAdded -= SuggestedInstancesOnChanged; 82 Content.AlgorithmInstances.ItemsMoved -= SuggestedInstancesOnChanged; 83 Content.AlgorithmInstances.ItemsRemoved -= SuggestedInstancesOnChanged; 84 Content.AlgorithmInstances.ItemsReplaced -= SuggestedInstancesOnChanged; 85 85 Content.SolutionSeedingPool.CollectionReset -= SeedingPoolOnChanged; 86 86 Content.SolutionSeedingPool.ItemsAdded -= SeedingPoolOnChanged; … … 94 94 protected override void RegisterContentEvents() { 95 95 base.RegisterContentEvents(); 96 Content. SuggestedInstances.CollectionReset += SuggestedInstancesOnChanged;97 Content. SuggestedInstances.ItemsAdded += SuggestedInstancesOnChanged;98 Content. SuggestedInstances.ItemsMoved += SuggestedInstancesOnChanged;99 Content. SuggestedInstances.ItemsRemoved += SuggestedInstancesOnChanged;100 Content. SuggestedInstances.ItemsReplaced += SuggestedInstancesOnChanged;96 Content.AlgorithmInstances.CollectionReset += SuggestedInstancesOnChanged; 97 Content.AlgorithmInstances.ItemsAdded += SuggestedInstancesOnChanged; 98 Content.AlgorithmInstances.ItemsMoved += SuggestedInstancesOnChanged; 99 Content.AlgorithmInstances.ItemsRemoved += SuggestedInstancesOnChanged; 100 Content.AlgorithmInstances.ItemsReplaced += SuggestedInstancesOnChanged; 101 101 Content.SolutionSeedingPool.CollectionReset += SeedingPoolOnChanged; 102 102 Content.SolutionSeedingPool.ItemsAdded += SeedingPoolOnChanged; … … 248 248 private void AlgorithmCloneButtonOnClick(object sender, EventArgs e) { 249 249 if (suggestedInstancesComboBox.SelectedIndex >= 0) 250 MainFormManager.MainForm.ShowContent((IAlgorithm)Content. SuggestedInstances[suggestedInstancesComboBox.SelectedIndex].Clone());250 MainFormManager.MainForm.ShowContent((IAlgorithm)Content.AlgorithmInstances[suggestedInstancesComboBox.SelectedIndex].Clone()); 251 251 } 252 252 … … 279 279 if (InvokeRequired) { Invoke((Action<object, EventArgs>)SuggestedInstancesComboBoxOnSelectedIndexChanged, sender, e); return; } 280 280 if (suggestedInstancesComboBox.SelectedIndex >= 0) { 281 var alg = Content. SuggestedInstances[suggestedInstancesComboBox.SelectedIndex];281 var alg = Content.AlgorithmInstances[suggestedInstancesComboBox.SelectedIndex]; 282 282 solverParametersView.Content = alg.Parameters; 283 283 var engineAlg = alg as EngineAlgorithm; … … 328 328 if (Content == null) return; 329 329 330 for (var i = 0; i < Content. SuggestedInstances.Count; i++) {331 suggestedInstancesComboBox.Items.Add(Content. SuggestedInstances[i]);332 if (prevSelection == null || Content. SuggestedInstances[i].Name == prevSelection.Name)330 for (var i = 0; i < Content.AlgorithmInstances.Count; i++) { 331 suggestedInstancesComboBox.Items.Add(Content.AlgorithmInstances[i]); 332 if (prevSelection == null || Content.AlgorithmInstances[i].Name == prevSelection.Name) 333 333 prevNewIndex = prevSelection == null ? 0 : i; 334 334 } -
branches/PerformanceComparison/HeuristicLab.OptimizationExpertSystem/3.3/Views/KnowledgeCenterViewBase.cs
r13752 r13774 88 88 89 89 private void RegisterContentSuggestedInstancesEvents() { 90 Content. SuggestedInstances.CollectionReset += ContentOnSuggestedInstancesChanged;91 Content. SuggestedInstances.ItemsAdded += ContentOnSuggestedInstancesChanged;92 Content. SuggestedInstances.ItemsMoved += ContentOnSuggestedInstancesChanged;93 Content. SuggestedInstances.ItemsRemoved += ContentOnSuggestedInstancesChanged;94 Content. SuggestedInstances.ItemsReplaced += ContentOnSuggestedInstancesChanged;90 Content.AlgorithmInstances.CollectionReset += ContentOnSuggestedInstancesChanged; 91 Content.AlgorithmInstances.ItemsAdded += ContentOnSuggestedInstancesChanged; 92 Content.AlgorithmInstances.ItemsMoved += ContentOnSuggestedInstancesChanged; 93 Content.AlgorithmInstances.ItemsRemoved += ContentOnSuggestedInstancesChanged; 94 Content.AlgorithmInstances.ItemsReplaced += ContentOnSuggestedInstancesChanged; 95 95 } 96 96 … … 139 139 140 140 private void DeregisterContentSuggestedInstancesEvents() { 141 Content. SuggestedInstances.CollectionReset -= ContentOnSuggestedInstancesChanged;142 Content. SuggestedInstances.ItemsAdded -= ContentOnSuggestedInstancesChanged;143 Content. SuggestedInstances.ItemsMoved -= ContentOnSuggestedInstancesChanged;144 Content. SuggestedInstances.ItemsRemoved -= ContentOnSuggestedInstancesChanged;145 Content. SuggestedInstances.ItemsReplaced -= ContentOnSuggestedInstancesChanged;141 Content.AlgorithmInstances.CollectionReset -= ContentOnSuggestedInstancesChanged; 142 Content.AlgorithmInstances.ItemsAdded -= ContentOnSuggestedInstancesChanged; 143 Content.AlgorithmInstances.ItemsMoved -= ContentOnSuggestedInstancesChanged; 144 Content.AlgorithmInstances.ItemsRemoved -= ContentOnSuggestedInstancesChanged; 145 Content.AlgorithmInstances.ItemsReplaced -= ContentOnSuggestedInstancesChanged; 146 146 } 147 147 #endregion -
branches/PerformanceComparison/HeuristicLab.OptimizationExpertSystem/3.3/Views/SolverView.Designer.cs
r13759 r13774 45 45 /// </summary> 46 46 private void InitializeComponent() { 47 WeifenLuo.WinFormsUI.Docking.DockPanelSkin dockPanelSkin 1= new WeifenLuo.WinFormsUI.Docking.DockPanelSkin();48 WeifenLuo.WinFormsUI.Docking.AutoHideStripSkin autoHideStripSkin 1= new WeifenLuo.WinFormsUI.Docking.AutoHideStripSkin();49 WeifenLuo.WinFormsUI.Docking.DockPanelGradient dockPanelGradient 1= new WeifenLuo.WinFormsUI.Docking.DockPanelGradient();50 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient 1= new WeifenLuo.WinFormsUI.Docking.TabGradient();51 WeifenLuo.WinFormsUI.Docking.DockPaneStripSkin dockPaneStripSkin 1= new WeifenLuo.WinFormsUI.Docking.DockPaneStripSkin();52 WeifenLuo.WinFormsUI.Docking.DockPaneStripGradient dockPaneStripGradient 1= new WeifenLuo.WinFormsUI.Docking.DockPaneStripGradient();53 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient 2= new WeifenLuo.WinFormsUI.Docking.TabGradient();54 WeifenLuo.WinFormsUI.Docking.DockPanelGradient dockPanelGradient 2= new WeifenLuo.WinFormsUI.Docking.DockPanelGradient();55 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient 3= new WeifenLuo.WinFormsUI.Docking.TabGradient();56 WeifenLuo.WinFormsUI.Docking.DockPaneStripToolWindowGradient dockPaneStripToolWindowGradient 1= new WeifenLuo.WinFormsUI.Docking.DockPaneStripToolWindowGradient();57 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient 4= new WeifenLuo.WinFormsUI.Docking.TabGradient();58 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient 5= new WeifenLuo.WinFormsUI.Docking.TabGradient();59 WeifenLuo.WinFormsUI.Docking.DockPanelGradient dockPanelGradient 3= new WeifenLuo.WinFormsUI.Docking.DockPanelGradient();60 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient 6= new WeifenLuo.WinFormsUI.Docking.TabGradient();61 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient 7= new WeifenLuo.WinFormsUI.Docking.TabGradient();47 WeifenLuo.WinFormsUI.Docking.DockPanelSkin dockPanelSkin2 = new WeifenLuo.WinFormsUI.Docking.DockPanelSkin(); 48 WeifenLuo.WinFormsUI.Docking.AutoHideStripSkin autoHideStripSkin2 = new WeifenLuo.WinFormsUI.Docking.AutoHideStripSkin(); 49 WeifenLuo.WinFormsUI.Docking.DockPanelGradient dockPanelGradient4 = new WeifenLuo.WinFormsUI.Docking.DockPanelGradient(); 50 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient8 = new WeifenLuo.WinFormsUI.Docking.TabGradient(); 51 WeifenLuo.WinFormsUI.Docking.DockPaneStripSkin dockPaneStripSkin2 = new WeifenLuo.WinFormsUI.Docking.DockPaneStripSkin(); 52 WeifenLuo.WinFormsUI.Docking.DockPaneStripGradient dockPaneStripGradient2 = new WeifenLuo.WinFormsUI.Docking.DockPaneStripGradient(); 53 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient9 = new WeifenLuo.WinFormsUI.Docking.TabGradient(); 54 WeifenLuo.WinFormsUI.Docking.DockPanelGradient dockPanelGradient5 = new WeifenLuo.WinFormsUI.Docking.DockPanelGradient(); 55 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient10 = new WeifenLuo.WinFormsUI.Docking.TabGradient(); 56 WeifenLuo.WinFormsUI.Docking.DockPaneStripToolWindowGradient dockPaneStripToolWindowGradient2 = new WeifenLuo.WinFormsUI.Docking.DockPaneStripToolWindowGradient(); 57 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient11 = new WeifenLuo.WinFormsUI.Docking.TabGradient(); 58 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient12 = new WeifenLuo.WinFormsUI.Docking.TabGradient(); 59 WeifenLuo.WinFormsUI.Docking.DockPanelGradient dockPanelGradient6 = new WeifenLuo.WinFormsUI.Docking.DockPanelGradient(); 60 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient13 = new WeifenLuo.WinFormsUI.Docking.TabGradient(); 61 WeifenLuo.WinFormsUI.Docking.TabGradient tabGradient14 = new WeifenLuo.WinFormsUI.Docking.TabGradient(); 62 62 this.minTargetView = new HeuristicLab.Data.Views.StringConvertibleValueView(); 63 63 this.maxEvaluationsView = new HeuristicLab.Data.Views.StringConvertibleValueView(); … … 81 81 this.seedingStrategyLabel = new System.Windows.Forms.Label(); 82 82 this.evaluationsLimitabel = new System.Windows.Forms.Label(); 83 this. algorithmSuggestionLabel = new System.Windows.Forms.Label();83 this.recommenderLabel = new System.Windows.Forms.Label(); 84 84 this.suggestedInstancesComboBox = new System.Windows.Forms.ComboBox(); 85 this.recommenderComboBox = new System.Windows.Forms.ComboBox(); 86 this.solverSplitContainer = new System.Windows.Forms.SplitContainer(); 87 this.recommenderViewHost = new HeuristicLab.MainForm.WindowsForms.ViewHost(); 88 this.instanceLabel = new System.Windows.Forms.Label(); 89 this.recommendRefreshButton = new System.Windows.Forms.Button(); 85 90 this.solverTabControl.SuspendLayout(); 86 91 this.resultsTabPage.SuspendLayout(); … … 89 94 this.parametersTabPage.SuspendLayout(); 90 95 this.operatorGraphTabPage.SuspendLayout(); 96 ((System.ComponentModel.ISupportInitialize)(this.solverSplitContainer)).BeginInit(); 97 this.solverSplitContainer.Panel1.SuspendLayout(); 98 this.solverSplitContainer.Panel2.SuspendLayout(); 99 this.solverSplitContainer.SuspendLayout(); 91 100 this.SuspendLayout(); 92 101 // … … 115 124 // algorithmCloneButton 116 125 // 117 this.algorithmCloneButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 118 this.algorithmCloneButton.Location = new System.Drawing.Point(823, 56); 126 this.algorithmCloneButton.Location = new System.Drawing.Point(123, 60); 119 127 this.algorithmCloneButton.Name = "algorithmCloneButton"; 120 128 this.algorithmCloneButton.Size = new System.Drawing.Size(26, 23); … … 136 144 // 137 145 this.solverTabControl.AllowDrop = true; 138 this.solverTabControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)139 | System.Windows.Forms.AnchorStyles.Left)140 | System.Windows.Forms.AnchorStyles.Right)));141 146 this.solverTabControl.Controls.Add(this.resultsTabPage); 142 147 this.solverTabControl.Controls.Add(this.runsTabPage); … … 145 150 this.solverTabControl.Controls.Add(this.parametersTabPage); 146 151 this.solverTabControl.Controls.Add(this.operatorGraphTabPage); 147 this.solverTabControl.Location = new System.Drawing.Point(0, 84); 152 this.solverTabControl.Dock = System.Windows.Forms.DockStyle.Fill; 153 this.solverTabControl.Location = new System.Drawing.Point(3, 3); 148 154 this.solverTabControl.Name = "solverTabControl"; 149 155 this.solverTabControl.SelectedIndex = 0; 150 this.solverTabControl.Size = new System.Drawing.Size( 849, 480);156 this.solverTabControl.Size = new System.Drawing.Size(556, 502); 151 157 this.solverTabControl.TabIndex = 11; 152 158 // … … 158 164 this.resultsTabPage.Name = "resultsTabPage"; 159 165 this.resultsTabPage.Padding = new System.Windows.Forms.Padding(3); 160 this.resultsTabPage.Size = new System.Drawing.Size( 841, 454);166 this.resultsTabPage.Size = new System.Drawing.Size(548, 476); 161 167 this.resultsTabPage.TabIndex = 2; 162 168 this.resultsTabPage.Text = "Results"; … … 166 172 // 167 173 this.showOnlyFinalResultCheckBox.AutoSize = true; 174 this.showOnlyFinalResultCheckBox.Checked = true; 175 this.showOnlyFinalResultCheckBox.CheckState = System.Windows.Forms.CheckState.Checked; 168 176 this.showOnlyFinalResultCheckBox.Location = new System.Drawing.Point(6, 6); 169 177 this.showOnlyFinalResultCheckBox.Name = "showOnlyFinalResultCheckBox"; … … 181 189 this.resultsDockPanel.Location = new System.Drawing.Point(3, 29); 182 190 this.resultsDockPanel.Name = "resultsDockPanel"; 183 this.resultsDockPanel.Size = new System.Drawing.Size( 835, 422);184 dockPanelGradient 1.EndColor = System.Drawing.SystemColors.ControlLight;185 dockPanelGradient 1.StartColor = System.Drawing.SystemColors.ControlLight;186 autoHideStripSkin 1.DockStripGradient = dockPanelGradient1;187 tabGradient 1.EndColor = System.Drawing.SystemColors.Control;188 tabGradient 1.StartColor = System.Drawing.SystemColors.Control;189 tabGradient 1.TextColor = System.Drawing.SystemColors.ControlDarkDark;190 autoHideStripSkin 1.TabGradient = tabGradient1;191 autoHideStripSkin 1.TextFont = new System.Drawing.Font("Segoe UI", 9F);192 dockPanelSkin 1.AutoHideStripSkin = autoHideStripSkin1;193 tabGradient 2.EndColor = System.Drawing.SystemColors.ControlLightLight;194 tabGradient 2.StartColor = System.Drawing.SystemColors.ControlLightLight;195 tabGradient 2.TextColor = System.Drawing.SystemColors.ControlText;196 dockPaneStripGradient 1.ActiveTabGradient = tabGradient2;197 dockPanelGradient 2.EndColor = System.Drawing.SystemColors.Control;198 dockPanelGradient 2.StartColor = System.Drawing.SystemColors.Control;199 dockPaneStripGradient 1.DockStripGradient = dockPanelGradient2;200 tabGradient 3.EndColor = System.Drawing.SystemColors.ControlLight;201 tabGradient 3.StartColor = System.Drawing.SystemColors.ControlLight;202 tabGradient 3.TextColor = System.Drawing.SystemColors.ControlText;203 dockPaneStripGradient 1.InactiveTabGradient = tabGradient3;204 dockPaneStripSkin 1.DocumentGradient = dockPaneStripGradient1;205 dockPaneStripSkin 1.TextFont = new System.Drawing.Font("Segoe UI", 9F);206 tabGradient 4.EndColor = System.Drawing.SystemColors.ActiveCaption;207 tabGradient 4.LinearGradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;208 tabGradient 4.StartColor = System.Drawing.SystemColors.GradientActiveCaption;209 tabGradient 4.TextColor = System.Drawing.SystemColors.ActiveCaptionText;210 dockPaneStripToolWindowGradient 1.ActiveCaptionGradient = tabGradient4;211 tabGradient 5.EndColor = System.Drawing.SystemColors.Control;212 tabGradient 5.StartColor = System.Drawing.SystemColors.Control;213 tabGradient 5.TextColor = System.Drawing.SystemColors.ControlText;214 dockPaneStripToolWindowGradient 1.ActiveTabGradient = tabGradient5;215 dockPanelGradient 3.EndColor = System.Drawing.SystemColors.ControlLight;216 dockPanelGradient 3.StartColor = System.Drawing.SystemColors.ControlLight;217 dockPaneStripToolWindowGradient 1.DockStripGradient = dockPanelGradient3;218 tabGradient 6.EndColor = System.Drawing.SystemColors.InactiveCaption;219 tabGradient 6.LinearGradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;220 tabGradient 6.StartColor = System.Drawing.SystemColors.GradientInactiveCaption;221 tabGradient 6.TextColor = System.Drawing.SystemColors.InactiveCaptionText;222 dockPaneStripToolWindowGradient 1.InactiveCaptionGradient = tabGradient6;223 tabGradient 7.EndColor = System.Drawing.Color.Transparent;224 tabGradient 7.StartColor = System.Drawing.Color.Transparent;225 tabGradient 7.TextColor = System.Drawing.SystemColors.ControlDarkDark;226 dockPaneStripToolWindowGradient 1.InactiveTabGradient = tabGradient7;227 dockPaneStripSkin 1.ToolWindowGradient = dockPaneStripToolWindowGradient1;228 dockPanelSkin 1.DockPaneStripSkin = dockPaneStripSkin1;229 this.resultsDockPanel.Skin = dockPanelSkin 1;191 this.resultsDockPanel.Size = new System.Drawing.Size(542, 444); 192 dockPanelGradient4.EndColor = System.Drawing.SystemColors.ControlLight; 193 dockPanelGradient4.StartColor = System.Drawing.SystemColors.ControlLight; 194 autoHideStripSkin2.DockStripGradient = dockPanelGradient4; 195 tabGradient8.EndColor = System.Drawing.SystemColors.Control; 196 tabGradient8.StartColor = System.Drawing.SystemColors.Control; 197 tabGradient8.TextColor = System.Drawing.SystemColors.ControlDarkDark; 198 autoHideStripSkin2.TabGradient = tabGradient8; 199 autoHideStripSkin2.TextFont = new System.Drawing.Font("Segoe UI", 9F); 200 dockPanelSkin2.AutoHideStripSkin = autoHideStripSkin2; 201 tabGradient9.EndColor = System.Drawing.SystemColors.ControlLightLight; 202 tabGradient9.StartColor = System.Drawing.SystemColors.ControlLightLight; 203 tabGradient9.TextColor = System.Drawing.SystemColors.ControlText; 204 dockPaneStripGradient2.ActiveTabGradient = tabGradient9; 205 dockPanelGradient5.EndColor = System.Drawing.SystemColors.Control; 206 dockPanelGradient5.StartColor = System.Drawing.SystemColors.Control; 207 dockPaneStripGradient2.DockStripGradient = dockPanelGradient5; 208 tabGradient10.EndColor = System.Drawing.SystemColors.ControlLight; 209 tabGradient10.StartColor = System.Drawing.SystemColors.ControlLight; 210 tabGradient10.TextColor = System.Drawing.SystemColors.ControlText; 211 dockPaneStripGradient2.InactiveTabGradient = tabGradient10; 212 dockPaneStripSkin2.DocumentGradient = dockPaneStripGradient2; 213 dockPaneStripSkin2.TextFont = new System.Drawing.Font("Segoe UI", 9F); 214 tabGradient11.EndColor = System.Drawing.SystemColors.ActiveCaption; 215 tabGradient11.LinearGradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; 216 tabGradient11.StartColor = System.Drawing.SystemColors.GradientActiveCaption; 217 tabGradient11.TextColor = System.Drawing.SystemColors.ActiveCaptionText; 218 dockPaneStripToolWindowGradient2.ActiveCaptionGradient = tabGradient11; 219 tabGradient12.EndColor = System.Drawing.SystemColors.Control; 220 tabGradient12.StartColor = System.Drawing.SystemColors.Control; 221 tabGradient12.TextColor = System.Drawing.SystemColors.ControlText; 222 dockPaneStripToolWindowGradient2.ActiveTabGradient = tabGradient12; 223 dockPanelGradient6.EndColor = System.Drawing.SystemColors.ControlLight; 224 dockPanelGradient6.StartColor = System.Drawing.SystemColors.ControlLight; 225 dockPaneStripToolWindowGradient2.DockStripGradient = dockPanelGradient6; 226 tabGradient13.EndColor = System.Drawing.SystemColors.InactiveCaption; 227 tabGradient13.LinearGradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; 228 tabGradient13.StartColor = System.Drawing.SystemColors.GradientInactiveCaption; 229 tabGradient13.TextColor = System.Drawing.SystemColors.InactiveCaptionText; 230 dockPaneStripToolWindowGradient2.InactiveCaptionGradient = tabGradient13; 231 tabGradient14.EndColor = System.Drawing.Color.Transparent; 232 tabGradient14.StartColor = System.Drawing.Color.Transparent; 233 tabGradient14.TextColor = System.Drawing.SystemColors.ControlDarkDark; 234 dockPaneStripToolWindowGradient2.InactiveTabGradient = tabGradient14; 235 dockPaneStripSkin2.ToolWindowGradient = dockPaneStripToolWindowGradient2; 236 dockPanelSkin2.DockPaneStripSkin = dockPaneStripSkin2; 237 this.resultsDockPanel.Skin = dockPanelSkin2; 230 238 this.resultsDockPanel.TabIndex = 0; 231 239 // … … 236 244 this.runsTabPage.Name = "runsTabPage"; 237 245 this.runsTabPage.Padding = new System.Windows.Forms.Padding(3); 238 this.runsTabPage.Size = new System.Drawing.Size( 841, 454);246 this.runsTabPage.Size = new System.Drawing.Size(548, 476); 239 247 this.runsTabPage.TabIndex = 4; 240 248 this.runsTabPage.Text = "Runs"; … … 249 257 this.runsView.Name = "runsView"; 250 258 this.runsView.ReadOnly = false; 251 this.runsView.Size = new System.Drawing.Size( 835, 448);259 this.runsView.Size = new System.Drawing.Size(542, 470); 252 260 this.runsView.TabIndex = 0; 253 261 // … … 258 266 this.seededRunsTabPage.Name = "seededRunsTabPage"; 259 267 this.seededRunsTabPage.Padding = new System.Windows.Forms.Padding(3); 260 this.seededRunsTabPage.Size = new System.Drawing.Size( 841, 454);268 this.seededRunsTabPage.Size = new System.Drawing.Size(548, 476); 261 269 this.seededRunsTabPage.TabIndex = 5; 262 270 this.seededRunsTabPage.Text = "Seeded Runs"; … … 271 279 this.seededRunsView.Name = "seededRunsView"; 272 280 this.seededRunsView.ReadOnly = false; 273 this.seededRunsView.Size = new System.Drawing.Size( 835, 448);281 this.seededRunsView.Size = new System.Drawing.Size(542, 470); 274 282 this.seededRunsView.TabIndex = 1; 275 283 // … … 279 287 this.solutionSeedingTabPage.Name = "solutionSeedingTabPage"; 280 288 this.solutionSeedingTabPage.Padding = new System.Windows.Forms.Padding(3); 281 this.solutionSeedingTabPage.Size = new System.Drawing.Size( 841, 454);289 this.solutionSeedingTabPage.Size = new System.Drawing.Size(548, 476); 282 290 this.solutionSeedingTabPage.TabIndex = 1; 283 291 this.solutionSeedingTabPage.Text = "Seeding Pool"; … … 290 298 this.parametersTabPage.Name = "parametersTabPage"; 291 299 this.parametersTabPage.Padding = new System.Windows.Forms.Padding(3); 292 this.parametersTabPage.Size = new System.Drawing.Size( 841, 454);300 this.parametersTabPage.Size = new System.Drawing.Size(548, 476); 293 301 this.parametersTabPage.TabIndex = 0; 294 302 this.parametersTabPage.Text = "Parameters"; … … 305 313 this.solverParametersView.ReadOnly = true; 306 314 this.solverParametersView.ShowDetails = true; 307 this.solverParametersView.Size = new System.Drawing.Size( 835, 448);315 this.solverParametersView.Size = new System.Drawing.Size(542, 470); 308 316 this.solverParametersView.TabIndex = 0; 309 317 // … … 314 322 this.operatorGraphTabPage.Name = "operatorGraphTabPage"; 315 323 this.operatorGraphTabPage.Padding = new System.Windows.Forms.Padding(3); 316 this.operatorGraphTabPage.Size = new System.Drawing.Size( 841, 454);324 this.operatorGraphTabPage.Size = new System.Drawing.Size(548, 476); 317 325 this.operatorGraphTabPage.TabIndex = 3; 318 326 this.operatorGraphTabPage.Text = "Operator Graph"; … … 328 336 this.operatorGraphViewHost.Name = "operatorGraphViewHost"; 329 337 this.operatorGraphViewHost.ReadOnly = true; 330 this.operatorGraphViewHost.Size = new System.Drawing.Size( 835, 448);338 this.operatorGraphViewHost.Size = new System.Drawing.Size(542, 470); 331 339 this.operatorGraphViewHost.TabIndex = 0; 332 340 this.operatorGraphViewHost.ViewsLabelVisible = true; … … 335 343 // algorithmStartButton 336 344 // 337 this.algorithmStartButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 338 this.algorithmStartButton.Location = new System.Drawing.Point(791, 55); 345 this.algorithmStartButton.Location = new System.Drawing.Point(91, 60); 339 346 this.algorithmStartButton.Name = "algorithmStartButton"; 340 347 this.algorithmStartButton.Size = new System.Drawing.Size(26, 23); … … 371 378 this.evaluationsLimitabel.Text = "Budget (FE):"; 372 379 // 373 // algorithmSuggestionLabel374 // 375 this. algorithmSuggestionLabel.AutoSize = true;376 this. algorithmSuggestionLabel.Location = new System.Drawing.Point(3, 59);377 this. algorithmSuggestionLabel.Name = "algorithmSuggestionLabel";378 this. algorithmSuggestionLabel.Size = new System.Drawing.Size(99, 13);379 this. algorithmSuggestionLabel.TabIndex = 9;380 this. algorithmSuggestionLabel.Text = "Suggested Solvers:";380 // recommenderLabel 381 // 382 this.recommenderLabel.AutoSize = true; 383 this.recommenderLabel.Location = new System.Drawing.Point(6, 9); 384 this.recommenderLabel.Name = "recommenderLabel"; 385 this.recommenderLabel.Size = new System.Drawing.Size(79, 13); 386 this.recommenderLabel.TabIndex = 9; 387 this.recommenderLabel.Text = "Recommender:"; 381 388 // 382 389 // suggestedInstancesComboBox … … 386 393 this.suggestedInstancesComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 387 394 this.suggestedInstancesComboBox.FormattingEnabled = true; 388 this.suggestedInstancesComboBox.Location = new System.Drawing.Point( 108, 56);395 this.suggestedInstancesComboBox.Location = new System.Drawing.Point(91, 33); 389 396 this.suggestedInstancesComboBox.Name = "suggestedInstancesComboBox"; 390 this.suggestedInstancesComboBox.Size = new System.Drawing.Size( 677, 21);397 this.suggestedInstancesComboBox.Size = new System.Drawing.Size(186, 21); 391 398 this.suggestedInstancesComboBox.TabIndex = 7; 392 399 this.suggestedInstancesComboBox.SelectedIndexChanged += new System.EventHandler(this.SuggestedInstancesComboBoxOnSelectedIndexChanged); 393 400 // 401 // recommenderComboBox 402 // 403 this.recommenderComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 404 | System.Windows.Forms.AnchorStyles.Right))); 405 this.recommenderComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 406 this.recommenderComboBox.FormattingEnabled = true; 407 this.recommenderComboBox.Location = new System.Drawing.Point(91, 6); 408 this.recommenderComboBox.Name = "recommenderComboBox"; 409 this.recommenderComboBox.Size = new System.Drawing.Size(154, 21); 410 this.recommenderComboBox.TabIndex = 7; 411 this.recommenderComboBox.SelectedIndexChanged += new System.EventHandler(this.RecommenderComboBoxOnSelectedIndexChanged); 412 // 413 // solverSplitContainer 414 // 415 this.solverSplitContainer.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 416 | System.Windows.Forms.AnchorStyles.Left) 417 | System.Windows.Forms.AnchorStyles.Right))); 418 this.solverSplitContainer.Location = new System.Drawing.Point(0, 56); 419 this.solverSplitContainer.Name = "solverSplitContainer"; 420 // 421 // solverSplitContainer.Panel1 422 // 423 this.solverSplitContainer.Panel1.Controls.Add(this.recommenderViewHost); 424 this.solverSplitContainer.Panel1.Controls.Add(this.instanceLabel); 425 this.solverSplitContainer.Panel1.Controls.Add(this.recommenderLabel); 426 this.solverSplitContainer.Panel1.Controls.Add(this.recommenderComboBox); 427 this.solverSplitContainer.Panel1.Controls.Add(this.algorithmCloneButton); 428 this.solverSplitContainer.Panel1.Controls.Add(this.suggestedInstancesComboBox); 429 this.solverSplitContainer.Panel1.Controls.Add(this.recommendRefreshButton); 430 this.solverSplitContainer.Panel1.Controls.Add(this.algorithmStartButton); 431 this.solverSplitContainer.Panel1.Padding = new System.Windows.Forms.Padding(3); 432 // 433 // solverSplitContainer.Panel2 434 // 435 this.solverSplitContainer.Panel2.Controls.Add(this.solverTabControl); 436 this.solverSplitContainer.Panel2.Padding = new System.Windows.Forms.Padding(3); 437 this.solverSplitContainer.Size = new System.Drawing.Size(849, 508); 438 this.solverSplitContainer.SplitterDistance = 283; 439 this.solverSplitContainer.TabIndex = 17; 440 // 441 // recommenderViewHost 442 // 443 this.recommenderViewHost.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 444 | System.Windows.Forms.AnchorStyles.Left) 445 | System.Windows.Forms.AnchorStyles.Right))); 446 this.recommenderViewHost.Caption = "View"; 447 this.recommenderViewHost.Content = null; 448 this.recommenderViewHost.Enabled = false; 449 this.recommenderViewHost.Location = new System.Drawing.Point(6, 89); 450 this.recommenderViewHost.Name = "recommenderViewHost"; 451 this.recommenderViewHost.ReadOnly = false; 452 this.recommenderViewHost.Size = new System.Drawing.Size(271, 412); 453 this.recommenderViewHost.TabIndex = 16; 454 this.recommenderViewHost.ViewsLabelVisible = true; 455 this.recommenderViewHost.ViewType = null; 456 // 457 // instanceLabel 458 // 459 this.instanceLabel.AutoSize = true; 460 this.instanceLabel.Location = new System.Drawing.Point(6, 36); 461 this.instanceLabel.Name = "instanceLabel"; 462 this.instanceLabel.Size = new System.Drawing.Size(51, 13); 463 this.instanceLabel.TabIndex = 9; 464 this.instanceLabel.Text = "Instance:"; 465 // 466 // recommendRefreshButton 467 // 468 this.recommendRefreshButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 469 this.recommendRefreshButton.Location = new System.Drawing.Point(251, 6); 470 this.recommendRefreshButton.Name = "recommendRefreshButton"; 471 this.recommendRefreshButton.Size = new System.Drawing.Size(26, 23); 472 this.recommendRefreshButton.TabIndex = 10; 473 this.recommendRefreshButton.Text = "Start"; 474 this.recommendRefreshButton.UseVisualStyleBackColor = true; 475 this.recommendRefreshButton.Click += new System.EventHandler(this.button1_Click); 476 // 394 477 // SolverView 395 478 // 396 479 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 397 480 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 481 this.Controls.Add(this.solverSplitContainer); 398 482 this.Controls.Add(this.minTargetView); 399 483 this.Controls.Add(this.maxEvaluationsView); 400 this.Controls.Add(this.algorithmCloneButton);401 484 this.Controls.Add(this.seedingStrategyPanel); 402 this.Controls.Add(this.solverTabControl);403 this.Controls.Add(this.algorithmStartButton);404 485 this.Controls.Add(this.minimumTargetLabel); 405 486 this.Controls.Add(this.seedingStrategyLabel); 406 487 this.Controls.Add(this.evaluationsLimitabel); 407 this.Controls.Add(this.algorithmSuggestionLabel);408 this.Controls.Add(this.suggestedInstancesComboBox);409 488 this.Name = "SolverView"; 410 489 this.Size = new System.Drawing.Size(849, 564); … … 416 495 this.parametersTabPage.ResumeLayout(false); 417 496 this.operatorGraphTabPage.ResumeLayout(false); 497 this.solverSplitContainer.Panel1.ResumeLayout(false); 498 this.solverSplitContainer.Panel1.PerformLayout(); 499 this.solverSplitContainer.Panel2.ResumeLayout(false); 500 ((System.ComponentModel.ISupportInitialize)(this.solverSplitContainer)).EndInit(); 501 this.solverSplitContainer.ResumeLayout(false); 418 502 this.ResumeLayout(false); 419 503 this.PerformLayout(); … … 434 518 private System.Windows.Forms.Label seedingStrategyLabel; 435 519 private System.Windows.Forms.Label evaluationsLimitabel; 436 private System.Windows.Forms.Label algorithmSuggestionLabel;520 private System.Windows.Forms.Label recommenderLabel; 437 521 private System.Windows.Forms.ComboBox suggestedInstancesComboBox; 438 522 private System.Windows.Forms.Button algorithmCloneButton; … … 446 530 private System.Windows.Forms.Label minimumTargetLabel; 447 531 private Data.Views.StringConvertibleValueView minTargetView; 532 private System.Windows.Forms.ComboBox recommenderComboBox; 533 private System.Windows.Forms.SplitContainer solverSplitContainer; 534 private MainForm.WindowsForms.ViewHost recommenderViewHost; 535 private System.Windows.Forms.Label instanceLabel; 536 private System.Windows.Forms.Button recommendRefreshButton; 448 537 } 449 538 } -
branches/PerformanceComparison/HeuristicLab.OptimizationExpertSystem/3.3/Views/SolverView.cs
r13759 r13774 44 44 algorithmCloneButton.Text = string.Empty; 45 45 algorithmCloneButton.Image = VSImageLibrary.Clone; 46 recommendRefreshButton.Text = string.Empty; 47 recommendRefreshButton.Image = VSImageLibrary.Refresh; 46 48 seedingStrategyView = new EnumValueView<SeedingStrategyTypes>() { 47 49 Dock = DockStyle.Fill … … 66 68 seedingStrategyView.Content = null; 67 69 seedingSolutionsView.Content = null; 70 recommenderViewHost.Content = null; 68 71 } else { 69 72 maxEvaluationsView.Content = Content.MaximumEvaluations; … … 73 76 seedingStrategyView.Content = Content.SeedingStrategy; 74 77 seedingSolutionsView.Content = Content.SolutionSeedingPool; 78 recommenderViewHost.Content = Content.AlgorithmInstanceRecommender; 75 79 } 76 80 } finally { SuppressEvents = false; } 77 81 UpdateSuggestedInstancesCombobox(); 82 UpdateRecommenderCombobox(); 78 83 } 79 84 … … 103 108 if (Content == null) return; 104 109 105 for (var i = 0; i < Content. SuggestedInstances.Count; i++) {106 suggestedInstancesComboBox.Items.Add(Content. SuggestedInstances[i]);107 if (prevSelection == null || Content. SuggestedInstances[i].Name == prevSelection.Name)110 for (var i = 0; i < Content.AlgorithmInstances.Count; i++) { 111 suggestedInstancesComboBox.Items.Add(Content.AlgorithmInstances[i]); 112 if (prevSelection == null || Content.AlgorithmInstances[i].Name == prevSelection.Name) 108 113 prevNewIndex = prevSelection == null ? 0 : i; 109 114 } 110 if (prevNewIndex >= 0) { 111 suggestedInstancesComboBox.SelectedIndex = prevNewIndex; 115 if (prevNewIndex >= 0) suggestedInstancesComboBox.SelectedIndex = prevNewIndex; 116 } 117 118 private void UpdateRecommenderCombobox() { 119 var prevSelection = Content.AlgorithmInstanceRecommender; 120 var prevNewIndex = -1; 121 recommenderComboBox.Items.Clear(); 122 if (Content == null) return; 123 124 /*var i = 0; 125 foreach (var type in ApplicationManager.Manager.GetTypes(typeof (IAlgorithmInstanceRecommender))) { 126 var r = (IAlgorithmInstanceRecommender)Activator.CreateInstance(type, BindingFlags.CreateInstance, Content); 127 recommenderComboBox.Items.Add(r); 128 if (prevSelection == null || type == prevSelection.GetType()) 129 prevNewIndex = prevSelection == null ? 0 : i; 130 i++; 112 131 } 132 if (prevNewIndex >= 0) recommenderComboBox.SelectedIndex = prevNewIndex;*/ 133 recommenderComboBox.Items.Add(new OverallBestRecommender(Content)); 134 if (prevSelection is OverallBestRecommender) recommenderComboBox.SelectedIndex = recommenderComboBox.Items.Count - 1; 135 recommenderComboBox.Items.Add(new KNearestNeighborRecommender(Content)); 136 if (prevSelection is KNearestNeighborRecommender) recommenderComboBox.SelectedIndex = recommenderComboBox.Items.Count - 1; 137 recommenderComboBox.Items.Add(new DistanceWeightedRecommender(Content)); 138 if (prevSelection is DistanceWeightedRecommender) recommenderComboBox.SelectedIndex = recommenderComboBox.Items.Count - 1; 113 139 } 114 140 … … 120 146 private void AlgorithmCloneButtonOnClick(object sender, EventArgs e) { 121 147 if (suggestedInstancesComboBox.SelectedIndex >= 0) 122 MainForm.ShowContent((IAlgorithm)Content. SuggestedInstances[suggestedInstancesComboBox.SelectedIndex].Clone());148 MainForm.ShowContent((IAlgorithm)Content.AlgorithmInstances[suggestedInstancesComboBox.SelectedIndex].Clone()); 123 149 } 124 150 … … 126 152 if (InvokeRequired) { Invoke((Action<object, EventArgs>)SuggestedInstancesComboBoxOnSelectedIndexChanged, sender, e); return; } 127 153 if (suggestedInstancesComboBox.SelectedIndex >= 0) { 128 var alg = Content. SuggestedInstances[suggestedInstancesComboBox.SelectedIndex];154 var alg = Content.AlgorithmInstances[suggestedInstancesComboBox.SelectedIndex]; 129 155 solverParametersView.Content = alg.Parameters; 130 156 var engineAlg = alg as EngineAlgorithm; … … 137 163 SetEnabledStateOfControls(); 138 164 } 165 166 private void RecommenderComboBoxOnSelectedIndexChanged(object sender, EventArgs e) { 167 if (InvokeRequired) { Invoke((Action<object, EventArgs>)RecommenderComboBoxOnSelectedIndexChanged, sender, e); return; } 168 if (recommenderComboBox.SelectedIndex < 0) return; 169 Content.AlgorithmInstanceRecommender = (IAlgorithmInstanceRecommender)recommenderComboBox.SelectedItem; 170 recommenderViewHost.Content = Content.AlgorithmInstanceRecommender; 171 Content.UpdateSuggestions(); 172 } 173 174 private void button1_Click(object sender, EventArgs e) { 175 Content.UpdateSuggestions(); 176 } 139 177 } 140 178 }
Note: See TracChangeset
for help on using the changeset viewer.