Render borders in gpui2 divs
This commit is contained in:
@@ -73,6 +73,7 @@ impl<V: 'static> Element<V> for Div<V> {
|
||||
for child in &mut self.children {
|
||||
child.paint(view, layout.bounds.origin(), cx);
|
||||
}
|
||||
style.paint_foreground(layout.bounds, cx);
|
||||
if pop_text_style {
|
||||
cx.pop_text_style();
|
||||
}
|
||||
|
||||
@@ -477,6 +477,15 @@ pub trait StyleHelpers: Styleable<Style = Style> {
|
||||
self
|
||||
}
|
||||
|
||||
fn border_color<C>(mut self, border_color: C) -> Self
|
||||
where
|
||||
C: Into<Hsla>,
|
||||
Self: Sized,
|
||||
{
|
||||
self.declared_style().border_color = Some(border_color.into());
|
||||
self
|
||||
}
|
||||
|
||||
fn text_color<C>(mut self, color: C) -> Self
|
||||
where
|
||||
C: Into<Hsla>,
|
||||
|
||||
Reference in New Issue
Block a user