Commit Graph
2301 Commits
Author SHA1 Message Date
Conrad Irwin f185aca25a Use the correct snapshot when calculating mouse positions 2024-01-24 19:10:53 -07:00
Conrad Irwin 4e085b2052 Show hovered cursors less flickerily 2024-01-23 22:32:22 -07:00
Conrad Irwin a3968c5cc5 Fix rendering of diagnostic blocks (#4232)
- Distinct colors to make it not confusing
- Avoid overflowing the edge of the editor when the message is long


Release Notes:

- Improved display of diagnostic blocks (F8)
2024-01-23 16:39:57 -07:00
Conrad Irwin 450cf9dd06 Fix rendering of diagnostic blocks
- Distinct colors to make it not confusing
- Avoid overflowing the edge of the editor when the message is long
2024-01-23 16:28:58 -07:00
Mikayla Maki 9f6072c6b6 Revert "Improve completion, action and shared project popovers' layout" 2024-01-23 15:26:11 -08:00
Kirill Bulatov bf35b78380 Allow both action and completion lists to occupy max width and height of its element 2024-01-23 22:42:06 +02:00
Kirill Bulatov 513ddf1861 Change background for the max width of the completion/action elements 2024-01-23 22:12:29 +02:00
Kirill Bulatov 4c039d0f02 Fix code actions being too small 2024-01-23 21:39:22 +02:00
Kirill BulatovandPiotr 74bdb48359 Make completions menu to occupy more space
* make completion elements as wide as the longest element
* make completion docs scrollable

co-authored-by: Piotr <piotr@zed.dev>
2024-01-23 21:26:40 +02:00
030b20ace9 Fix scroll jitter by ignoring autoscroll events if following
When following someone else we saw jitter because
`ScrollPositionChanged` events were battling `SelectionsChanged` events,
both of which were scrolling the viewport.

This ignores the ScrollPositionChanged if autoscrolling is on.

Co-authored-by: Antonio <antonio@zed.dev>
Co-authored-by: Julia <julia@zed.dev>
2024-01-23 16:16:21 +01:00
Thorsten BallandAntonio c8c605d23a Fix horizontal scroll going too far to the left
Previously one could scroll infinitely to the left. This clams it to 0.

Co-authored-by: Antonio <antonio@zed.dev>
2024-01-23 12:28:50 +01:00
Conrad Irwin ce0833eadf Fix off-by-one highlighting in hover tooltip (#4206)
rust analyzer has a tendency to return markdown of the form:

```rust
 // <-- note the leading space
blah blah blah
```

This is clearly defectuous, so we used to .trim() the output.

Unfortunately we trim after applying syntax highlighting, so that causes
the output to look goofy.

Fix this by updating the highlighting when we trim.

[[PR Description]]

Release Notes:

- Fixed a bug where syntax highlighting was off in hover tooltips
2024-01-22 23:12:08 -07:00
Julia f2eb78bbfc Avoid overwriting mouse wheel scroll with selection auto-scroll (#4207)
Release Notes:

- Fixed an issue where mouse wheel events could be ignored while
selecting text near the top or bottom of the editor with the mouse.
2024-01-22 19:07:03 -05:00
Julia a2aa47aba2 Avoid overwriting mouse wheel scroll with selection auto-scroll 2024-01-22 18:12:25 -05:00
Conrad Irwin fd8d2d41b0 One off 2024-01-22 15:53:12 -07:00
Conrad Irwin 98d514f5bf Fix off-by-one highlighting in hover tooltip
rust analyzer has a tendency to return markdown of the form:

```rust
 // <-- note the leading space
blah blah blah
```

This is clearly defectuous, so we used to .trim() the output.

Unfortunately we trim after applying syntax highlighting, so that causes
the output to look goofy.

Fix this by updating the highlighting when we trim.
2024-01-22 15:23:37 -07:00
Conrad Irwin 53b47c15ac Hide editor hovers when a menu is open 2024-01-22 13:33:13 -07:00
JuliaandNathan Sobo 2c3d9805a4 Store a z-index id per-layer
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2024-01-22 10:16:59 -05:00
Kirill Bulatov 7aa3d9d1fb Fix lightning bolt hover and git gutter mark overlapping 2024-01-22 16:01:32 +02:00
Antonio Scandurra f76a2502bb Show diagnostics on hover 2024-01-22 12:01:53 +01:00
Mikayla c05edee2b5 Port the rest of the app 2024-01-21 20:26:33 -08:00
Conrad Irwin 3b84291343 Updates to chat after Hack#2 (#4175)
Release Notes:

- Channels: Improved font sizes in chat
- Channels: Added a link preview when hovering over links in chat
- Channels: Fixed rendering of newlines in chat messages
- Added a new setting "use_autoclose" (defaulting to true) that lets you
disable autoclose per language.
([#1420](https://github.com/zed-industries/community/issues/1420))
([#1903](https://github.com/zed-industries/community/issues/1903))
2024-01-20 20:03:37 -07:00
Conrad Irwin 29ac1fd081 Merge remote-tracking branch 'origin/main' into chat-font-size 2024-01-20 14:51:53 -07:00
Conrad Irwin 778856c101 Add a setting "use_autoclose" to control autoclose
Also disable autoclose for Chat
2024-01-20 13:33:03 -07:00
Mikayla 33105486aa Make platform input handler private
Automatically record the context on non-view input handlers
Simplify the async window context update() method
2024-01-20 06:56:19 -08:00
Max Brunsfeld 0858db9ebb Autocomplete mentions (#4171)
Release Notes:

- Added autocomplete for @-mentions in the chat panel.
2024-01-19 17:03:56 -08:00
Max Brunsfeld 8fb0270b4a Make applying of additional completion edits go through the CompletionProvider 2024-01-19 16:56:28 -08:00
Max Brunsfeld 739d1179e3 Stop propagation when confirming a completion 2024-01-19 16:02:51 -08:00
Max Brunsfeld 4fb3e6d812 Ensure editors context menus get at least 3 lines of height 2024-01-19 15:47:42 -08:00
Mikayla eaa0e93112 Fix hover popovers showing up over zoomed panels 2024-01-19 14:52:49 -08:00
Conrad Irwin af30a9b814 Show cursors sligthly longer 2024-01-19 14:38:17 -07:00
139986d080 Start work on autocomplete for chat mentions
Co-authored-by: Conrad <conrad@zed.dev>
Co-authored-by: Nathan <nathan@zed.dev>
Co-authored-by: Marshall <marshall@zed.dev>
2024-01-19 13:12:57 -08:00
Max BrunsfeldandConrad 1ceccdf03b Move the details of completion-resolution logic into Project
Co-authored-by: Conrad <conrad@zed.dev>
2024-01-19 11:52:28 -08:00
Joseph T. Lyons 595428a8b1 Rename show cursors to display cursor names 2024-01-19 11:37:57 -05:00
Joseph T. Lyons cb1b7915ee Allow cursors to be shown via a command (#4153) 2024-01-19 11:09:49 -05:00
Joseph T. Lyons bcc13e151c Change struct field name 2024-01-19 07:52:28 -05:00
Kirill Bulatov a4a0a02dc3 Avoid gutter resizes on line number increase/decrease (#4135) 2024-01-19 10:25:55 +02:00
Joseph T. Lyons 0062cc000b Allow cursors to be shown via a command 2024-01-19 02:58:30 -05:00
Conrad Irwin 276032398b Fix overflow in hover handler 2024-01-18 16:53:05 -07:00
Conrad Irwin e513020fbb Fine tune 2024-01-18 15:59:13 -07:00
Kirill Bulatov bf8e57098d Avoid gutter resizes on line number increase/decrease
Reserves 4 characters for the line number in the gutter to avoid editor bounds jumping when editing small files like commit messages.
2024-01-18 23:11:05 +02:00
Conrad Irwin bfee008bb2 Merge branch 'main' into cursors 2024-01-18 14:03:27 -07:00
Piotr Osiewicz 9506fa461f Start documenting display_map module 2024-01-18 16:38:06 +01:00
Mikayla Maki 933fb87013 Fix editor selection issue (#4110)
Release Notes:

- Fixes a bug where, editor selections would update in the wrong pane
when split.
2024-01-17 17:16:56 -08:00
Mikayla Maki aa7351041d Add typo detection to CI (#4107)
Adding the typos crate to our CI will take some doing, as we have
several tests which rely on typos in various ways (e.g. checking state
as the user types), but I thought I'd take a first stab at fixing what
it finds.

Release Notes:

- N/A
2024-01-17 17:13:47 -08:00
Mikayla edb204511c Fix selection bug in editor causing selections to be un-ended 2024-01-17 16:30:01 -08:00
Mikayla 078fd35f4f WIP 2024-01-17 15:52:54 -08:00
Piotr OsiewiczandKirill 6cbc49e5f0 Editor docs (#4097)
Release Notes:

- N/A

---------

Co-authored-by: Kirill <kirill@zed.dev>
2024-01-18 00:48:37 +01:00
Mikayla 57400e9687 Fix typos detected by crate-ci/typos 2024-01-17 14:31:21 -08:00
Conrad Irwin ef0432da0d Hide cursors by default, but show some 2024-01-17 10:14:20 -07:00