feat: implement nested border-box layout and alignment
This commit is contained in:
@@ -43,6 +43,7 @@ pub const TYPE_NAMES: &[&str] = &[
|
||||
"Spacer",
|
||||
"Row",
|
||||
"Column",
|
||||
"Overlay",
|
||||
"Button",
|
||||
"Page",
|
||||
"Window",
|
||||
@@ -143,6 +144,7 @@ enum Operation {
|
||||
Scroll,
|
||||
Row,
|
||||
Column,
|
||||
Overlay,
|
||||
Button,
|
||||
Page,
|
||||
SetText,
|
||||
@@ -186,7 +188,7 @@ impl Operation {
|
||||
Rect => (2, 4),
|
||||
MoveTab | MoveWindow | OpenValue | Spacer | SetText | SetColor | Append | Remove
|
||||
| Render | Navigate | OnClick | Present => (1, 1),
|
||||
Row | Column => (2, MAX_UI_NODES + 2),
|
||||
Row | Column | Overlay => (2, MAX_UI_NODES + 2),
|
||||
Button => (1, 1),
|
||||
Insert | Replace | Move => (2, 2),
|
||||
Page | Unmount | Close | Activate | Back | Forward | Children | NewWindow
|
||||
@@ -425,6 +427,7 @@ fn new_typed_block(
|
||||
Kind::Scroll { .. } => "ScrollBlock",
|
||||
Kind::Row => "Row",
|
||||
Kind::Column => "Column",
|
||||
Kind::Overlay => "Overlay",
|
||||
Kind::Button => "Button",
|
||||
Kind::Page => "Page",
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user