1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-30 21:30:03 -04:00

Refactor: break out Layout to own struct/file

This commit is contained in:
Emil Ernerfeldt
2020-05-13 21:36:15 +02:00
parent b8675ad67f
commit d4204f03c0
10 changed files with 173 additions and 95 deletions

View File

@@ -128,8 +128,7 @@ impl<'a> Widget for Slider<'a> {
// Place the text in line with the slider on the left:
columns[1].set_desired_height(slider_response.rect.height());
columns[1].horizontal(|ui| {
ui.set_align(Align::Center);
columns[1].inner_layout(Layout::horizontal(Align::Center), |ui| {
ui.add(Label::new(full_text).multiline(false));
});