8152e06
Allow triggering preview and stable simultaneously (#11201)
Click to expand commit body
Release Notes: - N/A
Conrad Irwin created
8152e06
Allow triggering preview and stable simultaneously (#11201)
Release Notes: - N/A
Conrad Irwin created
62c12cd
Reduce frequency of workspace save (#11183)
Co-Authored-By: Mikayla <mikayla@zed.dev> Release Notes: - N/A --------- Co-authored-by: Mikayla <mikayla@zed.dev>
Conrad Irwin and Mikayla created
4fad96b
Add yss operation support for vim surrounds: (#11084)
The Motion::CurrentLine operation will contain the newline of the current line, so we need to deal with this edge case Release Notes: - N/A
Hans created
ad44237
Fix panic in SVG rendering (#11196)
Release Notes: - Fixed a panic in SVG rendering
Conrad Irwin created
bc73626
support vim replace command with range (#10709)
Release Notes: - Added support for line ranges in vim replace commands #9428 - not supporting anything other than bare line numbers right now - ~need to figure out how to show range in question in search bar~ @ConradIrwin implemented showing a highlight of the selected range for a short direction instead - ~tests lol~
Danny Hua created
0697b41
Hang diagnostics (#11190)
Release Notes: - Added diagnostics for main-thread hangs on macOS. These are only enabled if you've opted into diagnostics. --------- Co-authored-by: Mikayla <mikayla@zed.dev>
Conrad Irwin and Mikayla created
04cd8dd
assistant2: Add the ability to collapse chat messages (#11194)
This PR adds the ability to collapse/uncollapse chat messages. I think the spacing might be a little off with the collapsed calculations, so we'll need to look into that. https://github.com/zed-industries/zed/assets/1486634/4009c831-b44e-4b30-85ed-0266cb5b8a26 Release Notes: - N/A
Marshall Bowers created
ce643e6
Add Gentoo support to Linux dependency script (#11141)
This PR adds dependencies for Gentoo Linux. Release Notes: - N/A
shimataro created
6ab9c3c
x11: HiDPI support (#11140)
Fixes https://github.com/zed-industries/zed/issues/11121 Release Notes: - N/A
apricotbucket28 created
a765535
wayland: Implement cursor-shape-v1 (#11106)
Fixes wrong cursor icons and sizes on KDE 6 (and possibly other compositors) Gnome still doesn't support this protocol, so to fix cursor settings there we'll need to read `gsettings`. Before:  After:  Release Notes: - N/A
apricotbucket28 created
089ea78
assistant2: Use `ChatMessage` component to render chat messages (#11193)
This PR updates the new assistant panel to use the `ChatMessage` component to render its chat messages. This also lays the foundation for collapsing the messages, though that has yet to be wired up. Adapted from the work on the `assistant-chat-ui` branch. Release Notes: - N/A
Marshall Bowers created
ae65034
assistant2: Add headers to chat messages (#11191)
This PR adds headers to the chat messages in the new assistant panel. Adapted from the work on the `assistant-chat-ui` branch. Release Notes: - N/A
Marshall Bowers created
1c09b69
Pin message composer to the bottom of the new assistant panel (#11186)
Release Notes: - N/A --------- Co-authored-by: Marshall <marshall@zed.dev> Co-authored-by: Nate <nate@zed.dev> Co-authored-by: Kyle <kylek@zed.dev> Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
Max Brunsfeld , Marshall , Nate , Kyle , and Marshall Bowers created
f842d19
Remove extra space right of traffic lights on macOS (#11176)
This PR balances the left and right spacing around the traffic lights on macOS. Release Notes: - Minor UI changes to the titlebar
Nate Butler created
d633a0d
gpui: Fix `Global` trait (#11187)
This PR restores the `Global` trait's status as a marker trait. This was the original intent from #7095, when it was added, that had been lost in #9777. The purpose of the `Global` trait is to statically convey what types can and can't be accessed as `Global` state, as well as provide a way of restricting access to said globals. For example, in the case of the `ThemeRegistry` we have a private `GlobalThemeRegistry` that is marked as `Global`: https://github.com/zed-industries/zed/blob/91b3c24ed35d58438ae33970f07d1ff01d3acfc7/crates/theme/src/registry.rs#L25-L34 We're then able to permit reading the `ThemeRegistry` from the `GlobalThemeRegistry` via a custom getter, while still restricting which callers are able to mutate the global: https://github.com/zed-industries/zed/blob/91b3c24ed35d58438ae33970f07d1ff01d3acfc7/crates/theme/src/registry.rs#L46-L61 Release Notes: - N/A
Marshall Bowers created
91b3c24
editor: Clear diagnostics when folding a range that contains it (#11167)
Fixes #4659 Release Notes: - Fixed active diagnostic in editor showing up when it's line is in a folded range.
Piotr Osiewicz created
20625e9
preview tabs: Allow replacing preview tab when using code navigation (#10730)
This PR adds support for replacing the current preview tab when using GoToDefinition. Previously a tab, that was navigated away from, was converted into a permanent tab and the new tab was opened as preview. Without `enable_preview_from_code_navigation`: https://github.com/zed-industries/zed/assets/53836821/99840724-d6ff-4738-a9c4-ee71a0001634 With `enable_preview_from_code_navigation`: https://github.com/zed-industries/zed/assets/53836821/8c60efcb-d597-40bf-b08b-13faf5a289b6 Note: In the future I would like to improve support for the navigation history, because right now tabs that are not "normal" project items, e.g. FindAllReferences cannot be reopened Release Notes: - Added support for replacing the current preview tab when using code navigation (`enable_preview_from_code_navigation`)
Bennet Bo Fenner created
9ff8477
Register ESLint as an available language server (#11178)
This PR adds the ability for the ESLint language server (`eslint`) to be
controlled by the `language_servers` setting.
Now in your settings you can indicate that the ESLint language server
should be used for a given language, even if that language does not have
the ESLint language server registered for it already:
```json
{
"languages": {
"My Language": {
"language_servers": ["eslint", "..."]
}
}
}
```
Release Notes:
- N/A
Marshall Bowers created
ec95605
XI2 Smooth Scrolling for X11 - Attempt 2 (#11110)
This should have fixed the problems that some users were reporting with https://github.com/zed-industries/zed/pull/10695 . The problem was with devices which send more than one valuator axis in a single event whereas the original PR assumed there would only ever be one axis per event. This version also does away with the complicated device selection and instead just uses the master pointer device, which automatically uses all sub-pointers. Edit: Confirmed working for one of the user's which the first attempt was broken for. Release Notes: - Added smooth scrolling for X11 on Linux - Added horizontal scrolling for X11 on Linux
Owen Law created
ff8e7f9
Fix wayland keyrepeat: use modifier-independant keycode instead of keysym (#11095)
fix bug introduced by #11052 https://github.com/zed-industries/zed/pull/11052#issuecomment-2080475491 the keysym for `a` pressed with or without shift is different, so keyrepeat was never ended for `Shift-A`. Release Notes: - N/A
Jakob Hellermann created
2614215
wayland: Fix crash on wayfire (#11081)
It is a protocol violation to attach a buffer before acknowledging in xdg_surface::configure. Release Notes: - N/A
apricotbucket28 created
2386ae9
Set appid/wmclass for zed window (#10909)
fixes https://github.com/zed-industries/zed/issues/9132 By setting the app id, window managers like `sway` can apply custom configuration like `for_window [app_id="zed"] floating enable`. Tested using `wlprop`/`hyprctl activewindow` for wayland, `xprop` for x11. Release Notes: - Zed now sets the window app id / class, which can be used e.g. in window managers like `sway`/`i3` to define custom rules
Jakob Hellermann created
5674ba2
Validate buffer_id of anchors in is_valid (#11170)
Release Notes: - Fixes diagnostic panic better (follow up from #11066)
Conrad Irwin created
95118c6
Restore previous workspace on application resume (#10813)
Addresses #10812 Release Notes: - Launching an empty already-running Zed application now behaves like a regular startup and respects the user `resume_on_startup` setting. ([#10812](https://github.com/zed-industries/zed/issues/10812)). See attached showcase which highlights how the previous project can now be re-opened through both "quit" and "close window". This has a noticeable performance benefit on startup/project resume time. This should also make the behaviour of closing/opening an application consistent between macOS/Linux/Windows. https://github.com/zed-industries/zed/assets/22855292/9c37ba31-ce0a-4c3d-940d-a56e3347e64a
William Viktorsson created
35c3af7
gpui/mac: Disable shadows on non-opaque windows (#10896)
The culprit behind ghost images in transparent windows and bad performance with blurred windows turns out to be one and the same: window shadows. The simplest and most popular fix appears to be to simply disable shadows on non-opaque windows so let's just do that. Disabling shadows on a window that is already visible however leaves the shadow on screen, detached from the window, until a full screen effect such as exposé or a virtual desktop switch wipes it clean. There does not seem to be any known solution to this, and it does not affect windows created after switching to a transparent theme so this is a good enough compromise for now. Release Notes: - Fixed ghostly artifacts in transparent window backgrounds. - Fixed sluggishness with blurred window backgrounds.
jansol created
5ef7591
git: Do not log error if repository has no commits (#11163)
This is a follow-up to #10685 which started to hide these errors instead of displaying them to the user. But the errors are still noisy and not actionable, so we hide them instead. Release Notes: - Removed error message being logged when `git blame` is run in a repository without commits. Co-authored-by: Bennet <bennetbo@gmx.de>
Thorsten Ball and Bennet created
9746f4f
Fix relative line numbers (#11161)
Closes #11105 Release Notes: - Fixed rendering of relative line numbers in editor ([#11105](https://github.com/zed-industries/zed/issues/11105)). Co-authored-by: Thorsten <thorsten@zed.dev>
Bennet Bo Fenner and Thorsten created
9693e39
Remove unused fields (#11158)
Release Notes: - N/A
Thorsten Ball created
45d217f
Set destructive action only when prompt level is set to `Destructive` (#11154)
Oversight from #11015, where we added `PromptLevel::Destructive`, which should be used when a prompt performs a "destructive" action (e.g. deleting a file). However, we accidentally set `setHasDestructiveAction` to `true` regardless of which prompt level would be specified Release Notes: - N/A
Bennet Bo Fenner created
ca187c8
Allow users to configure ESLint's `rulesCustomizations` settings (#11135)
https://github.com/zed-industries/zed/assets/2072378/18f0bb28-0546-4234-a11f-39af6c9fcc12
`rulesCustomizations` is an array of rule severity overrides. Globs can
be used to apply default severities for multiple rules. See
[docs](https://github.com/microsoft/vscode-eslint/blob/553e632fb4cf073fce1549fb6c3c1b5140a52ebb/README.md?plain=1#L312-L333)
& [type
definitions](https://github.com/microsoft/vscode-eslint/blob/553e632fb4cf073fce1549fb6c3c1b5140a52ebb/%24shared/settings.ts#L168)
Example Zed `settings.json` to override all eslint errors to warnings:
```jsonc
{
"lsp": {
"eslint": {
"settings": {
"rulesCustomizations": [
// set all eslint errors/warnings to show as warnings
{ "rule": "*", "severity": "warn" }
]
}
}
}
}
```
Release Notes:
- Added support for configuring ESLint's `rulesCustomizations` settings,
ie. `{"lsp": {"eslint": {"settings": {"rulesCustomizations": [{"rule":
"*", "severity": "warn"}]}}}}`
William Villeneuve created
f72cf2a
Highlight reference types directive in TypeScript (#11039)
Before: <img width="443" alt="image" src="https://github.com/zed-industries/zed/assets/45585937/a8037edb-ed5b-4b12-92b4-2d409442ad4b"> After: <img width="429" alt="image" src="https://github.com/zed-industries/zed/assets/45585937/1fd66523-d667-4041-952f-c1125e7feab9"> Release Notes: - Add typescript reference types directive highlighted(#11001)
d1y created
8a79535
vim: Document jk (#11150)
Release Notes: - N/A
Thorsten Ball created
d4ec68b
Add hpp file icon (#11149)
Release Notes: - Added `.hpp` file icon.
Joseph T. Lyons created
c8a496e
Windows: Fix direct_write crash when clicking an empty line (#11117)
Windows platform direct_write using `LineLayout::default` indicates `font_size` will be 0. Zed crashed when click empty line. Release Notes: - N/A
CharlesChen0823 created
c826ad2
gpui: Improve the image example (#11111)
### fix cropping problem Prior to these changes the images were being cropped so you never actually saw the full image but you had to use your mouse to make the window bigger to see both the text and the images... ### activate ```rust cx.activate(true); ``` was not in place so the window did not appear when you ran the example ### No longer need to Ctrl-c to quit the example Now you can hit *Cmd-q* to quit out of the example instead of having to *Ctrl-c* in your terminal where you fired off the example Release Notes: - N/A
Michael Angerman created
f458f90
Fix bugs from recent PRs (#11147)
Fix missed delete in project panel Fix blinking scrollbar from selections-in-scrollbar change Release Notes: - N/A (nightly only)
Mikayla Maki created
39fb1d5
Incorporate ElementId as part of the Element::id trait method and expose GlobalId (#11101)
We're planning to associate "selection sources" with global element ids to allow arbitrary UI text to be selected in GPUI. Previously, global ids were not exposed outside the framework and we entangled management of the element id stack with element state access. This was more acceptable when element state was the only place we used global element ids, but now that we're planning to use them more places, it makes sense to deal with element identity as a first-class part of the element system. We now ensure that the stack of element ids which forms the current global element id is correctly managed in every phase of element layout and paint and make the global id available to each element method. In a subsequent PR, we'll use the global element id as part of implementing arbitrary selection for UI text. Release Notes: - N/A --------- Co-authored-by: Antonio Scandurra <me@as-cii.com>
Nathan Sobo and Antonio Scandurra created
8b55494
Properly register new icons (#11132)
This PR fixes some issues with the icons added in #11116, where they weren't being registered properly. Release Notes: - N/A
Marshall Bowers created
32e6424
Icons for js, c, cc, h, jsx, and tsx file types (#11116)
Release Notes: Add Icons for react (jsx/tsx), C, and C++ files  Release Notes: - Added icons for JS, React, C, and C++
Derek Briggs created
d2569af
Switch from delete file by default to trash file by default (#10875)
TODO:
- [x] Don't immediately seg fault
- [x] Implement for directories
- [x] Add cmd-delete to remove files
- [ ] ~~Add setting for trash vs. delete~~ You can just use keybindings
to change the behavior.
fixes https://github.com/zed-industries/zed/issues/7228
fixes https://github.com/zed-industries/zed/issues/5094
Release Notes:
- Added a new `project_panel::Trash` action and changed the default
behavior for `backspace` and `delete` in the project panel to send a
file to the systems trash, instead of permanently deleting it
([#7228](https://github.com/zed-industries/zed/issues/7228),
[#5094](https://github.com/zed-industries/zed/issues/5094)). The
original behavior can be restored by adding the following section to
your keybindings:
```json5
[
// ...Other keybindings...
{
"context": "ProjectPanel",
"bindings": {
"backspace": "project_panel::Delete",
"delete": "project_panel::Delete",
}
}
]
Mikayla Maki created
5dbd23f
vim: add keybinding to jump to parent directory in project panel (#11078)
Release Notes: - vim: Support `-` to go to `parent directory` of the project panel. As mentioned in the comments of #11073 this adds support for netrw's `-` to go to the parent directory in the project panel. Again tested on linux only. - N/A
blufony created
b7d9aeb
Semantic index progress (#11071)
Release Notes: - N/A --------- Co-authored-by: Antonio Scandurra <me@as-cii.com> Co-authored-by: Kyle <kylek@zed.dev> Co-authored-by: Marshall <marshall@zed.dev> Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
Max Brunsfeld , Antonio Scandurra , Kyle , Marshall , and Marshall Bowers created
1aa9c86
Scrollbar markers for cursors (#10816)
How it looks:
https://github.com/zed-industries/zed/assets/2101250/f564111c-1019-4442-b8a6-de338e12b12e
This PR adds cursor markers to the scrollbar. They work similar to
VSCode:
1. A cursor marker takes the whole scrollbar width.
2. It's always 2px high.
3. It uses the player's `cursor` color, so it may be helpful in the
collaboration mode.
There's a setting to switch cursor markers on/off:
```json
{
"scrollbar": {
"cursors": true
}
}
```
Implementation details:
- Unlike other markers, cursor markers are displayed synchronously.
Otherwise they don't feel smooth and sometimes freez on prolonged
up/down navigation.
- Cursor markers are automatically switched off when it's more than 100
of them.
- The minimum (non-cursor) marker height is now 5px. It allows the user
to see other markers under the cursor marker.
- The way the minimum height is imposed on markers has changed a bit to
keep consistency between markers of different types.
- Selected symbol markers use less vibrant color (`info` faded out a
little).
Release Notes:
- Added displaying of cursor markers in the scrollbar. They can be
switched on/off by the `scrollbar.cursors` setting.
Andrew Lygin created
848bb97
release notes vN (#11077)
Make it more likely the draft release notes work... Release Notes: - N/A
Conrad Irwin created
8e925bf
Don't panic when a tree-sitter parse fails (#11076)
Fixes https://zed-industries.slack.com/archives/C04S6T1T7TQ/p1714162894982749 Release Notes: * Fixed a crash that could happen if an error occurred in a parser provided by an extension. Co-authored-by: Conrad <conrad@zed.dev>
Max Brunsfeld and Conrad created
adcaa21
Add keybindings to jump to first / last file in project panel (#11073)
Release Notes:
- vim: Support `g g`/`G` to go to top/bottom of the project panel.
In vim type environments i usually expect to be able to jump to the top
and bottom and i was confused as to why that wasn't possible in the
project panel. So i added it. If anyone using different keymaps also
thinks this might be useful i would be happy to add other defaults. I
think for vim mode it is the most useful though, because you tend to not
use your mouse in vim mode.
This is my first contribution to any rust project, but it seemed like a
good starting point.
The function select_last() is inspired by select_first.
I was also thinking about adding a bigger jump keybinding, that would
jump for example 5 entries up / down, with vim default keybindings "{" /
"}".
FYI: I tested this on linux only and don't have access to any macos
machines.
- N/A
blufony created
393b16d
Fix Wayland keyrepeat getting cancelled by unrelated keyup (#11052)
fixes #11048 ## Problem in the situation `press right`, `press left`, `release right` the following happens right now: - `keypressed right`, `current_keysym` is set to `right` - `keypressed left`, `current_keysym` is set to `left` the repeat timer runs asynchronously and emits keyrepeats since `current_keysym.is_some()` - `keyreleased right`, `current_keysym` is set to None the repeat timer no longer emits keyrepeats - `keyreleased left`, this is where `current_keysym` should actually be set to None. ## Solution Only reset `current_keysym` if the released key matches the last pressed key. Release Notes: - N/A
Jakob Hellermann created
7bd18fa
Sync maximized state from top-level configure event for a wayland window (#11003)
* Otherwise is_maximized always returns `true`
Release Notes:
- Fixed maximized state. Tested with a dummy maximize/restore button
with the `zoom()` (not implemented yet). Without the right `maximized`,
in toggle zoom function is not possible to call `set_maximized()` or
`unset_maximized()`.
```rust
fn zoom(&self) {
if self.is_maximized() {
self.borrow_mut().toplevel.unset_maximized();
} else {
self.borrow_mut().toplevel.set_maximized();
}
}
```
Akilan Elango created
11dc3c2
windows: Support all `OpenType` font features (#10756)
Release Notes: - Added support for all `OpenType` font features to DirectWrite. https://github.com/zed-industries/zed/assets/14981363/cb2848cd-9178-4d87-881a-54dc646b2b61 --------- Co-authored-by: Mikayla Maki <mikayla@zed.dev>
张小白 and Mikayla Maki created
268cb94
windows: Move manifest file to `gpui` (#11036)
This is a follow up of #10810 , `embed-resource` crate uses a different method to link the manifest file, so this makes moving manifest file to `gpui` possible. Now, examples can run as expected:  TODO: - [ ] check if it builds with gnu toolchain Release Notes: - N/A
张小白 created