Commit Graph
14268 Commits
Author SHA1 Message Date
Nate Butler 1cc2984fef Extend theme converter to allow multimatching against vscode colors 2023-11-09 16:38:48 -05:00
Marshall Bowers 26c4abcc19 Refine theme styles (#3291)
This PR refines a number of styles in the default theme, as well as
updates the theme importer to support importing syntax styles from VS
Code themes.

Release Notes:

- N/A
2023-11-09 15:32:10 -05:00
Marshall Bowers f1108c1ad9 Allow user-theme related methods to be unused 2023-11-09 15:16:59 -05:00
Nate ButlerandMarshall Bowers 6460a6d1d3 Deal with special case where a VSCode theme doesn't have a foreground color
Co-Authored-By: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com>
2023-11-09 14:53:04 -05:00
Nate ButlerandMarshall Bowers c392e567a0 Finish passing Syntax from VSCode themes to Zed Themes
Co-Authored-By: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com>
2023-11-09 14:41:26 -05:00
Max Brunsfeld efa5263528 Use normal JS comments within JSX tags and JSX expression blocks (#3290)
This fix only required changing the `overrides` queries for JavaScript
and TSX. I've made the fix in both the `zed2` and `zed` crates.

Release Notes:

- Fixed an issue in JavaScript and TSX files, where the 'toggle
comments' command used the wrong comment syntax inside of JSX tags and
expressions within JSX.
2023-11-09 11:15:08 -08:00
Max Brunsfeld 785a835091 Duplicate buffer test changes in language2 version 2023-11-09 11:09:49 -08:00
Max BrunsfeldandKirill 3248d712e5 Use normal JS comments within JSX tags and JSX expression blocks
Co-authored-by: Kirill <kirill@zed.dev>
2023-11-09 10:58:33 -08:00
Nate ButlerandMarshall Bowers b260ab5947 Extend UserSyntax to allow font_style and font_weight to be specified
Co-Authored-By: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com>
2023-11-09 13:46:08 -05:00
Conrad Irwin f68d8e9612 Fix escape in GoToLine with new event emitter (#3289)
[[PR Description]]

Release Notes:

- N/A
2023-11-09 11:23:26 -07:00
Marshall Bowers 70651e3fc1 Use IndexMap for a deterministic order when importing syntax colors 2023-11-09 13:12:36 -05:00
Marshall Bowers 7a0eef99ff Reorganize theme_importer 2023-11-09 13:07:32 -05:00
Marshall Bowers c2d703c963 Properly emit UserHighlightStyles 2023-11-09 12:59:20 -05:00
Julia 8191babed1 zed2: Get tsserver running again (#3288)
Port these changes to the zed2 directory

Release Notes:

- N/A
2023-11-09 12:55:27 -05:00
Conrad Irwin bab847a209 Fix escape in GoToLine with new event emitter 2023-11-09 10:52:17 -07:00
Marshall Bowers 0c2aef6068 Add importing-themes feature flag to theme2 crate
When this feature is set the `themes` module won't be compiled.
This allows us to run the `theme_importer` even when the `themes` module
has compile errors in it.
2023-11-09 12:49:16 -05:00
Marshall Bowers 9e2de5ad97 Emit unique highlights for each syntax token 2023-11-09 12:46:37 -05:00
Nate ButlerandMarshall Bowers 4cabcdd6d4 WIP – Add Syntax themes to importer
Co-Authored-By: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com>
2023-11-09 12:30:53 -05:00
Julia 229c106781 zed2: Get tsserver running again 2023-11-09 11:43:40 -05:00
Nate ButlerandMarshall Bowers f727945f16 Allow imported themes to refine StatusColors
Co-Authored-By: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com>
2023-11-09 11:30:59 -05:00
Joseph T. Lyons 309ad1f33b Fix typo in EULA (#3287)
Release Notes:

- N/A
2023-11-09 11:25:50 -05:00
Joseph T. Lyons 71c22ba4b1 Fix typo in EULA 2023-11-09 11:08:30 -05:00
Nate Butler 5ccd6e67b6 Add more vscode colors 2023-11-09 11:01:18 -05:00
Kirill Bulatov fa4e7604c6 Do not use prettier for formatting node_modules/** files (#3286)
Fixes

> the most annoying thing i'm running into right now is that when i'm
patching something inside node_modules, Zed tries to pretty-format it
according to my prettier config. this messes up the patch because it has
formatting changes now. i need the pretty formatting on save to be off
inside node_modules, that never makes sense

feedback from #influencers 

Do note though, that language servers will still format any file inside
node_modules, but at least it's not prettier now.
VSCode seem to format the node_modules/** files via language servers
too, so that seems ok for now, and the rest could be fixed during

> "project diagnostics" (eslint) seem to be running inside node_modules,
e.g. i'm seeing 3182 "errors" in my project. that doesn't make sense and
probably wastes resources in addition to being annoying

feedback later.

Release Notes:

- Fixed prettier formatting files inside node_modules
2023-11-09 17:42:58 +02:00
Kirill Bulatov 01d7e2d231 Port changes to gpui2 2023-11-09 17:18:41 +02:00
Julia 2b093c7839 Get tsserver running again (#3277)
Release Notes:

- Fixed a few issues preventing Javascript/Typescript language server
from working with latest upstream changes.
2023-11-09 10:14:36 -05:00
Kirill Bulatov 23c8be7dac Do not propose prettier formatters for documents in node_modules/ 2023-11-09 14:49:37 +02:00
Kirill Bulatov 8d8e38a741 Adjust the tests 2023-11-09 14:40:32 +02:00
Kirill Bulatov 7918982c6e Change locate prettier method signature 2023-11-09 14:23:33 +02:00
Nate Butler f57822ab1d Extend VSCode theme importer 2023-11-09 01:39:31 -05:00
Nate Butler 60ca0ccf6c WIP 2023-11-09 01:21:22 -05:00
Nate Butler 71a1b131cd Merge branch 'main' into update-workspace-styles 2023-11-09 00:38:06 -05:00
Mikayla Maki bb08571de8 port notifications2 and integration tests (#3283)
Release Notes:

- N/A
2023-11-08 21:32:33 -08:00
Nathan Sobo 9f9938ffc6 Simplify input handling (#3282)
This PR takes a different approach to input handling.

Rather than returning the optional input handler, focus handle pair from
the element trait, we instead allow you to register an input handler
imperatively on the window context with `WindowContext::handle_input`.
You pass a focus handle reference and any implementer of
`PlatformInputHandler`. There's an `ElementInputHandler<V>` that
implements `PlatformWindowHandler` so long as `V` implements
`InputHandler`.

Release Notes:

- N/A
2023-11-08 22:27:36 -07:00
Mikayla 94ae2091ff Add notifications2 2023-11-08 21:23:31 -08:00
Nathan Sobo cb13d7fa6f Add docs 2023-11-08 22:03:26 -07:00
Nathan Sobo ff4f9512bd Remove comments 2023-11-08 21:49:21 -07:00
Nathan Sobo 243c19cebe Actually set the input handler 2023-11-08 21:43:14 -07:00
Mikayla Maki f836ecd436 port rope2 to zed2 (#3224)
port rope2 to zed2

Release Notes:

- NA
2023-11-08 20:19:05 -08:00
Mikayla Maki 5c3ef189ae Switch from associated type to generic on EventEmitter trait (#3281)
This removes a lot of ad-hoc event translation code in the workspace and
replaces it with a GPUI feature and trait bounds.

TODO:
- [x] Proof out idea
- [x] Convert the workspace
- [x] Convert the rest of the app

Release Notes:

- N/A
2023-11-08 20:16:33 -08:00
Mikayla 22a19cd8ff Merge branch 'main' into event-emitter 2023-11-08 20:10:38 -08:00
Nathan Sobo bac0b84dfa Simplify IME support 2023-11-08 21:06:00 -07:00
Mikayla e9267a7495 Update editor to use new event emitter 2023-11-08 19:52:43 -08:00
Mikayla 9fd7066ac1 Get workspace compiling with new event emitters 2023-11-08 19:29:00 -08:00
Conrad Irwin 755bf38f0b de-dbg (#3280)
Remove some debugging from GoToLine

Release Notes:

- N/A
2023-11-08 18:45:42 -07:00
Max Brunsfeld 2fb47b086a Implement bounds_for_range, so that text input windows are positioned correctly (#3278)
![Screenshot 2023-11-08 at 5 33
10 PM](https://github.com/zed-industries/zed/assets/326587/09efd785-2c43-41b2-9429-c17067497fd2)

![Screenshot 2023-11-08 at 5 33
28 PM](https://github.com/zed-industries/zed/assets/326587/14a9faee-3547-40b6-a31f-16f653cdcb36)
2023-11-08 17:38:11 -08:00
Conrad Irwin 1f1e8fd81a de-dbg 2023-11-08 18:36:12 -07:00
Max Brunsfeld ffeed40e87 Merge branch 'main' into bounds-for-range 2023-11-08 17:31:00 -08:00
Max Brunsfeld 52d538170b Fix vertical position in first_rect_for_character_range 2023-11-08 17:27:32 -08:00
Max Brunsfeld 3f288f7977 Assign gutter widht on editor view when painting element 2023-11-08 17:01:50 -08:00