mirror of
https://github.com/emilk/egui.git
synced 2026-09-01 14:20:04 -04:00
Allow mutable borrow of ui.style (#18)
This commit is contained in:
@@ -93,6 +93,12 @@ impl Ui {
|
|||||||
&self.style
|
&self.style
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Mutably borrow internal `Style`.
|
||||||
|
/// Changes apply to this `Ui` and its subsequent children.
|
||||||
|
pub fn style_mut(&mut self) -> &mut Style {
|
||||||
|
&mut self.style
|
||||||
|
}
|
||||||
|
|
||||||
pub fn set_style(&mut self, style: Style) {
|
pub fn set_style(&mut self, style: Style) {
|
||||||
self.style = style
|
self.style = style
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user