Esempio n. 1
0
 public static Rect AddRectangle(this IControlContainer container, float x, float y, int w, int h, Color?fillColor = null, Color?borderColor = null)
 => container.AddControlPassThrough(new Rect(container, x, y, w, h)
 {
     BorderColor     = borderColor,
     BackgroundColor = fillColor,
 });
Esempio n. 2
0
 public static Line AddLine(this IControlContainer container, int x1, int y1, int x2, int y2, int thickness = 1)
 => container.AddControlPassThrough(new Line(container, x1, y1, x2, y2, thickness));
Esempio n. 3
0
 public static Line AddLine(this IControlContainer container, float x1, float y1, float x2, float y2, int thickness = 1)
 => container.AddControlPassThrough(new Line(container, (int)x1, (int)y1, (int)x2, (int)y2, thickness));
Esempio n. 4
0
 public static TextBox AddTextBox(this IControlContainer container, float x, float y, int width, string text = "", int fontIndex = 0)
 => container.AddControlPassThrough(new TextBox(container, x, y, width)
 {
     Text      = text,
     FontIndex = fontIndex
 });