Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ 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/).

## [6.11.0] - 2025-12-18

### Added

- Added a `TextSelected` event. https://github.com/Textualize/textual/pull/6290

## [6.10.0] - 2025-12-16

### Fixed
Expand Down Expand Up @@ -3246,6 +3252,8 @@ 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

[6.11.0]: https://github.com/Textualize/textual/compare/v6.10.0...v6.11.0
[6.10.0]: https://github.com/Textualize/textual/compare/v6.9.0...v6.10.0
[6.9.0]: https://github.com/Textualize/textual/compare/v6.8.0...v6.9.0
[6.8.0]: https://github.com/Textualize/textual/compare/v6.7.1...v6.8.0
[6.7.1]: https://github.com/Textualize/textual/compare/v6.7.0...v6.7.1
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 = "6.10.0"
version = "6.11.0"
homepage = "https://github.com/Textualize/textual"
repository = "https://github.com/Textualize/textual"
documentation = "https://textual.textualize.io/"
Expand Down
4 changes: 4 additions & 0 deletions src/textual/events.py
Original file line number Diff line number Diff line change
Expand Up @@ -976,3 +976,7 @@ class DeliveryFailed(Event, bubble=False):

name: str | None = None
"""Optional name returned to the app to identify the download."""


class TextSelected(Event, bubble=True):
"""Sent from the screen when text is selected (Not Input and TextArea)"""
1 change: 1 addition & 0 deletions src/textual/screen.py
Original file line number Diff line number Diff line change
Expand Up @@ -1698,6 +1698,7 @@ def _forward_event(self, event: events.Event) -> None:
self.clear_selection()
self._mouse_down_offset = None
self._selecting = False
self.post_message(events.TextSelected())

elif isinstance(event, events.MouseDown) and not self.app.mouse_captured:
self._box_select = event.shift
Expand Down
Loading