Files
lightcraft/crates
Gert Pellin 7ccff3b96e fix(toast): draw the toast as widgets so the message can be selected
The toast was painted straight onto the layer with painter.galley(), and
painted text is never hit-tested: nothing in it could be selected or
copied. A toast often carries the path or the command the user needs
elsewhere ("Exported frame to /path"), and egui's selectable labels —
on by default — only work on real widgets.

Draw it as an Area with a Frame and a wrapping Label instead, keeping the
same centring, 6 px radius, 20/11 padding and the 0.25 s fade-out.

The new tests assert the toast has an area of its own, that the pointer
reaches the text (egui offers the text cursor over it), and that a long
message still wraps within the canvas. All three fail when the toast is
painted, which is what they are for.
2026-10-12 16:14:39 +02:00
..
2026-10-11 12:02:46 +00:00
2026-10-11 12:40:55 +00:00
2026-10-11 12:03:53 +00:00
2026-10-11 12:00:57 +00:00
2026-10-11 12:03:53 +00:00
2026-10-11 12:43:20 +00:00
2026-10-11 11:47:28 +00:00
2026-10-11 13:09:34 +00:00
2026-10-11 13:09:34 +00:00
2026-10-11 12:37:14 +00:00
2026-10-09 20:34:54 -04:00