changelog

This commit is contained in:
Will McGugan
2023-02-13 12:11:54 +00:00
parent bf7f26b16a
commit 5e6690a5e8
3 changed files with 13 additions and 5 deletions

View File

@@ -19,14 +19,18 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- Added Shift+scroll wheel and ctrl+scroll wheel to scroll horizontally
- Added `Tree.action_toggle_node` to toggle a node without selecting, and bound it to <kbd>Space</kbd> https://github.com/Textualize/textual/issues/1433
- Added `Tree.reset` to fully reset a `Tree` https://github.com/Textualize/textual/issues/1437
- Added DOMNode.watch and DOMNode.is_attached methods https://github.com/Textualize/textual/pull/1750
- Added `DOMNode.watch` and `DOMNode.is_attached` methods https://github.com/Textualize/textual/pull/1750
- Added `DOMNode.css_tree` which is a renderable that shows the DOM and CSS https://github.com/Textualize/textual/pull/1778
- Added `DOMNode.children_view` which is a view on to a nodes children list, use for querying https://github.com/Textualize/textual/pull/1778
### Changed
- Breaking change: `TreeNode` can no longer be imported from `textual.widgets`; it is now available via `from textual.widgets.tree import TreeNode`. https://github.com/Textualize/textual/pull/1637
- `Tree` now shows a (subdued) cursor for a highlighted node when focus has moved elsewhere https://github.com/Textualize/textual/issues/1471
- Breaking change: renamed `Checkbox` to `Switch` https://github.com/Textualize/textual/issues/1746
- `App.install_screen` name is no longer optional
- `App.install_screen` name is no longer optional https://github.com/Textualize/textual/pull/1778
- `App.query` now only includes the current screen https://github.com/Textualize/textual/pull/1778
- `DOMNode.tree` now displays simple DOM structure only https://github.com/Textualize/textual/pull/1778
### Fixed

View File

@@ -1297,8 +1297,11 @@ class App(Generic[ReturnType], DOMNode):
self.log.system(f"{screen} INSTALLED name={name!r}")
def uninstall_screen(self, screen: Screen | str) -> str | None:
"""Uninstall a screen. If the screen was not previously installed then this
method is a null-op.
"""Uninstall a screen.
If the screen was not previously installed then this method is a null-op.
Uninstalling a screen allows Textual to delete it when it is popped or switched.
Note that you
Args:
screen: The screen to uninstall or the name of a installed screen.

View File

@@ -526,7 +526,8 @@ class DOMNode(MessagePump):
@property
def css_tree(self) -> Tree:
"""Get a Rich tree object which will recursively render the structure of the node tree.
"""Get a Rich tree object which will recursively render the structure of the node tree,
which also displays CSS and size information.
Returns:
A Rich object which may be printed.