Try Style newtype instead of trait for Svg widget

This commit is contained in:
Héctor Ramón Jiménez 2024-03-06 17:26:07 +01:00
parent 597a41cea7
commit 8a63774b24
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
2 changed files with 26 additions and 14 deletions

View file

@ -366,7 +366,7 @@ pub fn image<Handle>(handle: impl Into<Handle>) -> crate::Image<Handle> {
#[cfg(feature = "svg")]
pub fn svg<Theme>(handle: impl Into<core::svg::Handle>) -> crate::Svg<Theme>
where
Theme: crate::svg::Style,
crate::svg::Style<Theme>: Default,
{
crate::Svg::new(handle)
}