When I try to push image into row/column i get:
46 | .push(Image::new(self.image.clone()))
| ^^^^ the trait `iced_native::widget::image::Renderer` is not implemented for `iced_wgpu::renderer::Renderer`
|
= note: required because of the requirements on the impl of `std::convert::From<iced_native::widget::image::Image>` for `iced_native::element::Element<'_, wgpu_backend::iced_pipeline::Message, iced_wgpu::renderer::Renderer>`
= note: required because of the requirements on the impl of `std::convert::Into<iced_native::element::Element<'_, wgpu_backend::iced_pipeline::Message, iced_wgpu::renderer::Renderer>>` for `iced_native::widget::image::Image`
From example:
pub fn view<'a>(&'a mut self, color: f32) -> Element<'a, Message, Renderer> {
let content = Row::new()
.spacing(20)
.align_items(Align::End)
.push(Image::new(self.image.clone()))
.push(
Column::new().spacing(20).push(
Row::new()
.align_items(Align::End)
.spacing(20)
.push(Text::new("Icon").size(30).width(Length::Fill)),
),
);
Container::new(content)
.width(Length::Fill)
.height(Length::Fill)
.center_x()
.center_y()
.into()
}
self.image is image::Handle do i need to do different?
You need to enable the image feature.
Ah wonderful, thank so much for fast response!
Most helpful comment
You need to enable the
imagefeature.