Add "zed" label to the title bar
This commit is contained in:
parent
64c26a73be
commit
21c74ca78d
3 changed files with 14 additions and 4 deletions
|
@ -7,6 +7,7 @@ pane_divider = { width = 1, color = "$border.0" }
|
||||||
|
|
||||||
[workspace.titlebar]
|
[workspace.titlebar]
|
||||||
border = { width = 1, bottom = true, color = "$border.0" }
|
border = { width = 1, bottom = true, color = "$border.0" }
|
||||||
|
text = { extends = "$text.0" }
|
||||||
|
|
||||||
[workspace.tab]
|
[workspace.tab]
|
||||||
text = "$text.2"
|
text = "$text.2"
|
||||||
|
|
|
@ -34,7 +34,7 @@ pub struct SyntaxTheme {
|
||||||
#[derive(Deserialize)]
|
#[derive(Deserialize)]
|
||||||
pub struct Workspace {
|
pub struct Workspace {
|
||||||
pub background: Color,
|
pub background: Color,
|
||||||
pub titlebar: ContainerStyle,
|
pub titlebar: ContainedLabel,
|
||||||
pub tab: Tab,
|
pub tab: Tab,
|
||||||
pub active_tab: Tab,
|
pub active_tab: Tab,
|
||||||
pub pane_divider: Border,
|
pub pane_divider: Border,
|
||||||
|
|
|
@ -949,12 +949,21 @@ impl View for Workspace {
|
||||||
|
|
||||||
fn render(&mut self, cx: &mut RenderContext<Self>) -> ElementBox {
|
fn render(&mut self, cx: &mut RenderContext<Self>) -> ElementBox {
|
||||||
let settings = self.settings.borrow();
|
let settings = self.settings.borrow();
|
||||||
|
let theme = &settings.theme;
|
||||||
Container::new(
|
Container::new(
|
||||||
Flex::column()
|
Flex::column()
|
||||||
.with_child(
|
.with_child(
|
||||||
ConstrainedBox::new(
|
ConstrainedBox::new(
|
||||||
Container::new(Empty::new().boxed())
|
Container::new(
|
||||||
.with_style(&settings.theme.workspace.titlebar)
|
Align::new(
|
||||||
|
Label::new(
|
||||||
|
"zed".into(),
|
||||||
|
theme.workspace.titlebar.label.clone()
|
||||||
|
).boxed()
|
||||||
|
)
|
||||||
|
.boxed()
|
||||||
|
)
|
||||||
|
.with_style(&theme.workspace.titlebar.container)
|
||||||
.boxed(),
|
.boxed(),
|
||||||
)
|
)
|
||||||
.with_height(32.)
|
.with_height(32.)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue