Commit Graph
109 Commits
Author SHA1 Message Date
Conrad Irwin a761e6ca0e More mouse occlusion work 2023-11-28 09:59:58 -07:00
Conrad Irwin 107c3d7f67 Fix esc in command palette
Also: add editor.register_action
2023-11-27 14:32:22 -07:00
Conrad Irwin 7a8aba329b Break content mask for hoverables 2023-11-27 11:43:14 -07:00
Antonio Scandurra 3ea12ad0d7 Remove commented out code 2023-11-27 19:19:56 +01:00
Antonio Scandurra a5951df21f Start on hover popover 2023-11-27 18:56:37 +01:00
Antonio Scandurra eb647be685 Pass max height manually 2023-11-27 14:56:46 +01:00
Antonio Scandurra 19bfed165b Show single-line docs in autocomplete and apply completion on mousedown 2023-11-24 13:22:25 +01:00
Antonio Scandurra 7eeb8078f6 Allow setting text background color via TextStyle 2023-11-23 19:22:18 +01:00
Antonio Scandurra 3b918bfee8 Merge branch 'main' into rename-element-traits
# Conflicts:
#	crates/gpui2/src/elements/uniform_list.rs
#	crates/ui2/src/components/context_menu.rs
#	crates/ui2/src/components/list.rs
2023-11-23 12:47:46 +01:00
Nathan Sobo c23f17ee0b Reorganize element-related traits 2023-11-22 11:19:43 -07:00
Antonio Scandurra 524f892fb0 Correctly swap position of context menu 2023-11-22 19:02:44 +01:00
Antonio Scandurra 3a8e9b5697 Avoid holding borrow to editor while painting child elements 2023-11-22 11:40:38 +01:00
2c4d83c9af WIP
co-authored-by: conrad <conrad@zed.dev>
co-authored-by: Nathan <nathan@zed.dev>
2023-11-20 14:46:01 -08:00
Conrad Irwin 0798cfd58c Merge branch 'main' into derive-element-redux 2023-11-20 09:15:38 -07:00
Nathan Sobo 33cd6f520a Clean compile with redesigned element traits 2023-11-18 21:51:47 -07:00
Nathan Sobo 0673606de8 WIP 2023-11-18 20:22:43 -07:00
Nathan Sobo adc355a1e6 Element refinement passing on ui2 2023-11-18 20:05:47 -07:00
Nathan Sobo 2515bbf990 Move self in Element::paint
Remove mutable state borrows in favor of state ownership in render processes to streamline element rendering.
2023-11-17 23:32:55 -07:00
Julia 3655a96e54 Merge branch 'main' into unborked-git-zed2-diagnostics-view 2023-11-17 16:32:35 -05:00
Julia c6d22af416 Get diagnostic2 tests building and running 2023-11-17 16:32:35 -05:00
Julia a464a7da2a Merge branch 'main' into unborked-git-zed2-diagnostics-view 2023-11-17 16:32:35 -05:00
JuliaandNathan Sobo f4eb219c75 Get diagnostics view almost building in the zed2 world
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2023-11-17 16:32:35 -05:00
Nathan Sobo 2fb13cf1ca Separate WrappedLines from ShapedLines (#3350)
ShapedLines are never wrapped, whereas WrappedLines are optionally
wrapped if they are associated with a wrap width. Originally, when
rewriting GPUI, I tried to combine everything because wrapping is
inherently optional for the Text element, but we have a bunch of APIs
that don't make sense on a line that may wrap, so we need a distinct
type for that case.

This is a precursor to implementing clickable links in markdown. I
noticed multiple places where we were confused about whether or not the
line was wrapped so this felt important.

Release Notes:

- N/A
2023-11-16 23:20:35 -07:00
Nathan Sobo 9558da8681 Separate WrappedLines from ShapedLines
ShapedLines are never wrapped, whereas WrappedLines are optionally wrapped if
they are associated with a wrap width. I tried to combine everything because
wrapping is inherently optional for the Text element, but we have a bunch of
APIs that don't make sense on a line that may wrap, so we need a distinct type
for that case.
2023-11-16 23:10:51 -07:00
Conrad Irwin 8c14a8fa95 Merge branch 'main' into collab_ui2 2023-11-15 21:04:47 -07:00
Conrad Irwin 0a9fb3978b Enable panel switching 2023-11-15 21:01:00 -07:00
Nathan Sobo c6b374ebc9 Remove initialize method from Element trait 2023-11-15 14:11:19 -07:00
Antonio Scandurra 08dfcba68a Fix panic when painting blocks 2023-11-15 20:02:35 +01:00
Antonio ScandurraandNathan Sobo 9ff238921f Fix clicking on code action and fold indicators
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2023-11-15 18:29:53 +01:00
Antonio ScandurraandNathan Sobo 17b8e4a684 Handle clicking folded ranges
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2023-11-15 18:19:26 +01:00
Antonio ScandurraandNathan Sobo 3ff8c78b58 Return a Fold struct when querying the FoldMap
This contains a new `id` field that lets us distinguish among folds.

Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2023-11-15 17:09:59 +01:00
Antonio Scandurra 851a60a68e Render fold indicators in the gutter 2023-11-15 14:07:37 +01:00
Antonio Scandurra 003e4bc241 Extract out a register_actions function 2023-11-15 09:53:32 +01:00
Antonio Scandurra feeb44c122 Merge remote-tracking branch 'origin/main' into editor2-rename
# Conflicts:
#	crates/editor2/src/editor.rs
#	crates/editor2/src/element.rs
#	crates/gpui2/src/style.rs
2023-11-15 09:51:33 +01:00
Antonio Scandurra 1def355d44 Don't return Result from TextStyle::highlight 2023-11-15 09:10:46 +01:00
Mikayla b81b96f353 Merge branch 'element-types' of github.com:zed-industries/zed into element-types 2023-11-14 15:55:53 -08:00
Mikayla 7f72df6dcf Merge branch 'main' into element-types 2023-11-14 15:49:10 -08:00
Conrad Irwin 1109cd11c8 Abandon ship 2023-11-14 16:17:24 -07:00
Nathan SoboandJulia bef4df5df9 Return an id from Element::element_id instead of calling cx.with_element_id
Co-Authored-By: Julia <julia@zed.dev>
2023-11-14 16:05:28 -07:00
Mikayla 6b25841e2a WIP 2023-11-14 14:48:34 -08:00
Conrad Irwin 3b01a032ba In the middle of stuff 2023-11-14 14:38:23 -07:00
Conrad Irwin 5dda105182 Merge branch 'main' into element-types 2023-11-14 11:45:19 -07:00
Antonio Scandurra 48b3a90fbf WIP 2023-11-14 19:42:07 +01:00
Nathan Sobo bb584cc7c4 WIP 2023-11-14 11:00:52 -07:00
Antonio Scandurra 428be43710 Wire up rename editor 2023-11-14 18:50:02 +01:00
Antonio Scandurra 7f5014b34a Add red background to blocks that need styling 2023-11-14 17:15:33 +01:00
Antonio ScandurraandJulia b6914bf0fd Re-enable find all references
Co-Authored-By: Julia <julia@zed.dev>
2023-11-14 16:09:29 +01:00
Antonio ScandurraandJulia f9b9b7549f Render block elements
Co-Authored-By: Julia <julia@zed.dev>
2023-11-14 16:03:06 +01:00
Antonio Scandurra fc5ec47cc8 WIP 2023-11-14 14:48:59 +01:00
Nathan Sobo 364e3e7de5 Merge remote-tracking branch 'origin/main' into element-types 2023-11-14 01:55:58 -07:00