Commit Graph

155 Commits (4fd38f82a36f9874219b5169488133d97cc5e66c)

Author SHA1 Message Date
Benoît CORTIER 68affa3c59 Implement register selection
User can select register to yank into with the " command.
A new state is added to `Editor` and `commands::Context` structs.
This state is managed by leveraging a new struct `RegisterSelection`.
3 years ago
Blaž Hrastnik 14830e75ff Revert the line number rendering change, we were correct before 3 years ago
ahkrr e2d780f993 fix: 2 panics while setting style + off by 1
The panics would occur because set_style 
would draw outside of the the surface. 
Both occured using `find_prev` or `till_prev`
In my case the first panic! would appear
in a terminal with around 80 columns 
in helix/README.md going to the end of the file
with `geglf(`
the second with `geglfX`
The off by one fix ensures that `find_nth_prev` 
starts at the first character to the left
3 years ago
Wojciech Kępka 16b1cfa3be Add diagnostics keybindings 3 years ago
Kevin Sjöberg 3494bb8ef0 Refactor index assignment
Co-authored-by: Ivan Tham <pickfire@riseup.net>
3 years ago
Kevin Sjöberg a4ff8cdd8a Allow moving backwards in completions 3 years ago
Kevin Sjöberg 145bc1970a Trigger directory completion upon pressing Enter 3 years ago
Kevin Sjöberg aa8a8baeeb Calculate offset when moving picker cursor 3 years ago
Kevin Sjöberg 2ac496f919 Do not move past number of matches 3 years ago
ahkrr c5c3ec07f4 fix: panicked at 'attempt to subtract with overflow'
helix-term/src/ui/editor.rs:275:29
This would happen when the window-size was to small to display the entire width and one would start jumping forwards with f<some_char> and the beginning of the highlighted area would end up outside of the window
3 years ago
Kirawi c17dcb8633
Fixing Multiple Panics (#121)
* init

* wip

* wip
3 years ago
Blaž Hrastnik f2e554d761 matchbrackets: Needs to render with the viewport offset 3 years ago
Ivan Tham 29b9eed33c Fix panic paint mysterious matching pair
When the matching pair is out of bounds it still paints it causing an
out of bound panic. A dirty fix since it still have some issue, at least
it does not panic now.
3 years ago
Jan Hrastnik c1c3750d38 key is now modified in place at start of handle_event 3 years ago
Jan Hrastnik daad8ebe12 key_canonicalization now only matches chars 3 years ago
Jan Hrastnik 68abc67ec6 put the key canonicalization in a seperate function. only chars now get stripped of Shift modifier 3 years ago
Jan Hrastnik 712f25c2b9 removed shift matching 3 years ago
notoria c3a98b6a3e Highlight matching brackets 3 years ago
Blaž Hrastnik 661dbdca57 Fix cursor not showing on (0, 0) 3 years ago
Blaž Hrastnik c0332bd935 Fix split sizes getting out of sync with the terminal size, refs #69 3 years ago
Blaž Hrastnik a2147fc7d5 Change help prompt styling 3 years ago
Blaž Hrastnik 87d0617f3b Completion: Format docs tabs & highlight in the doc's native language 3 years ago
Blaž Hrastnik 3810650a6b Completion: Render non-markdown docs too 3 years ago
Blaž Hrastnik d54ae09d3b ESC should exit both completion and insert mode 3 years ago
Blaž Hrastnik d708efe275 Fix cursor positioning for prompts 3 years ago
Blaž Hrastnik 3336023614 ui: Menu rendering adjustments 3 years ago
Blaž Hrastnik 094203c74e Update deps, introduce the new tree-sitter lifetimes 3 years ago
Blaž Hrastnik b114cfa119 Display more data in completion popups. 3 years ago
Blaž Hrastnik 51d1d43289 Double the UI picker file limit. 3 years ago
Blaž Hrastnik 8949347e2c Completion: apply additionalTextEdits.
Used for adding imports to the file when completing.
3 years ago
Blaž Hrastnik fae2127a11 Drop cx.view_id, it was used before we had cx.current. 3 years ago
Blaž Hrastnik ccdebb99b5 Drop some useless imports. 3 years ago
Blaž Hrastnik ff4c1d05de Replace the Clear widget with buffer.clear/clear_with. 3 years ago
Blaž Hrastnik 1255bcb8a3 Simplify the compositor callback. 3 years ago
Blaž Hrastnik 0fe19ae472 clippy lint 3 years ago
Blaž Hrastnik d24844b73d ui: Render command mode doc text if available. 3 years ago
Blaž Hrastnik f0712479cb Define text color (mostly) in theme.toml. 3 years ago
Blaž Hrastnik f87dee926a Simplify prompt autocompletion rendering code. 3 years ago
Blaž Hrastnik ff84c8e394 Command mode: Per command completers. 3 years ago
Blaž Hrastnik 7c915dc065 Add the :new command, don't crash if saving without filename. 3 years ago
Blaž Hrastnik fd4fd12fa3 clippy lint 3 years ago
Blaž Hrastnik 355ad3cb82 Tokio migration. 3 years ago
Blaž Hrastnik 3038c2ef6d ui: Draft for completion doc preview. 3 years ago
Blaž Hrastnik d559199cec Stop crashing if last view is closed. 3 years ago
Blaž Hrastnik 28c167d71d doc: Be smarter about calculating modified status.
This way edit -> undo will properly show up as unmodified.
3 years ago
Blaž Hrastnik 3e5f24a9d5 lsp: support both utf-8 and utf-16 offsets.
Still need to implement the clangd encoding negotiation, but it's
a start. Should also manually override to utf8 for pyls.
3 years ago
Blaž Hrastnik 811f952a41 Center search results. 3 years ago
Blaž Hrastnik 7493d19098 Re-introduce clearing with bg color, seems the TUI issue was fixed. 3 years ago
Blaž Hrastnik 73f4abbb37 N as extend with search (for now, N should be search_prev). 3 years ago
Blaž Hrastnik 978f5114d8 Horizontal scrolling! It only took a year to get around to it. 3 years ago