1
0
mirror of https://github.com/DarthAffe/CUE.NET.git synced 2025-12-13 00:58:31 +00:00

Updated Radial Gradient Brush (markdown)

DarthAffe 2017-01-10 12:22:55 +01:00
parent 499c36f690
commit f5ef2d7953

@ -2,9 +2,11 @@ The _RadialGradientBrush_ is one of the default brushes provided by CUE.NET.
It's used to draw a gradient as a "circle" inside a rectangle.
You are able to define the center-point of the circle and the gradient which should be drawn by either providing them as constructor-parameters or using the _Center_- and _Gradient_-Properties.
If you don't set a gradient the brush will return transparent for every key.
If you don't set a gradient the brush will return transparent for every LED.
> The Center-Point is given as the percentage from the top left corner.
> new PointF(0f, 0f) will be top left, new PointF(0,5f, 0,5f) in the center and new PointF(1f, 1f) in the bottom right.
> new PointF(0f, 0f) will be top left, new PointF(0,5f, 0,5f) in the center and new PointF(1f, 1f) in the bottom right.
>
> The radius of the drawn circle is the biggest distance from the center to the farthest point of the rectangle this brush is rendered to.
If you want to create a background on your keyboard looking like this