Revise and clean up some icons (#35582)
This is really just a small beginning, as there are many other icons to be revised and cleaned up. Our current set is a bit of a mess in terms of dimension, spacing, stroke width, and terminology. I'm sure there are more non-used icons I'm not covering here, too. We'll hopefully tackle it all soon leading up to 1.0. Closes https://github.com/zed-industries/zed/issues/35576 Release Notes: - N/A
This commit is contained in:
parent
8b573d4395
commit
0609c8b953
58 changed files with 154 additions and 271 deletions
|
@ -6403,7 +6403,6 @@ impl Editor {
|
|||
IconButton::new("inline_code_actions", ui::IconName::BoltFilled)
|
||||
.icon_size(icon_size)
|
||||
.shape(ui::IconButtonShape::Square)
|
||||
.style(ButtonStyle::Transparent)
|
||||
.icon_color(ui::Color::Hidden)
|
||||
.toggle_state(is_active)
|
||||
.when(show_tooltip, |this| {
|
||||
|
@ -8338,26 +8337,29 @@ impl Editor {
|
|||
let color = Color::Muted;
|
||||
let position = breakpoint.as_ref().map(|(anchor, _, _)| *anchor);
|
||||
|
||||
IconButton::new(("run_indicator", row.0 as usize), ui::IconName::Play)
|
||||
.shape(ui::IconButtonShape::Square)
|
||||
.icon_size(IconSize::XSmall)
|
||||
.icon_color(color)
|
||||
.toggle_state(is_active)
|
||||
.on_click(cx.listener(move |editor, e: &ClickEvent, window, cx| {
|
||||
let quick_launch = e.down.button == MouseButton::Left;
|
||||
window.focus(&editor.focus_handle(cx));
|
||||
editor.toggle_code_actions(
|
||||
&ToggleCodeActions {
|
||||
deployed_from: Some(CodeActionSource::RunMenu(row)),
|
||||
quick_launch,
|
||||
},
|
||||
window,
|
||||
cx,
|
||||
);
|
||||
}))
|
||||
.on_right_click(cx.listener(move |editor, event: &ClickEvent, window, cx| {
|
||||
editor.set_breakpoint_context_menu(row, position, event.down.position, window, cx);
|
||||
}))
|
||||
IconButton::new(
|
||||
("run_indicator", row.0 as usize),
|
||||
ui::IconName::PlayOutlined,
|
||||
)
|
||||
.shape(ui::IconButtonShape::Square)
|
||||
.icon_size(IconSize::XSmall)
|
||||
.icon_color(color)
|
||||
.toggle_state(is_active)
|
||||
.on_click(cx.listener(move |editor, e: &ClickEvent, window, cx| {
|
||||
let quick_launch = e.down.button == MouseButton::Left;
|
||||
window.focus(&editor.focus_handle(cx));
|
||||
editor.toggle_code_actions(
|
||||
&ToggleCodeActions {
|
||||
deployed_from: Some(CodeActionSource::RunMenu(row)),
|
||||
quick_launch,
|
||||
},
|
||||
window,
|
||||
cx,
|
||||
);
|
||||
}))
|
||||
.on_right_click(cx.listener(move |editor, event: &ClickEvent, window, cx| {
|
||||
editor.set_breakpoint_context_menu(row, position, event.down.position, window, cx);
|
||||
}))
|
||||
}
|
||||
|
||||
pub fn context_menu_visible(&self) -> bool {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue