diff options
| author | Robin Gagnon <me@reobin.dev> | 2026-06-01 09:45:55 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-06-01 17:45:55 +0300 |
| commit | ab649adfded619a0461e36e2eb3929dd5f9e7567 (patch) | |
| tree | 438d1f20ebe73c309c78bb5822effb768476971f /src/app/state.rs | |
| parent | bd1d2f7cc5fece3fa91eadb55fb7e0a9f3331780 (diff) | |
fix: preserve linewise copy selection (#389)
refs #360
Co-authored-by: Can Celik <ogulcancelik@gmail.com>
Diffstat (limited to 'src/app/state.rs')
| -rw-r--r-- | src/app/state.rs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/app/state.rs b/src/app/state.rs index 1584bc19..d38699eb 100644 --- a/src/app/state.rs +++ b/src/app/state.rs @@ -813,7 +813,13 @@ pub(crate) struct CopyModeState { pub pane_id: PaneId, pub cursor_row: u16, pub cursor_col: u16, - pub selecting: bool, + pub selection: Option<CopyModeSelection>, +} + +#[derive(Debug, Clone, Copy, PartialEq, Eq)] +pub(crate) enum CopyModeSelection { + Character, + Linewise { anchor_row: u32 }, } #[derive(Debug, Clone, Copy, Default, PartialEq, Eq, serde::Serialize, serde::Deserialize)] |
