Implement overlay ordering for Image::float

This commit is contained in:
Héctor Ramón Jiménez 2025-04-25 11:20:16 +02:00
parent 7f1dcec391
commit e64c58d032
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
8 changed files with 416 additions and 143 deletions

View file

@ -101,6 +101,16 @@ where
) -> Option<Element<'a, Message, Theme, Renderer>> {
None
}
/// The index of the overlay.
///
/// Overlays with a higher index will be rendered on top of overlays with
/// a lower index.
///
/// By default, it returns `1.0`.
fn index(&self) -> f32 {
1.0
}
}
/// Returns a [`Group`] of overlay [`Element`] children.