Skip to content

Commit

Permalink
Merge pull request #5054 from Textualize/one-line-tree
Browse files Browse the repository at this point in the history
One line tree fix, bump to 0.81.0
  • Loading branch information
willmcgugan authored Sep 25, 2024
2 parents 7be8a31 + 4390365 commit c75b169
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
6 changes: 4 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).

## Unreleased
## [0.81.0] - 2024-09-25

### Add
### Added

- Added `x_axis` and `y_axis` parameters to `Widget.scroll_to_region` https://github.com/Textualize/textual/pull/5047
- Added `Tree.move_cursor_to_line` https://github.com/Textualize/textual/pull/5052
Expand All @@ -21,6 +21,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).

- Fixed widgets occasionally not getting Resize events https://github.com/Textualize/textual/pull/5048
- Fixed tree regression https://github.com/Textualize/textual/pull/5052
- Fixed glitch with single line inline widget https://github.com/Textualize/textual/pull/5054

## [0.80.1] - 2024-09-24

Expand Down Expand Up @@ -2405,6 +2406,7 @@ https://textual.textualize.io/blog/2022/11/08/version-040/#version-040
- New handler system for messages that doesn't require inheritance
- Improved traceback handling

[0.81.0]: https://github.com/Textualize/textual/compare/v0.80.1...v0.81.0
[0.80.1]: https://github.com/Textualize/textual/compare/v0.80.0...v0.80.1
[0.80.0]: https://github.com/Textualize/textual/compare/v0.79.0...v0.80.0
[0.79.0]: https://github.com/Textualize/textual/compare/v0.78.0...v0.79.0
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "textual"
version = "0.80.1"
version = "0.81.0"
homepage = "https://github.com/Textualize/textual"
repository = "https://github.com/Textualize/textual"
documentation = "https://textual.textualize.io/"
Expand Down
4 changes: 3 additions & 1 deletion src/textual/_compositor.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,9 @@ def render_segments(self, console: Console) -> str:
if not last:
append("\n")
if self.clear:
append("\n\x1b[J") # Clear down
if len(self.strips) > 1:
append("\n")
append("\x1b[J") # Clear down
if len(self.strips) > 1:
back_lines = len(self.strips) if self.clear else len(self.strips) - 1
append(f"\x1b[{back_lines}A\r") # Move cursor back to original position
Expand Down

0 comments on commit c75b169

Please sign in to comment.