Add colors for document highlights
This commit is contained in:
parent
bdf6e8bcc7
commit
268be71d8e
4 changed files with 12 additions and 6 deletions
|
@ -4057,12 +4057,12 @@ impl Editor {
|
||||||
|
|
||||||
this.highlight_background::<DocumentHighlightRead>(
|
this.highlight_background::<DocumentHighlightRead>(
|
||||||
read_ranges,
|
read_ranges,
|
||||||
|theme| todo!("theme.editor.document_highlight_read_background"),
|
|theme| theme.editor_document_highlight_read_background,
|
||||||
cx,
|
cx,
|
||||||
);
|
);
|
||||||
this.highlight_background::<DocumentHighlightWrite>(
|
this.highlight_background::<DocumentHighlightWrite>(
|
||||||
write_ranges,
|
write_ranges,
|
||||||
|theme| todo!("theme.editor.document_highlight_write_background"),
|
|theme| theme.editor_document_highlight_write_background,
|
||||||
cx,
|
cx,
|
||||||
);
|
);
|
||||||
cx.notify();
|
cx.notify();
|
||||||
|
|
|
@ -48,15 +48,15 @@ pub struct AppCell {
|
||||||
impl AppCell {
|
impl AppCell {
|
||||||
#[track_caller]
|
#[track_caller]
|
||||||
pub fn borrow(&self) -> AppRef {
|
pub fn borrow(&self) -> AppRef {
|
||||||
let thread_id = std::thread::current().id();
|
// let thread_id = std::thread::current().id();
|
||||||
eprintln!("borrowed {thread_id:?}");
|
// eprintln!("borrowed {thread_id:?}");
|
||||||
AppRef(self.app.borrow())
|
AppRef(self.app.borrow())
|
||||||
}
|
}
|
||||||
|
|
||||||
#[track_caller]
|
#[track_caller]
|
||||||
pub fn borrow_mut(&self) -> AppRefMut {
|
pub fn borrow_mut(&self) -> AppRefMut {
|
||||||
let thread_id = std::thread::current().id();
|
// let thread_id = std::thread::current().id();
|
||||||
eprintln!("borrowed {thread_id:?}");
|
// eprintln!("borrowed {thread_id:?}");
|
||||||
AppRefMut(self.app.borrow_mut())
|
AppRefMut(self.app.borrow_mut())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -114,6 +114,8 @@ pub struct ThemeColors {
|
||||||
pub editor_invisible: Hsla,
|
pub editor_invisible: Hsla,
|
||||||
pub editor_wrap_guide: Hsla,
|
pub editor_wrap_guide: Hsla,
|
||||||
pub editor_active_wrap_guide: Hsla,
|
pub editor_active_wrap_guide: Hsla,
|
||||||
|
pub editor_document_highlight_read_background: Hsla,
|
||||||
|
pub editor_document_highlight_write_background: Hsla,
|
||||||
pub terminal_background: Hsla,
|
pub terminal_background: Hsla,
|
||||||
pub terminal_ansi_bright_black: Hsla,
|
pub terminal_ansi_bright_black: Hsla,
|
||||||
pub terminal_ansi_bright_red: Hsla,
|
pub terminal_ansi_bright_red: Hsla,
|
||||||
|
|
|
@ -249,6 +249,8 @@ impl ThemeColors {
|
||||||
editor_invisible: neutral().light_alpha().step_4(), // todo!("pick the right colors")
|
editor_invisible: neutral().light_alpha().step_4(), // todo!("pick the right colors")
|
||||||
editor_wrap_guide: neutral().light_alpha().step_4(), // todo!("pick the right colors")
|
editor_wrap_guide: neutral().light_alpha().step_4(), // todo!("pick the right colors")
|
||||||
editor_active_wrap_guide: neutral().light_alpha().step_4(), // todo!("pick the right colors")
|
editor_active_wrap_guide: neutral().light_alpha().step_4(), // todo!("pick the right colors")
|
||||||
|
editor_document_highlight_read_background: neutral().light_alpha().step_4(), // todo!("pick the right colors")
|
||||||
|
editor_document_highlight_write_background: neutral().light_alpha().step_4(), // todo!("pick the right colors")
|
||||||
terminal_background: neutral().light().step_1(),
|
terminal_background: neutral().light().step_1(),
|
||||||
terminal_ansi_black: black().light().step_12(),
|
terminal_ansi_black: black().light().step_12(),
|
||||||
terminal_ansi_red: red().light().step_11(),
|
terminal_ansi_red: red().light().step_11(),
|
||||||
|
@ -320,6 +322,8 @@ impl ThemeColors {
|
||||||
editor_invisible: neutral().dark_alpha().step_4(), // todo!("pick the right colors")
|
editor_invisible: neutral().dark_alpha().step_4(), // todo!("pick the right colors")
|
||||||
editor_wrap_guide: neutral().dark_alpha().step_4(), // todo!("pick the right colors")
|
editor_wrap_guide: neutral().dark_alpha().step_4(), // todo!("pick the right colors")
|
||||||
editor_active_wrap_guide: neutral().dark_alpha().step_4(), // todo!("pick the right colors")
|
editor_active_wrap_guide: neutral().dark_alpha().step_4(), // todo!("pick the right colors")
|
||||||
|
editor_document_highlight_read_background: neutral().dark_alpha().step_4(), // todo!("pick the right colors")
|
||||||
|
editor_document_highlight_write_background: neutral().dark_alpha().step_4(), // todo!("pick the right colors")
|
||||||
terminal_background: neutral().dark().step_1(),
|
terminal_background: neutral().dark().step_1(),
|
||||||
terminal_ansi_black: black().dark().step_12(),
|
terminal_ansi_black: black().dark().step_12(),
|
||||||
terminal_ansi_red: red().dark().step_11(),
|
terminal_ansi_red: red().dark().step_11(),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue