re_ui 0.35.0

Rerun GUI theme and helpers, built around egui
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use egui::text::LayoutJob;

pub trait LayoutJobExt {
    /// Returns a copy of this job with the text and sections cleared, keeping the other
    /// layout settings (wrap, justify, `break_on_newline`, …).
    // TODO(emilk): add `LayoutJob::clear` to egui and use that instead.
    fn cleared(&self) -> LayoutJob;
}

impl LayoutJobExt for LayoutJob {
    fn cleared(&self) -> LayoutJob {
        Self {
            text: Default::default(),
            sections: Default::default(),
            ..self.clone()
        }
    }
}