mirror of
https://github.com/fltk/fltk.git
synced 2026-08-17 08:32:21 +08:00
Fix "Crash when using copied SVG image" (#1546)
Build and Test / build-linux (push) Canceled after 0s
Build and Test / build-wayland (push) Canceled after 0s
Build and Test / build-wayland-arm64 (push) Canceled after 0s
Build and Test / build-macos (push) Canceled after 0s
Build and Test / build-windows (push) Canceled after 0s
Build and Test / build-windows-arm (push) Canceled after 0s
Build and Test / build-linux (push) Canceled after 0s
Build and Test / build-wayland (push) Canceled after 0s
Build and Test / build-wayland-arm64 (push) Canceled after 0s
Build and Test / build-macos (push) Canceled after 0s
Build and Test / build-windows (push) Canceled after 0s
Build and Test / build-windows-arm (push) Canceled after 0s
This commit is contained in:
@@ -317,6 +317,7 @@ void Fl_Graphics_Driver::draw_rgb(Fl_RGB_Image *img, int XP, int YP, int WP, int
|
||||
Fl_RGB_Scaling keep = Fl_Image::RGB_scaling();
|
||||
Fl_Image::RGB_scaling(Fl_Image::scaling_algorithm());
|
||||
Fl_RGB_Image *img2 = (Fl_RGB_Image*)img->copy(w2, h2);
|
||||
img2->normalize(); // necessary when img is an Fl_SVG_Image
|
||||
Fl_Image::RGB_scaling(keep);
|
||||
cache(img2);
|
||||
draw_fixed(img2, XP, YP, WP, HP, cx, cy);
|
||||
|
||||
Reference in New Issue
Block a user