github pazz/urwidtrees 1.1.0
v1.1.0

3 hours ago

urwidtrees 1.1.0

Requires Python 3.10 or later and urwid 2.1.2 or later (#79).

Changes in behaviour

  • TreeBox returns tree keys that have no effect (for example left on a top-level node, ] on the last sibling, - on a tree that cannot collapse), so that enclosing widgets such as urwid.Columns can use them (#87).
  • Each key reaches the focused row once; it used to be sent twice (#59).
  • C (collapse all) keeps the focus on the top-level node it was under instead of jumping to the first root (#97).
  • CollapsibleArrowTree shows the collapse icon on top-level nodes with children; other top-level lines are padded to match (#100).
  • Unknown or misspelt keyword arguments to the decorator classes raise TypeError (#99).
  • NestedTree.depth counts the levels inside subtrees, and its unused outmost parameter is gone (#64).
  • from urwidtrees import * imports only the public classes (#81).
  • DecoratedTree.root follows the wrapped tree (#76).
  • Decoration glyphs are measured by display width; a wide glyph on a narrow indent may now raise NoSpaceError (#75).

Fixes

  • Trees of any depth: navigation and ArrowTree no longer recurse per level (#82); nor does NestedTree per nesting level (#106).
  • SimpleTree.root and TreeListWalker follow changes to the tree (#102); ArrowTree draws nothing towards a trailing empty nested subtree (#104).
  • NestedTree: subtrees nested two or more levels deep, forest subtrees, empty subtrees, interpret_covered, depth, root, collapse calls and collapse_all/expand_all on wide trees, and decoration of continuation lines (#64, #67, #69, #70, #77, #88, #89, #90, #91, #61).
  • ArrowTree: bar characters given as None, missing connectors, childbar_offset on continuation lines (#71, #72, #73).
  • CollapsibleIndentedTree no longer raises NoSpaceError for leaves (#74); CollapsibleArrowTree with icon_offset (#62).
  • TreeBox: empty trees (#63), focus left on a hidden node after refresh() (#95), one redraw per collapse (#96).
  • TreeListWalker: one cache per walker, freed with it (#83); falsy positions as initial focus (#85).
  • SimpleTree with empty child lists (#60); Tree.parent_position signature (#65); collapse state with callables returning any truth value (#66).

Removed

  • The lru_cache backport module and the mock docs extra (#78, #84).

Documentation and internals

  • The documentation builds on Read the Docs again, from main (#111), and shows the real TreeBox and TreeListWalker signatures (#107).
  • Smaller internals in tree.py, decoration.py and NestedTree's collapse calls, with no change in behaviour (#108, #109, #110).

Full Changelog: 1.0.5...1.1.0

Don't miss a new urwidtrees release

NewReleases is sending notifications on new releases.