Add Ui::available_height

Closes #553
This commit is contained in:
Emil Ernerfeldt
2021-08-15 17:04:14 +02:00
parent a48c69d809
commit 22a13c75bb
+4
View File
@@ -470,6 +470,10 @@ impl Ui {
self.available_size().x
}
pub fn available_height(&self) -> f32 {
self.available_size().y
}
/// In case of a wrapping layout, how much space is left on this row/column?
pub fn available_size_before_wrap(&self) -> Vec2 {
self.placer.available_rect_before_wrap().size()