summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-09-28 16:24:59 -0300
committerGabriel Schneider <[email protected]>2026-10-01 00:12:15 -0300
commit7ce5d94b5d48b68c86d015060ebcabe63e299e1a (patch)
treeddfbe4e1ac160cbd780c28751b5421ceca648d39 /docs
parent3992e9def8692710590deacbc20bd925e0f8d64a (diff)
downloadpardes-7ce5d94b5d48b68c86d015060ebcabe63e299e1a.tar.gz
pardes-7ce5d94b5d48b68c86d015060ebcabe63e299e1a.zip
A selection holds up to 1024 ranges on the desktop, 64 on the board
The limit was 64 everywhere, which helix-golf's enumerate_and_align outgrows (%s |\d+ makes 121 ranges). It is now memory.limits.selections, per platform, and the counts that hold it are u16. The ranges stay inline in each Text, so a pane grows by about 80 KiB on the desktop (three texts and the regex prompt's snapshot); the Pane size budget in Terminal.zig moves from 128 to 160 KiB and says why. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'docs')
-rw-r--r--docs/helix-keys.md2
-rw-r--r--docs/selections.md8
2 files changed, 6 insertions, 4 deletions
diff --git a/docs/helix-keys.md b/docs/helix-keys.md
index 3d02893b..1c9e0763 100644
--- a/docs/helix-keys.md
+++ b/docs/helix-keys.md
@@ -276,7 +276,7 @@ keeps the matches it found so far.
| an all-lowercase pattern | matches case-blind | helix's smart-case. mvzr has no such flag, so the surface is lowercased instead (ASCII folding is byte-for-byte, so the offsets are identical) | helix-verified |
| `^` and `$` | hold at every line's start and end | helix compiles with `multi_line(true)`; pardes gets the same by searching each line as its own haystack (`src/regexp.zig`) | helix-verified |
| `.` | never matches a newline | as the Rust regex crate: a pattern without `\n` searches line by line, and one that names `\n` has its `.`s made `[^\n]` (`src/regexp.zig`) | helix-verified |
-| more than 64 matches | the ones past `MAX_SELS` are dropped | the ceiling the whole selection model has, not this key's |
+| many matches | up to `memory.limits.selections` ranges: 1024 on the desktop, 64 on the board; matches past it are dropped | helix has no limit. The ranges are held inline in every `Text` (about 20 KiB each on the desktop) | helix-verified up to the limit |
| `K` / `Alt-K` | keep / remove ranges matching a regex | **skipped**: the same prompt, filtering instead of splitting — worth adding next |
### `Ctrl-c` — toggle comments
diff --git a/docs/selections.md b/docs/selections.md
index 202ec3d9..59c4415b 100644
--- a/docs/selections.md
+++ b/docs/selections.md
@@ -10,7 +10,8 @@ at `694e7dfdd`, upstream `278b24389`.
Every `Text` (src/Text.zig) has its own: a pane's body, its tag, a prompt's
answer, a column's or the workspace's tag. A selection is one primary range
-plus up to 63 others.
+plus others, up to `memory.limits.selections` in all (1024 on the
+desktop, 64 on the board).
- The PRIMARY is where the cursor always was: `cur_row`/`cur_col` is the
head, `vsel.row`/`vsel.col` the anchor while `vsel.active`, and a bare
@@ -33,7 +34,7 @@ plus up to 63 others.
`Text.setRanges` is the one writer of a whole selection: it sorts by start,
merges ranges that overlap or share a start (helix `normalize`), follows the
-primary through the merges, and keeps the first 64. `setRange` writes one
+primary through the merges, and keeps the first `max_selections`. `setRange` writes one
range and drops the others.
## Making, splitting, merging, rotating, removing
@@ -107,7 +108,8 @@ the replay.
- Direction of a one-character range: both of its cells are the same cell,
so it has none. helix can flip one (`Alt-;`) and the commands that read
the head (`&`, the next extend) see the difference.
-- Count: at most 64 ranges; matches past that are dropped silently.
+- Count: at most `memory.limits.selections` ranges (1024 on the desktop, 64
+ on the board); matches past that are dropped silently.
- `n`/`N` walk the look ring (acme), not regex search hits, and there is no
`*`; helix-golf's `*`, `""N` and `n` do not apply.
- `s`/`S` match as sam does (docs/helix-keys.md, "Regex selection"): each