This PR fixes copying code blocks in the docs.
The problem was that some of the elements we removed from the base
mdBook template were causing errors in the script, which prevented the
right event listeners from being registered for the copy button.
To remedy this, the elements have been restored, but are using `display:
none` so that they don't appear in the UI.
Resolves#11592.
Release Notes:
- N/A
This PR updates the root path used by Copilot to be a validate path when
running on Windows.
Release Notes:
- N/A
Co-authored-by: Jason Lee <huacnlee@gmail.com>
A minor thing I've spotted and decided to fix on the spot.
It was being cloned twice within the body of that function (one of which
was redundant even without this PR); now in most cases we go down from 2
clones to 0.
Release Notes:
- N/A
This pull request introduces a new `markdown` crate which is capable of
parsing and rendering a Markdown source. One of the key additions is
that it enables text selection within a `Markdown` view. Eventually,
this will replace `RichText` but for now the goal is to use it in the
assistant revamped assistant in the spirit of making progress.
<img width="711" alt="image"
src="https://github.com/zed-industries/zed/assets/482957/b56c777b-e57c-42f9-95c1-3ada22f63a69">
Note that this pull request doesn't yet use the new markdown renderer in
`assistant2`. This is because we need to modify the assistant before
slotting in the new renderer and I wanted to merge this independently of
those changes.
Release Notes:
- N/A
---------
Co-authored-by: Nathan Sobo <nathan@zed.dev>
Co-authored-by: Conrad <conrad@zed.dev>
Co-authored-by: Alp <akeles@umd.edu>
Co-authored-by: Zachiah Sawyer <zachiah@proton.me>
It seems that on the first frame after the system resumes from sleep,
`dcomp_vsync_fn` mistakenly detects the `timer_stop_event` triggering
and exits the loop.
Release Notes:
- N/A
This PR changes the Markdown language defaults to set `format_on_save`
to be `off`.
Prettier's Markdown formatting is a bit controversial for some people,
so we turn it off by default.
To restore the previous behavior, add the following to your settings:
```json
{
"languages": {
"Markdown": {
"format_on_save": "on"
}
}
}
```
Release Notes:
- Changed the default `format_on_save` behavior for Markdown files to be
`off`.
Release Notes:
- N/A
## What
Addresses a long-standing issue of doing the blending operations in sRGB
space. Currently, the input HSL colors are provided in sRGB space and
converted to linear in the vertex shader. Conversion back to sRGB, which
is required on most platforms today, happens at the very end of the
pipeline when writing into sRGB render target.
Note-1: in the future we may consider doing HSL -> sRGB -> Linear
transform on CPU before feeding into shaders. However, I don't expect
any significant difference here given that we are likely bound by fill
rate and pixel shaders, anyway.
Note-2: the graphics stack is programmed to detect if the platform
supports presenting in linear color space and avoids converting to sRGB
at the end in this case. However, on my Z13 laptop this isn't supported
by the RADV driver.
Closes#7684Closes#11462
@jansol please confirm if you can!
## Comparison
Screenshot of the Glazier theme before the change:
![glazier-old](https://github.com/zed-industries/zed/assets/107301/6a9552e1-0819-4a4e-8121-8d62ec012bf4)
Same theme after the change:
![glazier-new](https://github.com/zed-industries/zed/assets/107301/4e61c422-4a4b-4c4b-84a3-55680626d681)
Previously, `DirectWrite` had been following the text system
implementation on `macOS`, using the font's postscript name to
differentiate between different font faces. However, I noticed
occasional rendering issues, such as fonts incorrectly rendering as
italics. Later, I discovered that on `Windows`, the postscript name is
**not** unique. Surprisingly, even the same font can have different
postscript names on macOS and Windows! It's hard to believe! The
postscript name of a font face should be obtained from the same font
table. Why would the same font face have different names?
For example, the postscript name of ZedMono on `macOS` is
`Zed-Mono-Bold-Extended-Italic`, while on `Windows`, it is
`Zed-Mono-Extended`, missing weight and style information, leading to
incorrect rendering.
This PR introduces a `FontIdentifier` struct to uniquely identify font
faces.
Release Notes:
- N/A
As per Microsoft documentation, positive values scroll right, not left.
GPUI was incorrectly assuming it perfectly mirrored vertical scrolling.
Fixes#11515
Release Notes:
- N/A
This PR is another step to tabless editing (#6424, #4963). It adds
support for tab bar settings that allow the user to change its placement
or to hide completely.
Configuraton:
```json
"tab_bar": {
"show": true
}
```
Placemnet options are "top", "bottom" and "no".
This PR intentionally doesn't affect tab bars of other panes (Terminal
for instance) to keep code changes small. I guess we'll do the rest in
separate PRs.
Release Notes:
- Added support for configuring the editor tab bar (part of #6424,
#4963).
---------
Co-authored-by: Mikayla <mikayla@zed.dev>
This shows "Researching..." as placeholder text as early as possible so
that the user can see the model is working on reading/researching/etc.
This also adds on an `Option<Value>` to the `render_running` function so
that tools can hopefully render based on partially completed JSON (still
to come).
Release Notes:
- N/A
This fixes restart after updates not working on Linux.
On Linux we can't reliably get the binary path after an update, because
the original binary was deleted and the path will contain ` (deleted)`.
See: https://github.com/rust-lang/rust/issues/69343
We *could* strip ` (deleted)` off, but that feels nasty. So instead we
save the original binary path, before we do the installation, then
restart.
Later on, we can also change this to be a _new_ binary path returned by
the installers, which we then have to start.
Release Notes:
- N/A
Now, regardless of how the Zed window is closed, Zed can remember the
window's restore size.
- [x] Windows implementation
- [x] macOS implementation
- [x] Linux implementation (partial)
- [x] update SQL data base (mark column `fullscreen` as deprecated)
The current implementation on Linux is basic, and I'm not sure if it's
correct.
The variable `fullscreen` in SQL can be removed, but I'm unsure how to
do it.
edit: mark `fullscreen` as deprecated
### Case 1
When the window is closed as maximized, reopening it will open in the
maximized state, and returning from maximized state will restore the
position and size it had when it was maximized.
https://github.com/zed-industries/zed/assets/14981363/7207752e-878a-4d43-93a7-41ad1fdb3a06
### Case 2
When the window is closed as fullscreen, reopening it will open in
fullscreen mode, and toggling fullscreen will restore the position and
size it had when it entered fullscreen (note that the fullscreen
application was not recorded in the video, showing a black screen, but
it had actually entered fullscreen mode).
https://github.com/zed-industries/zed/assets/14981363/ea5aa70d-b296-462a-afb3-4c3372883ea3
### What's more
- As English is not my native language, some variable and struct names
may need to be modified to match their actual meaning.
- I am not familiar with the APIs related to macOS and Linux, so
implementation for these two platforms has not been done for now.
- Any suggestions and ideas are welcome.
Release Notes:
- N/A
Fixes#11422 by accepting just the start of the line.
Release Notes:
- N/A
---------
Co-authored-by: max <max@zed.dev>
Co-authored-by: jacob <jacob@supermaven.com>
This PR updates the new assistant with a button to start a new
conversation.
Clicking on it will reset the chat and put it into a fresh state.
The current conversation will be serialized and written to
`~/.config/zed/conversations`.
Release Notes:
- N/A
Just adding a short note about `cargo build --release` and the location
of the compiled binary. It helps a lot to streamline usage of Zed day to
day on Linux.
Release Notes:
- N/A
This PR adds the general structure for conversation history to the new
assistant.
Right now we have a placeholder button in the assistant panel that will
toggle a picker containing some placeholder saved conversations.
Release Notes:
- N/A