-
Notifications
You must be signed in to change notification settings - Fork 4
Brush
All drawing in the nModules is done with brushes.
General settings
Enumeration. What type of brush this is. SolidColor, Image, LinearGradient, or RadialGradient.
Default Value: SolidColor
A simple brush that just draws a single color.
Color. The color to draw with.
Default Value: Black.
Test
Settings shared by the RadialGradient and LinearGradient brush types.
Settings used by the linear gradient brush. These settings essentially let you specify the gradient, as shown on MSDN.
Settings used by the radial gradient brush. These settings essentially let you specify the gradient, as shown on MSDN.
Settings used by the image brush.
Integer. This images own alpha channel is multiplied by this value in order to determine the final alpha value. Range [0, 255].
Default Value: 255
File. The image to draw with.
Default Value: ""
Enumeration. How to scale the image.
Values
- Center: Center the image in the area we are drawing in, without scaling it.
- Tile: Tile the image.
- Fit: Uniformly scale the image such that it covers the entire area we are drawing in, in at least one dimension, without overflowing.
- Fill: Uniformly scale the image such that is covers the entire area we are drawing in.
- Edges: Scales the image to cover the entire area we draw in, without stretching the edges of the image.
Default Value: Center
OffsetRectangle<Float>. What the image edges are. Used by the Edges scaling mode to determine which parts of the image to stretch. The image is essentially divided into 9 sections, as shown below. Sections 1, 3, 7, and 9 are not stretched; sections 2, and 8 are only stretched horizontally; sections 4 and 6 are only stretched vertically; and, finally, section 5 is stretched to cover the remaining area.
1 2 3
4 5 6
7 8 9
Default Value: {Left: 0, Right: 0, Top: 0, Bottom: 0}
Enumeration. How to tile horizontally. Mirror, Clamp, or Wrap.
Default Value: Wrap
Enumeration. How to tile vertically. Mirror, Clamp, or Wrap.
Default Value: Wrap