mirror of
https://github.com/nsnail/spectre.console.git
synced 2025-12-28 19:45:48 +08:00
Fix tree rendering
Fixes some tree rendering problems where lines were not properly drawn at some levels during some circumstances. * Change the API back to only allow one root. * Now uses a stack based approach to rendering instead of recursion. * Removes the need for measuring the whole tree in advance. Leave this up to each child to render.
This commit is contained in:
committed by
Patrik Svensson
parent
0e0f4b4220
commit
8261b25e5c
@@ -1,4 +1,4 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Spectre.Console
|
||||
{
|
||||
@@ -8,8 +8,8 @@ namespace Spectre.Console
|
||||
public interface IHasTreeNodes
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the children of this node.
|
||||
/// Gets the tree's child nodes.
|
||||
/// </summary>
|
||||
public List<TreeNode> Children { get; }
|
||||
List<TreeNode> Nodes { get; }
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user