Auto pair deletions with selections (#15010) 45c7c6a1 parent 7b117bea

* Add Transaction::change_by_and_with_selection Adds `Transaction::change_by_and_with_selection` which centralizes logic for producing change sets with a potentially new selection that is applied incrementally, rather than all at once at the end with `with_selection`. It also centralizes the offset tracking logic so that the caller can construct a new selection with ranges as if they were operating on the text as-is. * backfill auto pair delete tests * Change auto pair hook to operate on single changes Change the auto pair hook to operate on single ranges to allow transactions that mix auto pair changes with other operations, such as inserting or deleting a single char, and denendting. * add delete_by_and_with_selection * Delete pairs with multi-char-range selections This completes auto pair deletions. Currently, auto pairs only get deleted when the range is a single grapheme wide, since otherwise, the selection would get computed incorrectly through the normal change mapping process. Now auto pairs get deleted even with larger ranges, and the resulting selection is correct. * insert double whitespace inside pair * account for overlapping deletes * fix as-is tests

authored by Skyler Hawthorne committed by GitHub

.cargo Add hook/event system 2 years ago
.github build(deps): bump cachix/cachix-action from 16 to 17
2 weeks ago
book docs: fix single quotes typo (#15520) 2 weeks ago
contrib feat: add language filtering to hx --health (#13484) 8 months ago
docs docs: fix contributing wording (#15452) 2 weeks ago
helix-core Auto pair deletions with selections (#15010)
2 weeks ago
helix-dap refactor(dap): drop request debug bound 3 weeks ago
helix-dap-types Fix dap request serialization and potential gutter underflow (#15017)
3 months ago
helix-event docs: fix cancellation typos in task controller comments (#15523)
2 weeks ago
helix-loader build(deps): bump the rust-dependencies group across 1 directory with 7 updates (#15518)
2 weeks ago
helix-lsp Improve docs and logging for lsp root selection (#15289) 3 weeks ago
helix-lsp-types build(deps): bump serde_json in the rust-dependencies group (#15084)
3 months ago
helix-parsec fix(clippy): clippy 1.83 lints (#12150) 1 year ago
helix-stdx build(deps): bump the rust-dependencies group with 4 updates (#15250) 2 months ago
helix-term Auto pair deletions with selections (#15010)
2 weeks ago
helix-tui Avoid OSC11/111 within tmux
3 weeks ago
helix-vcs build(deps): bump gix from 0.79.0 to 0.80.0 (#15364)
3 weeks ago
helix-view Emit OSC11 when previewing a theme, too (#15443)
3 weeks ago
runtime fix: handle Scala for-comprehension indentation in ERROR nodes (#15512)
2 weeks ago
xtask Rainbow tree-sitter matches 🌈 (#13530) 8 months ago
.envrc direnv: Watch changes to default.nix
1 year ago
.gitattributes Help Linguist identify Tree-sitter queries (#13436) 11 months ago
.gitignore fix: added .DS_Store to gitignore 1 year ago
CHANGELOG.md Add release notes for 25.07.1
8 months ago
Cargo.lock build(deps): bump the rust-dependencies group across 1 directory with 7 updates (#15518)
2 weeks ago
Cargo.toml build(deps): bump the rust-dependencies group across 1 directory with 7 updates (#15518)
2 weeks ago
LICENSE Add the LICENSE file. 4 years ago
README.md Remove skulpin mention from README.md (#15029) 3 months ago
base16_theme.toml base16_default: add styles to newer unthemed features (#10858)
1 year ago
default.nix fix: add runtimeDir as propagated build input (#14247) 7 months ago
flake.lock nix: Update flake lock 6 months ago
flake.nix flake: Remove darwin CoreFoundation dev-shell input
5 months ago
grammars.nix fix(nix): fix ill-defined escape warning in grammars.nix (#15370) 1 month ago
languages.toml Add buckconfig to ini language file-types (#15521)
2 weeks ago
logo.svg Reduce logo sizes even more (#9211)
2 years ago
logo_dark.svg Reduce logo sizes even more (#9211)
2 years ago
logo_light.svg Reduce logo sizes even more (#9211)
2 years ago
rust-toolchain.toml chore(msrv): bump from 1.82 to 1.87 (#15196)
2 months ago
rustfmt.toml Merge branch 'master' into great_line_ending_and_cursor_range_cleanup 4 years ago
screenshot.png update screenshot (#1879) 4 years ago
shell.nix build(nix): update flake deps, add default.nix file 3 years ago
theme.toml Allow theming directory prompt completions (#12205) 1 year ago

README.md

Helix

Build status GitHub Release Documentation GitHub contributors Matrix Space

Screenshot

A Kakoune / Neovim inspired editor, written in Rust.

The editing model is very heavily based on Kakoune; during development I found myself agreeing with most of Kakoune’s design decisions.

For more information, see the website or documentation.

All shortcuts/keymaps can be found in the documentation on the website.

Troubleshooting

Features

  • Vim-like modal editing
  • Multiple selections
  • Built-in language server support
  • Smart, incremental syntax highlighting and code editing via tree-sitter

Although it’s primarily a terminal-based editor, I am interested in exploring a custom renderer (similar to Emacs) using wgpu.

Note: Only certain languages have indentation definitions at the moment. Check runtime/queries/<lang>/ for indents.scm.

Installation

Installation documentation.

Packaging status

Contributing

Contributing guidelines can be found here.

Getting help

Your question might already be answered on the FAQ.

Discuss the project on the community Matrix Space (make sure to join #helix-editor:matrix.org if you’re on a client that doesn’t support Matrix Spaces yet).

Credits

Thanks to @jakenvac for designing the logo!