ColoredRectangleRuntime
Introduction
The ColoredRectangleRuntime is a visual object which displays a solid-color rectangle. It can be used to display solid colors, but can also display gradients.
ColoredRectangleRuntime is often used as a colored background or a health bar.
Code Example
The following code creates a ColoredRectangleRuntime:
var coloredRectangleRuntime = new ColoredRectangleRuntime();
coloredRectangleRuntime.Color = Color.White;
coloredRectangleRuntime.Width = 100;
coloredRectangleRuntime.Height = 100;
coloredRectangleRuntime.AddToManagers();The output is a white rectangle:
Last updated
Was this helpful?

