aboutsummaryrefslogtreecommitdiff
path: root/helix-view
Commit message (Collapse)AuthorAge
...
* commands: Make no arg ':theme' show name (#3740)James O. D. Hunt2022-10-26
| | | | | | | | | | | | | | | | Most commands that accept an argument show their current value if no argument is specified. The `:theme` command previously displayed an error message in the status bar if not provided with an argument: ``` Theme name not provided ``` It now shows the current theme name in the status bar if no argument is specified. Signed-off-by: James O. D. Hunt <jamesodhunt@gmail.com> Signed-off-by: James O. D. Hunt <jamesodhunt@gmail.com>
* cargo fmtBlaž Hrastnik2022-10-21
|
* Autosave all when the terminal loses focus (#3178)Charlie Groves2022-10-21
| | | | | | | | | | | * Autosave all when the terminal loses focus * Correct comment on focus config Co-authored-by: Blaž Hrastnik <blaz@mxxn.io> * Need a block_try_flush_writes in all quit_all paths Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
* simplify encoding test macro (#4385)Kirawi2022-10-21
|
* Fix multi byte auto pairs (#4024)Skyler Hawthorne2022-10-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Fix test::print for Unicode The print function was not generating correct translations when the input has Unicode (non-ASCII) in it. This is due to its use of String::len, which gives the length in bytes, not chars. * Fix multi-code point auto pairs The current code for auto pairs is counting offsets by summing the length of the open and closing chars with char::len_utf8. Unfortunately, this gives back bytes, and the offset needs to be in chars. Additionally, it was discovered that there was a preexisting bug where the selection was not computed correctly in the case that the cursor was: 1. a single grapheme in width 2. this grapheme was more than one char 3. the direction of the cursor is backwards 4. a secondary range In this case, the offset was not being added into the anchor. This was fixed. * migrate auto pairs tests to integration * review comments
* feat(view): re-use align_view function (#4390)Matouš Dzivjak2022-10-20
|
* chore(view): remove indent_unit helper fn (#4389)Matouš Dzivjak2022-10-20
|
* Merge pull request #2267 from dead10ck/fix-write-failBlaž Hrastnik2022-10-20
|\ | | | | Write path fixes
| * reduce LSP timeout to 3sSkyler Hawthorne2022-10-19
| |
| * fail if doc save sender is closedSkyler Hawthorne2022-10-19
| |
| * Editor::flush_writes returns an errorSkyler Hawthorne2022-10-19
| |
| * doc.close() now unusedBlaž Hrastnik2022-10-19
| |
| * Wire up save_queue as a part of new_document rather than openBlaž Hrastnik2022-10-19
| |
| * Use a write_count to determine how many writes left to flushBlaž Hrastnik2022-10-19
| |
| * Deduplicate flush_writesBlaž Hrastnik2022-10-19
| |
| * Use a single save_queue on the editorBlaž Hrastnik2022-10-19
| |
| * review commentsSkyler Hawthorne2022-10-19
| |
| * remove Document::format_and_saveSkyler Hawthorne2022-10-19
| |
| * fix write scratch buffer to fileSkyler Hawthorne2022-10-19
| |
| * Save text in document saved events, use in status messageSkyler Hawthorne2022-10-19
| |
| * Rename doc save event names to past tenseSkyler Hawthorne2022-10-19
| |
| * fix erroneous write sender closeSkyler Hawthorne2022-10-19
| | | | | | | | | | | | This was not distinguishing the error types when trying a receive on an empty receiver, which was erroneously causing the sender to be closed when trying to flush the writes when there were none
| * increase LSP shutdown timeoutSkyler Hawthorne2022-10-19
| | | | | | | | The Clang LAP takes a long time to shut down on Windows
| * fix modified status with auto formatSkyler Hawthorne2022-10-19
| |
| * improve reliability of shutdownSkyler Hawthorne2022-10-19
| |
| * fix buffer-closeSkyler Hawthorne2022-10-19
| |
| * fix(write): do not set new path on document until write succeedsSkyler Hawthorne2022-10-19
| | | | | | | | | | | | If a document is written with a new path, currently, in the event that the write fails, the document still gets its path changed. This fixes it so that the path is not updated unless the write succeeds.
| * fix: buffer-close ensuring writesSkyler Hawthorne2022-10-19
| | | | | | | | Make sure buffer-close waits for the document to finish its writes.
| * chore(write): serialize write operations within a DocumentSkyler Hawthorne2022-10-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The way that document writes are handled are by submitting them to the async job pool, which are all executed opportunistically out of order. It was discovered that this can lead to write inconsistencies when there are multiple writes to the same file in quick succession. This seeks to fix this problem by removing document writes from the general pool of jobs and into its own specialized event. Now when a user submits a write with one of the write commands, a request is simply queued up in a new mpsc channel that each Document makes to handle its own writes. This way, if multiple writes are submitted on the same document, they are executed in order, while still allowing concurrent writes for different documents.
* | Merge pull request #4061 from pascalkuthe/undercurl-modifierBlaž Hrastnik2022-10-19
|\ \ | |/ |/| Support different kinds of underline rendering (updated)
| * merge underline-style and underline-color into a single tablePascal Kuthe2022-10-13
| |
| * adress review commentsPascal Kuthe2022-10-11
| |
| * make casing consistent with other configurationPascal Kuthe2022-10-06
| |
| * make underline_style a seperate optionPascal Kuthe2022-10-01
| | | | | | | | | | | | | | | | | | | | Underline styles are mutally exclusive and overwrite each other. Therefore implementing as an modifier lead to incorrect behaviour when the underline style is overwritten. For backwards compatability the "underline" modified is retained (but deprecated). Instead the "underline_style" and "underline_color" optios should be used to style underlines.
| * Fix failing testsA-Walrus2022-10-01
| | | | | | | | Add underline field to doctests, and fix bugs
| * Add separate color for underlinesA-Walrus2022-10-01
| |
| * Support different kinds of underline renderingGokul Soumya2022-10-01
| | | | | | | | | | | | | | | | | | Adds four new modifiers that can be used in themes: - undercurled - underdashed - underdotted - double-underline
* | Make skip_levels a u8A-Walrus2022-10-17
| |
* | Fix rendering of lines longer than 2^16A-Walrus2022-10-17
| | | | | | | | | | Before things would be cast to u16 earlier than needed, which would cause problems for insanely long lines (longer than 2^16 ~ 65 thousand)
* | feat(csharp,debug): add C# debugger support (#4213)Filip Dutescu2022-10-15
| |
* | Apply transactions to the jumplist for undo/redo (#4227)Michael Davis2022-10-12
| | | | | | | | | | Undo/redo/earlier/later call `Document::apply_impl` which applies transactions to the document. These transactions also need to be applied to the view as in 0aedef0.
* | fix: remove unneeded allocations when calling helix_view::Info::newAlexis (Poliorcetics) Bourget2022-10-11
| |
* | Add a helper function for applying transactionsMichael Davis2022-10-11
| | | | | | | | | | | | It is easy to forget to call `Document::apply` and/or `View::apply` in the correct order. This commit introduces a helper function which closes over both calls.
* | Apply transactions to ViewsMichael Davis2022-10-11
| | | | | | | | | | | | This change adds View::apply calls for all Document::apply call-sites, ensuring that changes to a document do not leave invalid entries in the View's jumplist.
* | Add View::apply for adjusting jumplist rangesMichael Davis2022-10-11
| | | | | | | | | | | | | | Applying a transaction to a View adjusts the ranges in the jumplist to ensure that they remain within the text of the document and follow regular selection invariants (for example, must be have a width of at least one).
* | Propagate idle timeout event to components (#3172)Gokul Soumya2022-10-11
| |
* | Fix goto/view center mismatch (#4135)Brandon Dong2022-10-10
| |
* | Add cursorcolumn (#4084)A-Walrus2022-10-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Implement cursorcolumn * Add documentation * Separate column style from line with fallback * Fallback to cursorcolumn first * Switch to non-fallback try_get_exact Add new function `try_get_exact`, which doesn't perform fallback, and use that instead because the fallback behaviour is being handled manually.
* | Automatically track pseudo-pending text (#4077)Michael Davis2022-10-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change automatically tracks pending text for for commands which use on-next-key callbacks. For example, `t` will await the next key event and "t" will be shown in the bottom right-hand corner to show that we're in a pending state. Previously, the text for these on-next-key commands needed to be hard-coded into the command definition which had some drawbacks: * It was easy to forget to write and clear the pending text. * If a command was remapped in a custom config, the pending text would still show the old key. With this change, pending text is automatically tracked based on the key events that lead to the command being executed. This works even when the command is remapped in config and when the on-next-key callback is nested under some key sequence (for example `mi`).
* | Change focus to modified docs on quit (#3872)A-Walrus2022-10-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Change focus to modified docs on quit When quitting with modified documents, automatically switch focus to one of them. * Update helix-term/src/commands/typed.rs Co-authored-by: Poliorcetics <poliorcetics@users.noreply.github.com> * Make it work with buffer-close-all and the like * Cleanup Use Cow instead of String, and rename DoesntExist -> DoesNotExist Co-authored-by: Poliorcetics <poliorcetics@users.noreply.github.com>