1
0
mirror of https://github.com/emilk/egui.git synced 2026-06-27 15:13:12 -04:00

Fix panic when rendering thin textured rectangles (#5692)

* Closes https://github.com/emilk/egui/issues/5664
* [x] I have followed the instructions in the PR template

(cherry picked from commit 54d00d7d69)
This commit is contained in:
Pēteris Pakalns
2025-02-06 22:37:32 +02:00
committed by Lucas Meurer
parent bc2d3703c7
commit 2d37f1a778

View File

@@ -1810,7 +1810,7 @@ impl Tessellator {
}
}
if stroke.is_empty() {
if stroke.is_empty() && out.texture_id == TextureId::default() {
// Approximate thin rectangles with line segments.
// This is important so that thin rectangles look good.
if rect.width() <= 2.0 * self.feathering {