diff options
| author | Polesznyák Márk <contact@pml68.dev> | 2025-10-21 17:34:52 +0200 |
|---|---|---|
| committer | Polesznyák Márk <contact@pml68.dev> | 2025-10-21 17:34:52 +0200 |
| commit | e49a19b923ef954ea1130ab6455c5e2c3f8ef426 (patch) | |
| tree | 54f639bbf69db2f4be61310f2a7684af6f10d940 /src | |
| parent | fix: `Selection::text` not accounting for graphemes larger than 1 byte (diff) | |
| download | iced_selection-e49a19b923ef954ea1130ab6455c5e2c3f8ef426.tar.gz | |
docs: list keyboard shortcuts under `text` module
Diffstat (limited to '')
| -rw-r--r-- | src/text.rs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/text.rs b/src/text.rs index 9957b5f..f911a39 100644 --- a/src/text.rs +++ b/src/text.rs @@ -1,4 +1,21 @@ //! Text widgets display information through writing. +//! +//! Keyboard shortcuts (applies to both [`Text`] and [`Rich`]): +//! +//! |MacOS|Linux/Windows|Effect| +//! |-|-|-| +//! |`Cmd + A`|`Ctrl + A`|Selects all text in the currently focused paragraph| +//! |`Cmd + C`|`Ctrl + C`|Copies the selected text to clipboard| +//! |`Shift + Left Arrow`|`Shift + Left Arrow`|Moves the selection to the left by one character| +//! |`Shift + Right Arrow`|`Shift + Right Arrow`|Moves the selection to the right by one character| +//! |`Shift + Opt + Left Arrow`|`Shift + Ctrl + Left Arrow`|Extends the selection to the previous start of a word| +//! |`Shift + Opt + Right Arrow`|`Shift + Ctrl + Right Arrow`|Extends the selection to the next end of a word| +//! |`Shift + Home`<br>`Shift + Cmd + Left Arrow`<br>`Shift + Opt + Up Arrow`|`Shift + Home`<br>`Shift + Ctrl + Up Arrow`|Selects to the beginning of the line| +//! |`Shift + End`<br>`Shift + Cmd + Right Arrow`<br>`Shift + Opt + Down Arrow`|`Shift + End`<br>`Shift + Ctrl + Down Arrow`|Selects to the end of the line| +//! |`Shift + Up Arrow`|`Shift + Up Arrow`|Moves the selection up by one line if possible, or to the start of the current line otherwise| +//! |`Shift + Down Arrow`|`Shift + Down Arrow`|Moves the selection down by one line if possible, or to the end of the current line otherwise| +//! |`Shift + Opt + Home`<br>`Shift + Cmd + Up Arrow`|`Shift + Ctrl + Home`|Selects to the beginning of the paragraph| +//! |`Shift + Opt + End`<br>`Shift + Cmd + Down Arrow`|`Shift + Ctrl + End`|Selects to the end of the paragraph| mod rich; use iced_widget::{ |
