Ignore:
Timestamp:
03/07/14 16:23:41 (6 years ago)
Author:
mkommend
Message:

#2076: Simplified the API of the tree layout engines.

File:
1 edited

Legend:

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

    r10561 r10565  
    1 
    2 using System;
     1#region License Information
     2
     3/* HeuristicLab
     4 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     5 *
     6 * This file is part of HeuristicLab.
     7 *
     8 * HeuristicLab is free software: you can redistribute it and/or modify
     9 * it under the terms of the GNU General Public License as published by
     10 * the Free Software Foundation, either version 3 of the License, or
     11 * (at your option) any later version.
     12 *
     13 * HeuristicLab is distributed in the hope that it will be useful,
     14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
     15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     16 * GNU General Public License for more details.
     17 *
     18 * You should have received a copy of the GNU General Public License
     19 * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
     20 */
     21
     22#endregion
     23
    324using System.Collections.Generic;
    4 using System.Drawing;
    525
    626namespace HeuristicLab.Encodings.SymbolicExpressionTreeEncoding.Views {
     
    1131    int VerticalSpacing { get; set; }
    1232
    13     void CalculateLayout();
    14     void CalculateLayout(float width, float height);
    15     void Initialize(T root, Func<T, IEnumerable<T>> getChildren, Func<T, int> getLength = null, Func<T, int> getDepth = null);
    16     void Clear();
    17     void Reset();
    18 
    19     // function members necessary to navigate the tree structure
    20     Func<T, IEnumerable<T>> GetChildren { get; set; }
    21     Func<T, int> GetLength { get; set; }
    22     Func<T, int> GetDepth { get; set; }
    23 
    24     IEnumerable<T> GetContentNodes();
    25     IEnumerable<VisualTreeNode<T>> GetVisualNodes();
    26     Dictionary<T, PointF> GetCoordinates();
     33    IEnumerable<VisualTreeNode<T>> CalculateLayout(T root, float width, float height);
    2734  }
    2835}
Note: See TracChangeset for help on using the changeset viewer.