Changeset 10885


Ignore:
Timestamp:
05/22/14 10:43:56 (5 years ago)
Author:
bburlacu
Message:

#2076: Fixed incorrect call to DrawNode which caused problems with emf export.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Encodings.SymbolicExpressionTreeEncoding.Views/3.4/SymbolicExpressionTreeChart.cs

    r10862 r10885  
    304304      //draw nodes and connections
    305305      foreach (var visualNode in visualNodes) {
    306         DrawTreeNode(visualNode);
     306        DrawTreeNode(graphics, visualNode);
    307307        var node = visualNode.Content;
    308308        foreach (var subtree in node.Subtrees) {
     
    317317          }
    318318        }
    319       }
    320     }
    321 
    322     protected void DrawTreeNode(VisualTreeNode<ISymbolicExpressionTreeNode> visualTreeNode) {
    323       using (var graphics = Graphics.FromImage(image)) {
    324         graphics.InterpolationMode = System.Drawing.Drawing2D.InterpolationMode.High;
    325         graphics.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.HighQuality;
    326         DrawTreeNode(graphics, visualTreeNode);
    327319      }
    328320    }
     
    404396    private void reingoldTilfordToolStripMenuItem_Click(object sender, EventArgs e) {
    405397      minHorizontalDistance = 30;
     398      minVerticalDistance = 30;
    406399      layoutEngine = new ReingoldTilfordLayoutEngine<ISymbolicExpressionTreeNode>(n => n.Subtrees) {
    407400        NodeWidth = preferredNodeWidth,
     
    416409
    417410    private void boxesToolStripMenuItem_Click(object sender, EventArgs e) {
    418       minHorizontalDistance = 5; 
     411      minHorizontalDistance = 5;
    419412      minVerticalDistance = 5;
    420413      layoutEngine = new BoxesLayoutEngine<ISymbolicExpressionTreeNode>(n => n.Subtrees, n => n.GetLength(), n => n.GetDepth()) {
Note: See TracChangeset for help on using the changeset viewer.