6286d86
Set the correct dispatch action for the double-click handler for the pane tab bar (#9221)
Click to expand commit body
Fixes #9003
Release Notes:
- Fixed the double-click action on the terminal tab bar opening a new
buffer instead of a new terminal
([#9003](https://github.com/zed-industries/zed/issues/9003)).
Igal Tabachnik
created
fc9f844
Always stop propagation in div's scroll wheel listener (#9282)
Click to expand commit body
Fixes #9274
This fixes a bug that was preventing the editor hover popovers from
being scrolled with the trackpad.
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/9174
Release Notes:
- Fixed panics when `.git` was opened as a Zed worktree
([9174](https://github.com/zed-industries/zed/issues/9174))
Kirill Bulatov
created
572ba3f
Fall back to FindAllReferences if cmd-click did not preform GoToDefinition elsewhere (#9243)
Kirill Bulatov
created
427d669
gpui: Do not emit MouseUpEvent when exiting drag & drop (#9273)
Click to expand commit body
Fixes #9198
Release Notes:
- Fixed a bug where empty panes could be created during drag & drop.
Piotr Osiewicz
created
ac4bbb6
Correctly re-render mouse cursor when hovering over pane group divider (#9270)
Click to expand commit body
Before this change, the hitbox felt one-sided because the cursor didn't
consistently change into the drag-handle cursor.
The reason was that we didn't trigger a redraw on hover, so we'd only
change the cursor if we detected hover AND something else caused a
redraw.
Release Notes:
- Fixed the pane resize handler not consistently triggering on mouse
hover.
Co-authored-by: Antonio <antonio@zed.dev>
Thorsten Ball
and
Antonio
created
754df93
Fix segfault when dropping MacWindow (#9267)
Click to expand commit body
This avoids calling `window.setDelegate(nil)` when the window was
already closed.
Release Notes:
- Fixed a segfault that could show up when closing windows.
Co-authored-by: Antonio <antonio@zed.dev>
Thorsten Ball
and
Antonio
created
3c28282
Redraw when toggling between windows (#9236)
Click to expand commit body
Before this change we didn't consistently trigger focus events when
toggling between with windows `Cmd-backtick`. We only triggered them
when the OS decided to trigger a redraw.
That lead to a nasty bug that showed up in Vim mode where a cursor would
still be active in the hidden window, even though it was deactivated.
One then had to manually try to trigger a focus event in the new window
to activate the cursor.
With this change, we call `cx.refresh` when the window activation status
changed which triggers focus events consistently and fixes this bug.
With logging we can observe this:
**BEFORE**:
https://github.com/zed-industries/zed/assets/1185253/e1ad8878-129c-44ba-9d8b-c720f9dca5b6
**AFTER**:
https://github.com/zed-industries/zed/assets/1185253/733fdadb-d1ea-47fe-a2c1-7b50af299cc0
Release Notes:
- Fixed focus not being consistently changed when switching between
multiple Zed windows via `Cmd-backtick`.
---------
Co-authored-by: Manu Raj <git@manuraj.dev>
Co-authored-by: Antonio <antonio@zed.dev>
Switch to using `x11rb` crate instead of current `xcb` crate for gpui's
x11 platform.
Also fixes the crash on resize, and white flashing on resize.
Release Notes:
- N/A
---------
Co-authored-by: Mikayla Maki <mikayla@zed.dev>
Fixes #7400
Release Notes:
- Improved the `zed` command to not create files until you save them in
the editor ([#7400](https://github.com/zed-industries/zed/issues/7400)).
Conrad Irwin
created
e792c1a
Open new windows with a default size and position (#9204)
Click to expand commit body
This PR changes GPUI to open windows with a default size and location,
and to otherwise inherit from their spawning window.
Note: The linux build now crashes on startup.
Release Notes:
- N/A
---------
Co-authored-by: Nathan <nathan@zed.dev>
Co-authored-by: Ezekiel Warren <zaucy@users.noreply.github.com>
Mikayla Maki
,
Nathan
, and
Ezekiel Warren
created
9a2dcee
windows: Support dropping targets with filenames longer than 260 characters (#9115)
Click to expand commit body
use `Vec` instead of slice to support dynamic filename length.
Release Notes:
- N/A
张小白
created
fb83cf2
notification panel: rework time formatting (#8997)
Click to expand commit body
Follow up of #7994 to rework the notification panel timestamps.
This PR also includes some of the changes @evrsen proposed in #8996
Here is what it looks like now:
https://github.com/zed-industries/zed/assets/53836821/d85450e7-eab6-4fe7-bd11-1d76c0e87258
Release Notes:
- Reworked date time formatting in the chat and the notification panel
- Added hover style to notifications and hovering tooltip on timestamps
---------
Co-authored-by: Evren Sen <146845123+evrsen@users.noreply.github.com>
Release Notes:
- N/A
This prevents a crash on sway (on older versions without fractional
scaling). This means the resize is delayed until the next this we
present a frame, we need to investigate if this is the correct this to
do.
bbb651
created
aeb2a98
chore: Move new util deps to workspace level (#9250)
Click to expand commit body
I've missed a comment from @maxdeviant on #9247 before hitting merge;
mea culpa
Release Notes:
- N/A
Piotr Osiewicz
created
34f09ba
chore: Clean up util dependencies. (#9247)
Click to expand commit body
This allows this crate to start building sooner + it reduces our total
build graph size by 13 units (1104 -> 1091).
Release Notes:
- N.A
Piotr Osiewicz
created
c09fe1c
Do not allow concurrent FindAllReferences requests for the same multibuffer anchors (#9242)
Click to expand commit body
FindAllReferences LSP requests might take a long time to complete, and
currently Zed allows multiple requests spawned concurrently for the same
Anchor in the multi buffer. That results in multiple search results'
multi buffers appearing, sometimes at once, which is not what we want.
Part of https://github.com/zed-industries/zed/issues/5351 that helps to
reduce the amount of search results after clicks that did not resolve
instantly.
Release Notes:
- Improved FindAllReferences action by not allowing concurrent requests
for the same multi buffer source
Kirill Bulatov
created
64219ba
When fetching extensions from blob store, don't halt on invalid extensions. (#9241)
Click to expand commit body
This fixes an error where we were failing to sync extensions from the
blob store because of the presence of one invalid extensions
(`gentle-dark`), which was missing the `authors` field in its manifest.
Release Notes:
- N/A
Co-authored-by: Marshall <marshall@zed.dev>
Max Brunsfeld
and
Marshall
created
05dfe96
Add --add/--new to control CLI behaviour (#9202)
Click to expand commit body
When neither is specified, if you open a directory you get a new
workspace, otherwise files are added to your existing workspace.
With --new files are always opened in a new workspace
With --add directories are always added to an existing workspace
Fixes #9076
Fixes #4861
Fixes #5370
Release Notes:
- Added `-n/--new` and `-a/--add` to the zed CLI. When neither is
specified, if you open a directory you get a new workspace, otherwise
files are added to your existing workspace. With `--new` files are
always opened in a new workspace, with `--add` directories are always
added to an existing workspace.
([#9076](https://github.com/zed-industries/zed/issues/9096),
[#4861](https://github.com/zed-industries/zed/issues/4861),
[#5370](https://github.com/zed-industries/zed/issues/5370)).
Conrad Irwin
created
89c67fb
Fix typos in default `settings.json` (#9239)
Click to expand commit body
This PR fixes some typos in the comments within the default
`settings.json` file.
Fixes #4257.
Release Notes:
- Fixed some incorrect comments in the default `settings.json` file
([#4257](https://github.com/zed-industries/zed/issues/4257)).
Marshall Bowers
created
41d8ba1
Remove wezterm fork from dependencie (#8998)
Click to expand commit body
Improves build time by removing wezterm dependency
([#8604](https://github.com/zed-industries/zed/issues/8604)).
Release Notes:
- N/A
dalton-oliveira
created
e7289c3
Correctly show the `shift` icon for keybindings on macOS (#9235)
This fixes #8072 and #9061 by surfacing formatting errors in the
activity indicator.
It shows a message in the activity indicator if the last attempt
to format a buffer failed.
It only keeps track of the last attempt, so any further formatting
that succeeds will reset or update the error message.
I chose to only keep track of that, because everything else (keeping
track of formatting state per buffer, per project, per worktree) seems
complicated with little benefit, since we'd have to keep track of that
state, update it, clean it, etc.
We can still do that should we decide that we need to keep track
of the state on a per-buffer basis, but I think for now this is a
good, simple solution.
This also changes the `OpenLog` action to scroll to the end of the
buffer
and to not mark the buffer as dirty.
Release Notes:
- Added message to activity indicator if last attempt to format a buffer
failed. Message will get reset when next formatting succeeds. Clicking
on message opens log with more information.
([#8072](https://github.com/zed-industries/zed/issues/8072) and
[#9061](https://github.com/zed-industries/zed/issues/9061)).
- Changed `zed: Open Log` action to not mark the opened log file as
dirty and to always scroll to the bottom of the log.
https://github.com/zed-industries/zed/assets/1185253/951fb9ac-8b8b-483a-a46d-712e52878a4d
Thorsten Ball
created
39a0841
Center dock resize handle hitboxes (#9225)
Click to expand commit body
Also, add a `deferred` function which takes an element to paint after
the current element tree.
Release Notes:
- Improved the size and position of the hitbox for resizing left, right,
and bottom panels.
([#8855](https://github.com/zed-industries/zed/issues/8855))
Co-authored-by: Julia <julia@zed.dev>
Co-authored-by: Nathan <nathan@zed.dev>
Antonio Scandurra
,
Julia
, and
Nathan
created
409aa51
Fix mouse interactions with the project and branch switchers (#9222)
Click to expand commit body
Previously, we were considering the mouse to be "out" of a div when its
hitbox wasn't hovered. However, if a parent listened for
"mouse_down_out" and a child occluded the parent, the parent would
always think the mouse was out even when the user clicked the child.
This commit changes the definition of "mouse out" to simply mean "does
not contain the point", without accounting for occlusion.
Release Notes:
- N/A
Co-authored-by: Julia <julia@zed.dev>
Antonio Scandurra
and
Julia
created
d5796dc
Show only prefix/suffix if there are more than 12 breadcrumbs (#9220)
Click to expand commit body
Fixes https://github.com/zed-industries/zed/issues/9079
This should fix the arena panic we were observing. I saw that breadcrumb
rendering was on the stack trace for some of the panics, so my suspicion
is that it's being caused by some people navigating into deeply nested
files.
Release Notes:
- Fixed a panic that could occur when displaying too many breadcrumbs.
([#9079](https://github.com/zed-industries/zed/issues/9079))
Antonio Scandurra
created
9f39694
Improve error messages when fetching single GitHub release (#9219)
Click to expand commit body
Release Notes:
- N/A
Thorsten Ball
created
e103607
copilot: Track focus of modal + close modal on ESC (#9217)
Click to expand commit body
I've also made Copilot's modal regain focus whenever you click on it, as
otherwise there's nothing inside of it that can gain focus. Clicks do
not fall through a modal, which I think is nice.
Release Notes:
- Fixed the issue where pressing ESC (`menu::Cancel`) did not exit the
Copilot modal. Fixes #8852
Piotr Osiewicz
created
0a34126
Insert hitbox when an interactive element can be scrolled (#9216)

Release Notes:
- Added syntax highlighting to code blocks in markdown preview
- Fixed scroll position in markdown preview when editing a markdown file
(#9208)
Bennet Bo Fenner
created
e5bd9f1
Fix prettier plugins does not seem to be picked up (#9193)
Click to expand commit body
This fixed the issue that prettier plugins were not picked up. The old
code would always send an empty array to the prettier plugin that
happens inside the `prettier_server.js`.
**Before**
The `options.plugins` key is an empty array, which is not correct.
```log
stderr: Resolved config: {"singleQuote":true,"trailingComma":"all","plugins":["prettier-plugin-organize-imports"]}, will format file '/Users/remcosmits/Documents/code/prettier-test/src/app/page.tsx' with options: {"singleQuote":true,"trailingComma":"all","plugins":[],"parser":"typescript","path":"/Users/remcosmits/Documents/code/prettier-test/src/app/page.tsx"}
```
https://github.com/zed-industries/zed/assets/62463826/52f2aad0-2f96-43a9-81ec-9d4630c495b2
**After**
The `options.plugins` contains the `prettier-plugin-organize-imports`
plugin as expected.
```log
stderr: Resolved config: {"singleQuote":true,"trailingComma":"all","plugins":["prettier-plugin-organize-imports"]}, will format file '/Users/remcosmits/Documents/code/prettier-test/src/app/page.tsx' with options: {"singleQuote":true,"trailingComma":"all","plugins":["prettier-plugin-organize-imports"],"parser":"typescript","path":"/Users/remcosmits/Documents/code/prettier-test/src/app/page.tsx"}
```
https://github.com/zed-industries/zed/assets/62463826/9045028d-aeca-4df1-819c-01905d83216c
Release Notes:
- Fixed send plugins correctly to the prettier plugin
([#8841](https://github.com/zed-industries/zed/issues/8841)).
Remco Smits
created
98cf494
Fix broken ESLint by pinning to `2.2.20-Insiders` release (#9215)
Click to expand commit body
This fixes #9213 by pinning ESLint to `2.2.20-Insiders` which is the
last known version to work well with Zed.
Once this fix is out, we can take a closer look at upgrading to 2.4.x or
even 3.x once that's out of prerelease.
Release Notes:
- Fixed ESLint integration being broken after Mar 7 2024 due to ESLint
3.0.1 alpha release being pushed.
([#9213](https://github.com/zed-industries/zed/issues/9213)).
Thorsten Ball
created
3be1402
Fix the double click and update the default settings (#9214)
Kirill Bulatov
created
44adb0a
Detect URLs at beginning and end of buffer as well (#9212)
Click to expand commit body
Release Notes:
- Fixed URL detection at very beginning and very end of buffer
([#9210](https://github.com/zed-industries/zed/issues/9210)).
| Before | After |
| ------ | ----- |
| 
| 
|
Ivan Žužak
created
14a0d80
ui: Center `Checkbox` within its container (#9201)
Click to expand commit body
This PR fixes an issue with the `Checkbox` component where the checkbox
wasn't being centered within its container element.
The problem can be seen when applying a background color to the
container element:
#### Before
<img width="439" alt="Screenshot 2024-03-11 at 5 44 10 PM"
src="https://github.com/zed-industries/zed/assets/1486634/11704b1a-3c3e-4250-99c3-973fb442287a">
#### After
<img width="447" alt="Screenshot 2024-03-11 at 5 45 59 PM"
src="https://github.com/zed-industries/zed/assets/1486634/569a850b-4bd7-4711-8327-bf426fa5d265">
This resulted in issues where, under certain conditions, the checkbox
could get cut off, as seen in #8868.
Centering the checkbox fixes this issue:
<img width="305" alt="Screenshot 2024-03-11 at 5 51 00 PM"
src="https://github.com/zed-industries/zed/assets/1486634/14e5642f-59ad-4288-bc25-ea7da2a008a7">
Fixes #8868.
Release Notes:
- Fixed a positioning issue with checkboxes
([#8868](https://github.com/zed-industries/zed/issues/8868)).
This PR insets the headers within `ContextMenu`s to give them some more
breathing room.
#### Before
<img width="347" alt="Screenshot 2024-03-11 at 4 13 31 PM"
src="https://github.com/zed-industries/zed/assets/1486634/73a56d68-d40e-4396-b584-f443197b69d6">
#### After
<img width="354" alt="Screenshot 2024-03-11 at 4 12 43 PM"
src="https://github.com/zed-industries/zed/assets/1486634/44c12a07-0784-4c94-b194-245f5cf94b2b">
Release Notes:
- Added padding to headers in context menus.
Marshall Bowers
created
02dcdd0
Open excerpt on double click in multibuffer by default. (#9196)
Click to expand commit body
Closes https://github.com/zed-industries/zed/issues/5275
Double click with `alt` modifier pressed will do the regular word
selection.
Adds a setting to disable this behavior and instead select a word, as in
the regular buffer.
```
// What to do when multibuffer is double clicked in some of its excerpts
// (parts of singleton buffers).
// May take 2 values:
// 1. Behave as a regular buffer and select the whole word.
// "double_click_in_multibuffer": "select"
// 2. Open the excerpt clicked as a new buffer in the new tab (default).
// "double_click_in_multibuffer": "open",
// For the case of "open", regular selection behavior can be achieved by holding `alt` when double clicking.
"double_click_in_multibuffer": "open",
```
Release Notes:
- Made multibuffer to open excerpts in new tabs on double click by
default (changing settings or keeping alt restores the word selection
behavior). ([5275](https://github.com/zed-industries/zed/issues/5275))
Kirill Bulatov
created
25c471f
Render `+` separators for keybindings on non-macOS platforms (#9194)
Click to expand commit body
This PR adjusts the rendering of keybindings on non-macOS platforms to
have a `+` separator instead of just a blank space.
<img width="952" alt="Screenshot 2024-03-11 at 3 18 17 PM"
src="https://github.com/zed-industries/zed/assets/1486634/1573823d-4329-41f0-bef4-7a6c09f3e632">
<img width="584" alt="Screenshot 2024-03-11 at 3 16 25 PM"
src="https://github.com/zed-industries/zed/assets/1486634/aae41b22-dfde-40a6-9e0e-cee855522d3a">
Release Notes:
- N/A
Marshall Bowers
created
fe70a26
Fix relative glob patterns not working for language servers (#9179)
Click to expand commit body
If a language server would send us a glob pattern like `**/*.rb` or
`**/{package.json}` we'd end up ignoring it and never sending the
language server any notifications, because we try to `strip_prefix` the
projects absolute path from the pattern, BUT if that path is not in the
pattern, we'd return `None`.
This change fixes that.
Release Notes:
- Fixed language server glob patterns for file watching being ignored if
they were relative patterns.
Co-authored-by: Bennet <bennetbo@gmx.de>
Co-authored-by: Remco <djsmits12@gmail.com>
Thorsten Ball
,
Bennet
, and
Remco
created
b2981f4
Fix completion-filtering by checking actual word boundaries & reduce Ruby word chars (#9170)
Click to expand commit body
This fixes https://github.com/zed-industries/zed/issues/9069 by
1. reverting https://github.com/zed-industries/zed/issues/7819
2. fixing completion filtering with regards to word boudaries
For (2) see explanation in commit message:
> Previously, this would only split words on upper-lower boundaries or
> on `_`/`-`.
>
> The result was that we would filter out completions too aggressively.
> The filter works by taking a suggested completion, say `foo_bar_lol`,
split
> it up into words - `foo`, `bar, `lol` - and check whether any of the
words
> start with the same characters as what the user already typed: `fo`,
or `bar`,
> ...
>
> In the case of Ruby, though, `:` wasn't considered a word boundary. If
the
> LSP would return `:foobar` when the user typed `:foo`, we'd check if
there are
> any completions that match `foo` (because that's the current word) but
> we'd compare against `foobar`, not `:` or `:foobar`.
>
> With this change, we get more match candidates and thus more
completions in Ruby.
With that we can do (1) because we don't need these characters as word
characters anymore to trigger completions.
Release Notes:
- Fixed word boundaries in Ruby by restoring old behavior (`@`, `:`, ...
are no longer considered word characters)
([#9069](https://github.com/zed-industries/zed/issues/9069))
- Fixed completions being filtered out when they happened at word
boundaries on special characters (e.g. `:`)
---------
Co-authored-by: Max <max@zed.dev>
Thorsten Ball
and
Max
created
f2aa183
ui: Extend `KeyBinding` with support for displaying keybindings for other platforms (#9192)
Click to expand commit body
This PR extends the `KeyBinding` component with support for displaying
keybindings for platforms other than macOS.
<img width="824" alt="Screenshot 2024-03-11 at 2 41 59 PM"
src="https://github.com/zed-industries/zed/assets/1486634/7108b17d-dfc3-42ee-9bfd-c58b334d7374">
Release Notes:
- N/A
Marshall Bowers
created
dfcc143
Rename 'project_core' crate to 'worktree', make it just about worktrees (#9189)
Click to expand commit body
This is just a refactor. I noticed that we now have a `project_core`
crate, which mainly contains the `Worktree` type and its private
helpers, plus the project's settings.
In this PR, I've renamed that crate to `worktree` and did some minor
simplification to its module structure. I also extracted a new
`WorktreeSettings` settings type from the `ProjectSettings`, so that the
worktree settings could live in the worktree crate. This way, the crate
is now exclusively about worktree logic.
Release Notes:
- N/A
Max Brunsfeld
created
2b67bb2
Occlude only modal and not the space around it used to center it
Antonio Scandurra
created
91a0923
Fix a few regressions related to the flicker fix (#9190)
Click to expand commit body
This pull request fixes
https://github.com/zed-industries/zed/issues/9187 and fixes also ix a
rendering problem that would show cursors on the same plane:

Release Notes:
- N/A
Antonio Scandurra
created
b4ddc83
Allow overriding font style and weight via experimental.theme_overrides in settings (#9122)
Click to expand commit body
Release Notes:
- Added support for overriding the current theme's syntax font styles
and weights in settings
([#9121](https://github.com/zed-industries/zed/issues/9121)).
| Before | After |
| ------ | ----- |
| 
| 
|
Ivan Žužak
created
3bd9d14
linux: Fix panic missing screen mode for crtc specified mode ID (#9106)
Click to expand commit body
Fix panic caused by missing screen mode for specified crtc mode id #9105
by searching over all crtcs instead of using the first one which may be
invalid.
Fixes #9089.
On linux, pressing shift and tab together can potentially produce
`ISO_Left_Tab`. This PR maps this key to "tab" with the shift modifier,
similar to `SHIFT_TAB_KEY` in gpui::platform::mac::events.
Note: The [default linux
keymaps](https://github.com/zed-industries/zed/blob/main/assets/keymaps/default-linux.json)
have shift-tab mapped to editor::TabPrev and ctrl-[ mapped to
editor::Outdent. Both actions appear to have the same effect.
Release Notes:
- Support shift-tab on linux (#9089).