You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When you take the image example from the egui repository and add the ferris.svg image multiple times in the ScrollArea, it shows up just once.
To Reproduce
Steps to reproduce the behavior:
Create a new project
Add the following dependencies:
eframe = "0.23.0"egui_extras = { version = "0.23.0", features = ["all_loaders"] }
Add the ferris.svg file from the image example to the src folder
Copy the following into your main.rs:
#![cfg_attr(not(debug_assertions), windows_subsystem = "windows")]// hide console window on Windows in releaseuse eframe::egui;fnmain() -> Result<(), eframe::Error>{let options = eframe::NativeOptions{initial_window_size:Some(egui::vec2(600.0,800.0)),
..Default::default()};
eframe::run_native("Image Viewer",
options,Box::new(|cc| {// This gives us image support:
egui_extras::install_image_loaders(&cc.egui_ctx);Box::<MyApp>::default()}),)}#[derive(Default)]structMyApp{}impl eframe::AppforMyApp{fnupdate(&mutself,ctx:&egui::Context,_frame:&mut eframe::Frame){
egui::CentralPanel::default().show(ctx, |ui| {
egui::ScrollArea::new([true,true]).show(ui, |ui| {
ui.image(egui::include_image!("ferris.svg"));
ui.image(egui::include_image!("ferris.svg"));
ui.image(egui::include_image!("ferris.svg"));});});}}
Expected behavior
I would expect to see the image appear multiple times. Weirdly enough the multiple images seem to have some effect, because the scrollbar show up and is able to scroll just so slightly, but still just one image appears. I've been able to get this in egui v0.22 but I was not able to build it in v0.23.
Desktop (please complete the following information):
OS: Linux, Debian, i3-wm
Version 0.23.0
Additional context
The text was updated successfully, but these errors were encountered:
When doing the same thing with rasterized images such as pngs, it shows the image twice, one big version, one smaller, even though it's add three time to the ScrollArea.
Had the same problem with multiple images in frame containers in a ScrollArea container, but it was fixed by setting the image to a fixed size. Oddly enough, the solution was found in this issue, but I don't have any jitters.
Describe the bug
When you take the image example from the egui repository and add the ferris.svg image multiple times in the ScrollArea, it shows up just once.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
I would expect to see the image appear multiple times. Weirdly enough the multiple images seem to have some effect, because the scrollbar show up and is able to scroll just so slightly, but still just one image appears. I've been able to get this in egui v0.22 but I was not able to build it in v0.23.
Desktop (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered: