summaryrefslogtreecommitdiff
path: root/src/body_layer.zig
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-11-05 00:35:15 -0300
committerGabriel Schneider <[email protected]>2026-11-05 01:17:28 -0300
commitd5158f6a69ce5a1af6372c140b07379ee0ba2446 (patch)
treeec722719840f59263e4b7dbc740681594b526274 /src/body_layer.zig
parent3b31e0484bd06658f10cd9165b76cb1ca3b198bd (diff)
downloadpardes-d5158f6a69ce5a1af6372c140b07379ee0ba2446.tar.gz
pardes-d5158f6a69ce5a1af6372c140b07379ee0ba2446.zip
Text, edit, normal, look, Query and their readers: the second selection form msel (whole rows r0..r1, for search-result highlights) goes; a visited search result and a query preview's place line are an explicit vsel like any other, back from the line's end (to the result's location start, the line's start for ordinary path:line rows; to the start for a preview line), and every msel branch in the edit ops, the drawing, the terminal's position tracking and the chords goes (visible: the result's highlight covers its line's characters and newline cell instead of the whole row width, with the ordinary selection colours; y, d and c on it act on that range as after x, its newline included, so a yanked result pastes as a line); selections.md and the ; Alt-; X Alt-x rows of helix-keys.md no longer describe msel; Text's walked shape changes (wire semantics)
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
Diffstat (limited to 'src/body_layer.zig')
-rw-r--r--src/body_layer.zig17
1 files changed, 0 insertions, 17 deletions
diff --git a/src/body_layer.zig b/src/body_layer.zig
index 7b1be4f7..027dfffb 100644
--- a/src/body_layer.zig
+++ b/src/body_layer.zig
@@ -318,23 +318,6 @@ pub fn renderBody(p: *Pardes, s: *Surface, arena: std.mem.Allocator, pane: *Pane
if (b == pardes.sel_slot and @min(sl.r0, sl.r1) < pane.tag_rows) continue;
paintPointerSelection(p, s, pane, r, tx, tw, tag_y, body_y, sl, pane.tag_rows, sel_btn[b], buttonInks(th)[b]);
}
- // modal line selection (helix `x`): whole body rows, normal mode only
- if ((pane.body.mode == .normal or modal_hover) and pane.body.msel.active) {
- const hover_only = modal_hover and pane.body.mode != .normal;
- const modal_bg = if (hover_only)
- colors.mix(page_rgb, colors.mix(page_rgb, th.sel_bg))
- else
- th.sel_bg;
- const lo = @min(pane.body.msel.r0, pane.body.msel.r1);
- const hi = @max(pane.body.msel.r0, pane.body.msel.r1);
- var row: u16 = pane.tag_rows; // never paint the tag row
- while (row < body_bottom) : (row += 1) {
- const ar = pane.wrapAt(@as(i32, row) - @as(i32, pane.tag_rows)).line;
- if (ar < lo or ar > hi) continue;
- const col: u16 = if (pane.file != null) panes.File.gutterWidth(pane) else 0;
- if (col < tw) s.tint(tx + col, body_y + row - pane.tag_rows, tw - col, modal_bg, if (hover_only) null else th.sel_fg);
- }
- }
const preview = normal.selRegexArmed(pane) != null;
const show_prim = (pane.body.mode == .normal and pane.body.vsel.active) or preview or
(modal_hover and pane.body.vsel.active);