flutter_colorpicker
flutter_colorpicker copied to clipboard
Fix stroke width scaling in hue ring
The hue ring despite accepting a different stroke width from 20.0
seems to have some bits hard coded in such a way that different values cause the ui to not render correctly.
This PR fixes that by first ensuring that the HueRingPainter
always renders inbound (see the first commit message for more information about the problem), secondly by changing the hard coded parts to scale with stroke width and finally by also scaling the thumb of the ring.
Old | New | |
---|---|---|
Normal stroke width 20.0 |
![]() |
![]() |
Big stroke width 40.0 |
![]() |
![]() |