Commit Graph
124 Commits
Author SHA1 Message Date
Max Brunsfeld 5c7cea5a3e WIP - Navigate to prev/next search result 2022-01-28 14:00:00 -08:00
Max Brunsfeld 7e02d669e1 Add a simple unit test for find bar 2022-01-28 13:05:29 -08:00
Antonio ScandurraandNathan Sobo 5b9d791269 Implement regex search with multiline support
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-28 16:15:18 +01:00
Antonio Scandurra b980b11053 Implement whole word mode 2022-01-28 11:48:04 +01:00
Max BrunsfeldandNathan Sobo 34ed734749 Add highlighted_ranges API to editor
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-27 15:19:28 -08:00
Antonio Scandurra dbf48d2a5b Merge pull request #375 from zed-industries/more-project-diagnostics-styling
Last touches on project diagnostics for now
2022-01-27 16:47:05 +01:00
Antonio ScandurraandNathan Sobo 3853826f78 Pause cursor blinking only when editor is focused
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-27 16:33:47 +01:00
Antonio ScandurraandNathan Sobo 41ec4645ab Don't panic when ending transaction that wasn't started by the same editor
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-27 15:53:44 +01:00
Antonio ScandurraandNathan Sobo f055053fc9 Avoid grouping transactions created by different editors
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-27 15:51:46 +01:00
Max Brunsfeld 76bbd101c6 Increase diagnostic editor's vertical scroll margin
This way, the first path header will always be fully visible when
you move your cursor to the beginning of the multibuffer.
2022-01-26 10:23:41 -08:00
Max Brunsfeld c9b4bb78f2 Merge branch 'project-diagnostics-pinned-tab' into style-project-diagnostics 2022-01-25 12:20:37 -08:00
Max BrunsfeldandNathan Sobo 78b57e4d9d Scale diagnostic header and message text with editor font
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-25 12:10:11 -08:00
Nathan SoboandMax Brunsfeld 0c6fd157ee Scale diagnostic headers icons with editor font and right align w/ line numbers
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
2022-01-25 12:40:53 -07:00
Antonio ScandurraandNathan Sobo 7250974aa6 Style block decorations
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-25 17:07:12 +01:00
Antonio Scandurra 65d4c33c0e Format messages within backticks using bold instead of with a background 2022-01-25 15:50:49 +01:00
Antonio Scandurra 7e55353de8 Show error code in diagnostic header 2022-01-25 15:23:58 +01:00
Antonio Scandurra ec0ca2a1b6 Display icon next to primary message 2022-01-25 15:15:03 +01:00
Antonio Scandurra e7ec016350 Restyle diagnostic headers 2022-01-25 12:23:24 +01:00
Nathan Sobo 9505d6cdcf Disable the nav history when selecting a definition in a different buffer
When jumping between different buffers, we don't care about the cursor's previous location. When navigating backward, we want to jump directly to the site of the jump.
2022-01-20 21:33:16 -07:00
377e41a90f Make navigation history work with project diagnostics
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2022-01-20 18:21:48 +01:00
Antonio Scandurra c450945001 WIP 2022-01-20 18:11:37 +01:00
Antonio ScandurraandNathan Sobo fad5c98b8d Center selections when going to definition
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-20 17:33:07 +01:00
Antonio ScandurraandNathan Sobo b6685a532c Make "go to definition" work in project diagnostics
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-20 17:30:30 +01:00
Antonio ScandurraandNathan Sobo d92b40474f Change GoToDefinition binding to F12
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-20 15:43:02 +01:00
Antonio Scandurra 66734e11af WIP: Start on a GoToDefinition action for the editor 2022-01-20 12:26:04 +01:00
Max Brunsfeld f43dcd6763 Move logic for starting language servers to the project 2022-01-19 14:05:06 -08:00
Antonio Scandurra 18f1040c85 Rename Navigation to NavHistory 2022-01-19 15:27:34 +01:00
Max Brunsfeld 05bf8f61e2 Avoid changing selection in buffer navigation dialogs
If an editor has highlighted_rows, autoscroll it to reveal those rows instead of
its cursor positions.
2022-01-18 17:29:33 -08:00
Max Brunsfeld 926306582b Add a unit test for navigation behavior at the editor level 2022-01-18 16:25:22 -08:00
Max Brunsfeld f7326b8d74 Push to navigation history based on jump distance instead of time 2022-01-18 15:02:49 -08:00
Antonio Scandurra 16b82d59f1 Experiment with a more general way of pushing editor navigation entries 2022-01-18 18:03:10 +01:00
Antonio Scandurra bb954e29cf Introduce a test to verify navigation 2022-01-18 10:03:56 +01:00
Antonio Scandurra d5acbe1e32 Use offset to restore navigation position if anchor can't be resolved 2022-01-18 09:59:28 +01:00
Max Brunsfeld 11b7270f68 Navigate to previous positions in editors when using navigation history 2022-01-17 16:01:52 -08:00
Antonio Scandurra bbf634f439 Start laying the foundation for a per-pane navigation system 2022-01-17 16:59:06 +01:00
b7561c6cef Add select_first and select_last bindings to outline view
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-14 10:45:37 -08:00
Max BrunsfeldandAntonio Scandurra 373fe6fadf Change Editor::set_highlighted_row to take a row range
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
2022-01-13 09:49:46 -08:00
Antonio ScandurraandMax Brunsfeld 055d48cfb2 Select the closest outline item when the outline view's query is empty
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2022-01-13 18:43:49 +01:00
Max BrunsfeldandNathan Sobo 6865a42df9 Show error+warning counts in project diagnostics tab
Allow workspace items' tab contents to be arbitrary elements

Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-12 10:51:28 -08:00
Max Brunsfeld 9ccf2f3f58 Tweak theming of project diagnostics 2022-01-12 10:51:08 -08:00
Max Brunsfeld b5ee095da9 Deduplicate path names in the project diagnostics view 2022-01-12 10:51:08 -08:00
Antonio Scandurra 6fbbbab7ba Process selection anchors in a sorted fashion when refreshing them 2022-01-12 09:28:09 +01:00
Antonio Scandurra b768a3977c Add unit test reproducing a panic when refreshing selections 2022-01-12 09:27:03 +01:00
Antonio Scandurra 7daa4b5b04 Don't return a Result in test-only method select_display_ranges 2022-01-12 09:14:48 +01:00
c16820166b Fix cursor position when inserting newlines on a repeated excerpt
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2022-01-11 18:30:25 +01:00
Antonio ScandurraandNathan Sobo aa543a4b0a Ensure selections stay sorted after refreshing them
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-11 17:16:45 +01:00
Antonio Scandurra b1de9a945d Fix outdent not working when cursor is at column 0 2022-01-10 15:32:28 +01:00
Max Brunsfeld f933d54469 When selections lose their excerpts, move them to the next primary diagnostic 2022-01-07 14:53:33 -08:00
Antonio ScandurraandNathan Sobo e5c520a265 Use Buffer handles instead of MultiBuffer as editor workspace items
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-07 17:48:31 +01:00
Antonio ScandurraandNathan Sobo 794d214eee Refactor opening workspace items
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-07 17:38:37 +01:00