Add ShadowedImage and ShadowedTexture items
AcceptedPublic

Authored by ahiemstra on Mon, Mar 23, 4:47 PM.

Details

Reviewers
mart
Group Reviewers
Kirigami
Summary

This adds the ShadowedImage and ShadowedTexture items. The first is a
QML-only item that makes use of the second. The second is a
ShadowedRectangle that uses a texture as color source for the item
instead of just a color.

It also does some cleanup on the scenegraph/shader related bits
introduced with ShadowedRectangle. Most importantly, it removes the
mostly duplicated core shaders in favour of a simple solution using
a #define.

Test Plan

There's a manual test included. It should look like this:

Diff Detail

Repository
R169 Kirigami
Branch
shadowed_texture
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 24109
Build 24127: arc lint + arc unit
ahiemstra created this revision.Mon, Mar 23, 4:47 PM
Restricted Application added a project: Kirigami. · View Herald TranscriptMon, Mar 23, 4:47 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
ahiemstra requested review of this revision.Mon, Mar 23, 4:47 PM
ahiemstra edited the test plan for this revision. (Show Details)Mon, Mar 23, 4:48 PM
mart added a subscriber: mart.Mon, Mar 23, 5:42 PM

+100, works very well here.
an api question. it was supposed to be possible to have the corners with independent radius (to have things like an image rounded only at top) would it still be possible with that approach? i guess would be expanding roundedrectangle to have independent radiuses?

Yeah if we split the radius into 4 that should be doable. The shader supports it, just need to bubble everything up all the way to the items.

mart accepted this revision.Fri, Mar 27, 9:34 AM

this one i think is good to go, then afterwards, the independent radii

This revision is now accepted and ready to land.Fri, Mar 27, 9:34 AM