Implement shadows in default selector impl

This commit is contained in:
Nikita Lisitsa 2022-12-18 19:22:55 +03:00
parent f42b91a80e
commit 1c9fb28ebf

View file

@ -755,7 +755,12 @@ namespace psemek::ui
{
auto st = merged_own_style();
p.draw_rect(shape().bbox(), *st->bg_color);
auto bbox = shape().bbox();
if (st->shadow_offset)
p.draw_rect(bbox + geom::cast<float>(*st->shadow_offset), *st->shadow_color);
p.draw_rect(bbox, *st->bg_color);
if (auto i = selected())
{