Commit Graph
2003 Commits
Author SHA1 Message Date
Kirill Bulatov 81c64647e8 Fix the test 2023-08-26 03:00:53 +03:00
Kirill Bulatov e6c4802488 Properly clip request offsets 2023-08-26 02:54:50 +03:00
Kirill Bulatov b2b0918790 Consider padding during hint highlight range mapping 2023-08-26 02:45:08 +03:00
Kirill Bulatov 665d86ea73 Defer navigation target buffer opening 2023-08-26 02:45:08 +03:00
Kirill Bulatov ddd7ab116f Do not convert lsp::Location of hint labels before resolve 2023-08-26 02:45:08 +03:00
Max Brunsfeld d6ffb68305 Fix bugs in autoscroll with 'fit' strategy (#2893)
This fixes a bug where text moved up and down by one pixel in the buffer
search query editor, while typing.

Release  notes:
* Fixed a bug where editors didn't auto-scroll when typing if all
cursors could not fit within the viewport.
2023-08-25 16:36:33 -07:00
Piotr OsiewiczandJulia Risley 2495d6581e Un serialize project search (#2857)
This is the first batch of improvements to current project search. There
are few things we can do better still, but I want to get this out in
next Preview.
Most of the slowness at this point seems to stem from updating UI too
often.

Release Notes:
- Improved project search by making it report results sooner.

---------

Co-authored-by: Julia Risley <julia@zed.dev>
2023-08-26 01:31:52 +02:00
Max BrunsfeldandNathan a3b2c03b17 Fix bugs in autoscroll with 'fit' strategy
* Scroll to the newest cursor if all cursors can't fit in the viewport.
* Refuse to layout an editor less tall than one line height.

Co-authored-by: Nathan <nathan@zed.dev>
2023-08-25 16:13:12 -07:00
Conrad Irwin bde67b2b9c Fix merge-conflict 2023-08-25 11:59:16 -06:00
Conrad Irwin f18cdcba54 Fix relative line numbers in vim visual mode
In visual mode when your selection ends with a newline we show the
cursor at the end of the previous line (not the start of the current
line). We had only been accounting for this if the cursor was on-screen.
2023-08-25 11:50:41 -06:00
Conrad Irwin 8d5dc266a3 Fix relative line numbers when newest cursor offscreen 2023-08-25 11:50:41 -06:00
Conrad Irwinand 790aa5d476 Add relative_line_mode
Co-Authored-By: joseph@zed.dev
2023-08-25 11:50:41 -06:00
Max Brunsfeld 404f76739c Format let-else statements 2023-08-25 10:11:32 -07:00
Kirill Bulatov 44c340b5f2 Properly invalidate the hint cache 2023-08-25 17:33:17 +03:00
Kirill Bulatov 2b95f0580e Fix the tests 2023-08-25 16:25:43 +03:00
Kirill Bulatov c10c3e2b54 Only invalidate when doing first, visible range query 2023-08-25 15:16:55 +03:00
Kirill Bulatov a63e1571dc Defer querying inlay hints for invisible editor ranges
This way, only the visible part gets frequently queried on typing (and
hint /refresh requests that follow), with queries for invisible ranges
cancelled eagerly.
2023-08-25 15:16:55 +03:00
Kirill Bulatov 0a18aa694f Use stricter inlay range checks to avoid stuck highlights
Often, hint ranges are separated by a single '<` char as in
`Option<Vec<u32>>`. When moving the caret from left to right, avoid
inclusive ranges to faster update the matching hint underline.
2023-08-25 14:46:39 +03:00
Kirill Bulatov e44516cc6c Add hover tests 2023-08-25 14:26:17 +03:00
Kirill Bulatov f19c659ed6 Add link_go_to_definition test for inlays 2023-08-25 14:26:17 +03:00
Kirill Bulatov abd2d012b1 Properly binary search cached inlay hints 2023-08-25 14:26:17 +03:00
Kirill Bulatov 3c55c933d4 Be more lenient with hint resolution, always return some hint 2023-08-25 14:26:17 +03:00
Kirill Bulatov 852427e87b Use inlay highlights in randomized tests 2023-08-25 14:26:17 +03:00
Kirill Bulatov 7cd60d6afb Simplify and restore client resolve capabilities 2023-08-25 14:26:17 +03:00
Kirill Bulatov dcf570bb03 Fix resolve status conversion 2023-08-25 14:26:17 +03:00
Kirill Bulatov bcaff0a18a Propagate inlay background highlights to data storage 2023-08-25 14:26:17 +03:00
Kirill Bulatov 4b78678923 Prepare background highlights for inlay highlights 2023-08-25 14:26:17 +03:00
Kirill Bulatov 12ffbe54fb Unify text and inlay highlights 2023-08-25 14:26:17 +03:00
Kirill Bulatov 420f8b7b15 Prepare for inlay and text highlight unification 2023-08-25 14:26:17 +03:00
Kirill BulatovandAntonio 4cc9f2f525 Highlight inlay hint parts on cmd-hover
Co-Authored-By: Antonio <antonio@zed.dev>
2023-08-25 14:26:17 +03:00
Kirill Bulatov f8874a726c Attempt to highlight inlays 2023-08-25 14:26:17 +03:00
Kirill Bulatov 6c5761d05b Pass inlay highlight information 2023-08-25 14:26:17 +03:00
Kirill Bulatov 477fc865f5 Properly resolve inlay label parts' locations and buffers 2023-08-25 14:26:17 +03:00
Kirill Bulatov 7eab18ec89 Pass inlay go to definition data 2023-08-25 14:26:17 +03:00
Kirill Bulatov ac86bbac75 Prepare for hover functionality refactoring 2023-08-25 14:26:17 +03:00
Kirill Bulatov 80e8714241 Send inlay hint resolve requests 2023-08-25 14:26:17 +03:00
Kirill Bulatov 3434990b70 Store inlay hint resolve data 2023-08-25 14:26:17 +03:00
Kirill Bulatov d1cb0b3c27 Properly detect hovered inlay hint label part 2023-08-25 14:26:17 +03:00
Kirill Bulatov d34491e822 Draft inlay hint part hover detection 2023-08-25 14:26:17 +03:00
Max BrunsfeldandMikayla a95dcfa8bc Make channel notes view searchable and navigable via pane history
Co-authored-by: Mikayla <mikayla@zed.dev>
2023-08-24 17:18:18 -07:00
Max BrunsfeldandMikayla 24141c2f16 Ensure collaborators cursor colors are the same in channel buffers as in projects
Co-authored-by: Mikayla <mikayla@zed.dev>
2023-08-24 11:31:41 -07:00
Mikaylaandmax 199be8241c Add following into channel notes
co-authored-by: max <max@zed.dev>
2023-08-24 11:25:20 -07:00
Max BrunsfeldandMikayla 7e83138805 Start work on showing consistent replica ids for channel buffers
Co-authored-by: Mikayla <mikayla@zed.dev>
2023-08-23 18:37:01 -07:00
Nathan Sobo 1bc4f22373 Rework element system, phase 1 (#2881)
This is a deep cut. There's still more work to do until we start
building UI with this. I've approached this as additively as possible,
but I've made a few changes to the rest of the code that I think would
be good to upstream before proceeding too much further.

Most of the interesting pieces are in gpui/playground, which is a
standalone binary that opens a single window and renders a new kind of
element. The layout of these new elements is provided by the taffy
layout engine crate, which conforms to web conventions. The idea is that
playground is relatively cheap to build and work on. As concepts
coalesce in playground, we can drop them into gpui and start
transitioning.
2023-08-23 08:26:38 -06:00
Nathan Sobo d375f7992d Merge branch 'main' into divs 2023-08-22 16:35:56 -06:00
Conrad Irwin 27ba77b16f Ensure editor clipboard contains \n too 2023-08-22 13:52:04 -06:00
Conrad Irwin 33d7fe02ee Rewrite paste
- vim: support P for paste before
- vim: support P in visual mode for paste without overriding clipboard
- vim: fix position when using `p` on text copied outside zed
- vim: fix indentation when using `p` on text copied from zed
2023-08-22 13:27:57 -06:00
Piotr Osiewicz ccb3f6748c chore: fmt 2023-08-22 18:14:07 +02:00
Piotr OsiewiczandConrad Irwin ccb9b5d278 Query char_kind for completion triggers.
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
2023-08-22 18:12:05 +02:00
Piotr OsiewiczandJulia Risley d27cebd977 Z 2819 (#2872)
This PR adds new config option to language config called
`word_boundaries` that controls which characters should be recognised as
word boundary for a given language. This will improve our UX for
languages such as PHP and Tailwind.

Release Notes:

- Improved completions for PHP
[#1820](https://github.com/zed-industries/community/issues/1820)

---------

Co-authored-by: Julia Risley <julia@zed.dev>
2023-08-22 10:35:20 +02:00