comments
This commit is contained in:
@@ -22,6 +22,8 @@ impl Text {
|
||||
|
||||
impl<Ctx> Widget<Ctx> for Text {
|
||||
fn draw(&self, painter: &mut Painter<Ctx>) {
|
||||
// TODO: when on_update is added to painter,
|
||||
// return & store TextureHandle to reuse
|
||||
painter.draw_text(&self.content, &self.attrs);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -103,6 +103,7 @@ impl<Ctx> Ui<Ctx> {
|
||||
{
|
||||
self.active.clear();
|
||||
self.primitives.clear();
|
||||
// free before bc nothing should exist
|
||||
self.free();
|
||||
let mut painter = Painter::new(
|
||||
&self.widgets,
|
||||
|
||||
Reference in New Issue
Block a user