CrabUI
Loading...
Searching...
No Matches
CrabUITest.LayoutTest Class Reference

Testing Layouts. More...

Inheritance diagram for CrabUITest.LayoutTest:
CrabUITest.FillMethods

Static Public Member Functions

static void Grid (CUIComponent Host)
 
- Static Public Member Functions inherited from CrabUITest.FillMethods
static bool IsTestMethod (MethodInfo mi)
 

Detailed Description

Testing Layouts.

Definition at line 20 of file GridLayoutTest.cs.

Member Function Documentation

◆ Grid()

static void CrabUITest.LayoutTest.Grid ( CUIComponent Host)
static

Definition at line 22 of file GridLayoutTest.cs.

23 {
24 CUIFrame frame = new CUIFrame(0.2f, 0.2f, 0.6f, 0.6f);
25
26 CUIGrid grid = new CUIGrid()
27 {
28 Absolute = new CUINullRect(100, 100, 100, 100),
29
30 GridTemplateColumns = "75% 25%",
31 GridTemplateRows = "50% 50%",
32 };
33
34 grid.Append(new CUIComponent()
35 {
36 BackgroundColor = Color.Blue,
37 GridCell = new Point(0, 0),
38 });
39
40 frame.Append(grid);
41
42 Host.Append(frame);
43 }
Base class for all components.
virtual CUIComponent Append(CUIComponent child, string name=null, [CallerMemberName] string memberName="")
Adds children to the end of the list.
Draggable and resizable container for other components.
Definition CUIFrame.cs:16
A Grid containing children in its cells.
Definition CUIGrid.cs:16
Rectangle with float?
Definition CUIRect.cs:104

The documentation for this class was generated from the following file: