egui icon indicating copy to clipboard operation
egui copied to clipboard

`Area::constrain_to` clips shadow

Open juancampa opened this issue 3 years ago • 1 comments

Describe the bug

When using Area::constrain_to, the shadow gets clipped if close to the edge.

This seems to be cause by this intersect call.

To Reproduce Steps to reproduce the behavior:

  1. Add a constrain_to to an Area
  2. Move that area to the edge of the constrained area

Expected behavior Shadow never gets clipped.

Screenshots

Screenshot 2023-11-15 at 10 47 28 AM

In this video you can see how the shadow gets clipped when it reaches the constrain_to rect:

https://github.com/emilk/egui/assets/1410520/c2b660e2-43bd-4c05-b9fe-59adc598cc91

juancampa avatar Nov 15 '23 15:11 juancampa

This affects the .stroke of the window as well. Of course it has a worse visual effect the wider the stroke is.

kcone avatar Dec 21 '24 01:12 kcone