Angled Gradient Modifier

Draw a linear gradient at an arbitrary angle across a Compose box so both endpoints land exactly on the box edge — the per-quadrant endpoint formula from the requested angle, why rotating the diagonal overshoots and why clamping to the nearest edge distorts the angle, and the degenerate cases that collapse the ramp to nothing. Use when a tilted gradient looks washed out or cut off near the corners, when the visible angle does not match the angle you asked for, or when the same gradient looks different on a wide box than on a tall one.

maxrave-dev Updated 2.3k repo stars
The SimpMusic repository on GitHub

File contents

maxrave-dev/kotlin-footguns commit 6edf154891

Frequently asked questions

npx get-skill add maxrave-dev/angled-gradient-modifier