Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
12/01/21 10:43:00 (2 years ago)
Author:
dpiringe
Message:

#3136

  • set the default template to f(_) when loading a new problem data
  • fixed a bug which caused the drawing of uncolored SubFunctionTreeNodes after using the window splitter
  • implemented a method to paint nodes of SubFunctionTreeNode as colored nodes for ISymbolicDataAnalysisModel
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3136_Structural_GP/HeuristicLab.Problems.DataAnalysis.Symbolic.Views/3.4/GraphicalSymbolicDataAnalysisModelView.cs

    r17180 r18099  
    2020#endregion
    2121
     22using System.Drawing;
    2223using System.Windows.Forms;
    2324using HeuristicLab.MainForm;
     
    4041    protected override void OnContentChanged() {
    4142      base.OnContentChanged();
    42       symbolicExpressionTreeView.Content = null;
    43       if (Content != null)
    44         symbolicExpressionTreeView.Content = Content.SymbolicExpressionTree;
     43      symbolicExpressionTreeChart.Tree = null;
     44      if (Content != null) {
     45        symbolicExpressionTreeChart.Tree = Content.SymbolicExpressionTree;
     46        RepaintNodes();
     47      }
     48    }
     49
     50    protected void RepaintNodes() {
     51      var tree = symbolicExpressionTreeChart.Tree;
     52      if (tree != null) {
     53        foreach (var n in tree.IterateNodesPrefix()) {
     54          if (n.Symbol is SubFunctionSymbol) {
     55            var visualNode = symbolicExpressionTreeChart.GetVisualSymbolicExpressionTreeNode(n);
     56            visualNode.FillColor = Color.LightCyan;
     57            visualNode.LineColor = Color.SlateGray;
     58          }
     59        }
     60        symbolicExpressionTreeChart.RepaintNodes();
     61      }
    4562    }
    4663  }
Note: See TracChangeset for help on using the changeset viewer.