Files
yoga/src/__tests__/Layout-test.c

6531 lines
216 KiB
C
Raw Normal View History

#include "../Layout.h"
2014-04-28 12:36:36 -07:00
#include "../Layout-test-utils.h"
2014-04-18 17:15:03 -07:00
2014-06-11 21:00:57 -07:00
// @generated by transpile.html
int main()
{
2014-04-18 17:15:03 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 100;
node_0->style.dimensions[CSS_HEIGHT] = 200;
2014-04-19 14:26:19 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 100;
node_0->layout.dimensions[CSS_HEIGHT] = 200;
2014-04-19 14:26:19 -07:00
}
2014-04-19 14:35:54 -07:00
test("should layout a single node with width and height", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 3);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 500;
node_1->style.dimensions[CSS_HEIGHT] = 500;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 250;
node_1->style.dimensions[CSS_HEIGHT] = 250;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 2);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 125;
node_1->style.dimensions[CSS_HEIGHT] = 125;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 3);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 500;
node_1->layout.dimensions[CSS_HEIGHT] = 500;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 500;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 250;
node_1->layout.dimensions[CSS_HEIGHT] = 250;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 2);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 750;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 125;
node_1->layout.dimensions[CSS_HEIGHT] = 125;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with children", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-18 17:15:03 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 500;
node_1->style.dimensions[CSS_HEIGHT] = 500;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 500;
node_1->style.dimensions[CSS_HEIGHT] = 500;
init_css_node_children(node_1, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-05-16 18:04:24 -07:00
node_2->style.dimensions[CSS_WIDTH] = 250;
node_2->style.dimensions[CSS_HEIGHT] = 250;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 1);
2014-05-16 18:04:24 -07:00
node_2->style.dimensions[CSS_WIDTH] = 250;
node_2->style.dimensions[CSS_HEIGHT] = 250;
2014-04-19 14:26:19 -07:00
}
}
2014-04-18 17:15:03 -07:00
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 500;
node_1->layout.dimensions[CSS_HEIGHT] = 500;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 500;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 500;
node_1->layout.dimensions[CSS_HEIGHT] = 500;
init_css_node_children(node_1, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-05-16 18:04:24 -07:00
node_2->layout.position[CSS_TOP] = 0;
node_2->layout.position[CSS_LEFT] = 0;
node_2->layout.dimensions[CSS_WIDTH] = 250;
node_2->layout.dimensions[CSS_HEIGHT] = 250;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 1);
2014-05-16 18:04:24 -07:00
node_2->layout.position[CSS_TOP] = 250;
node_2->layout.position[CSS_LEFT] = 0;
node_2->layout.dimensions[CSS_WIDTH] = 250;
node_2->layout.dimensions[CSS_HEIGHT] = 250;
2014-04-19 14:26:19 -07:00
}
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with nested children", root_node, root_layout);
2014-04-18 17:15:03 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 100;
node_0->style.dimensions[CSS_HEIGHT] = 200;
node_0->style.margin[CSS_LEFT] = 10;
node_0->style.margin[CSS_TOP] = 10;
node_0->style.margin[CSS_RIGHT] = 10;
node_0->style.margin[CSS_BOTTOM] = 10;
2014-04-19 14:26:19 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 10;
node_0->layout.position[CSS_LEFT] = 10;
node_0->layout.dimensions[CSS_WIDTH] = 100;
node_0->layout.dimensions[CSS_HEIGHT] = 200;
2014-04-19 14:26:19 -07:00
}
2014-04-19 14:35:54 -07:00
test("should layout node with margin", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
node_0->style.margin[CSS_LEFT] = 10;
node_0->style.margin[CSS_TOP] = 10;
node_0->style.margin[CSS_RIGHT] = 10;
node_0->style.margin[CSS_BOTTOM] = 10;
init_css_node_children(node_0, 3);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
node_1->style.margin[CSS_LEFT] = 50;
node_1->style.margin[CSS_TOP] = 50;
node_1->style.margin[CSS_RIGHT] = 50;
node_1->style.margin[CSS_BOTTOM] = 50;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
node_1->style.margin[CSS_LEFT] = 25;
node_1->style.margin[CSS_TOP] = 25;
node_1->style.margin[CSS_RIGHT] = 25;
node_1->style.margin[CSS_BOTTOM] = 25;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 2);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
node_1->style.margin[CSS_LEFT] = 10;
node_1->style.margin[CSS_TOP] = 10;
node_1->style.margin[CSS_RIGHT] = 10;
node_1->style.margin[CSS_BOTTOM] = 10;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 10;
node_0->layout.position[CSS_LEFT] = 10;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 3);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 50;
node_1->layout.position[CSS_LEFT] = 50;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 225;
node_1->layout.position[CSS_LEFT] = 25;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 2);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 360;
node_1->layout.position[CSS_LEFT] = 10;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with several children", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 200;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 300;
node_1->style.dimensions[CSS_HEIGHT] = 150;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 200;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 100;
node_1->layout.dimensions[CSS_WIDTH] = 300;
node_1->layout.dimensions[CSS_HEIGHT] = 150;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with row flex direction", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 300;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 200;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 300;
node_1->style.dimensions[CSS_HEIGHT] = 150;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 300;
node_0->layout.dimensions[CSS_HEIGHT] = 350;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 200;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 200;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 300;
node_1->layout.dimensions[CSS_HEIGHT] = 150;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node based on children main dimensions", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 200;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.flex = 1;
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 200;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 200;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 800;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with flex", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 1);
2014-04-18 17:15:03 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex = 1;
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 1000;
init_css_node_children(node_1, 1);
{
2014-05-16 18:04:24 -07:00
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.flex = 1;
2014-05-16 18:04:24 -07:00
node_2->style.dimensions[CSS_WIDTH] = 1000;
init_css_node_children(node_2, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_3;
2014-09-11 09:23:30 -07:00
node_3 = node_2->get_child(node_2->context, 0);
node_3->style.flex = 1;
2014-05-16 18:04:24 -07:00
node_3->style.dimensions[CSS_WIDTH] = 1000;
2014-04-19 14:26:19 -07:00
}
}
2014-04-18 17:15:03 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 1000;
node_1->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_1, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-05-16 18:04:24 -07:00
node_2->layout.position[CSS_TOP] = 0;
node_2->layout.position[CSS_LEFT] = 0;
node_2->layout.dimensions[CSS_WIDTH] = 1000;
node_2->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_2, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_3;
2014-09-11 09:23:30 -07:00
node_3 = node_2->get_child(node_2->context, 0);
2014-05-16 18:04:24 -07:00
node_3->layout.position[CSS_TOP] = 0;
node_3->layout.position[CSS_LEFT] = 0;
node_3->layout.dimensions[CSS_WIDTH] = 1000;
node_3->layout.dimensions[CSS_HEIGHT] = 1000;
2014-04-19 14:26:19 -07:00
}
}
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with flex recursively", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
node_0->style.margin[CSS_LEFT] = 5;
node_0->style.margin[CSS_TOP] = 10;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
node_1->style.margin[CSS_LEFT] = 15;
node_1->style.margin[CSS_TOP] = 50;
node_1->style.margin[CSS_BOTTOM] = 20;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
node_1->style.margin[CSS_LEFT] = 30;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 10;
node_0->layout.position[CSS_LEFT] = 5;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 50;
node_1->layout.position[CSS_LEFT] = 15;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 170;
node_1->layout.position[CSS_LEFT] = 30;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with targeted margin", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 100;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with justifyContent: flex-start", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 800;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 900;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with justifyContent: flex-end", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_BETWEEN;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 900;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with justifyContent: space-between", root_node, root_layout);
2014-04-19 14:26:19 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_AROUND;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 200;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 700;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with justifyContent: space-around", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_CENTER;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 400;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 500;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with justifyContent: center", root_node, root_layout);
}
2014-04-18 17:15:03 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex = 1;
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 1000;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with flex override height", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.align_items = CSS_ALIGN_FLEX_START;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 200;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 200;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 100;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with alignItems: flex-start", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.align_items = CSS_ALIGN_CENTER;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 200;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 400;
node_1->layout.dimensions[CSS_WIDTH] = 200;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 100;
node_1->layout.position[CSS_LEFT] = 450;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with alignItems: center", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.align_items = CSS_ALIGN_FLEX_END;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 200;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 800;
node_1->layout.dimensions[CSS_WIDTH] = 200;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 100;
node_1->layout.position[CSS_LEFT] = 900;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with alignItems: flex-end", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.align_items = CSS_ALIGN_FLEX_END;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_WIDTH] = 200;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.align_self = CSS_ALIGN_CENTER;
node_1->style.dimensions[CSS_WIDTH] = 100;
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 800;
node_1->layout.dimensions[CSS_WIDTH] = 200;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 100;
node_1->layout.position[CSS_LEFT] = 450;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with alignSelf overrides alignItems", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.align_items = CSS_ALIGN_STRETCH;
node_0->style.dimensions[CSS_WIDTH] = 1000;
node_0->style.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 1000;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 1000;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with alignItem: stretch", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout empty node", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.margin[CSS_LEFT] = 5;
node_1->style.margin[CSS_TOP] = 5;
node_1->style.margin[CSS_RIGHT] = 5;
node_1->style.margin[CSS_BOTTOM] = 5;
2014-04-19 14:26:19 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 10;
node_0->layout.dimensions[CSS_HEIGHT] = 10;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 5;
node_1->layout.position[CSS_LEFT] = 5;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout child with margin", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_HEIGHT] = 200;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 100;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 200;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should not shrink children if not enough space", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_CENTER;
2014-04-19 14:26:19 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
2014-04-19 14:35:54 -07:00
test("should layout for center", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_0->style.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.margin[CSS_TOP] = 10;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 100;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout flex-end taking into account margin", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.align_items = CSS_ALIGN_FLEX_END;
init_css_node_children(node_1, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-05-16 18:04:24 -07:00
node_2->style.margin[CSS_LEFT] = 10;
node_2->style.margin[CSS_TOP] = 10;
node_2->style.margin[CSS_RIGHT] = 10;
node_2->style.margin[CSS_BOTTOM] = 10;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 1);
2014-05-16 18:04:24 -07:00
node_2->style.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 20;
node_0->layout.dimensions[CSS_HEIGHT] = 120;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 20;
node_1->layout.dimensions[CSS_HEIGHT] = 120;
init_css_node_children(node_1, 2);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-05-16 18:04:24 -07:00
node_2->layout.position[CSS_TOP] = 10;
node_2->layout.position[CSS_LEFT] = 10;
node_2->layout.dimensions[CSS_WIDTH] = 0;
node_2->layout.dimensions[CSS_HEIGHT] = 0;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 1);
2014-05-16 18:04:24 -07:00
node_2->layout.position[CSS_TOP] = 20;
node_2->layout.position[CSS_LEFT] = 20;
node_2->layout.dimensions[CSS_WIDTH] = 0;
node_2->layout.dimensions[CSS_HEIGHT] = 100;
2014-04-19 14:26:19 -07:00
}
}
}
2014-04-19 14:35:54 -07:00
test("should layout alignItems with margin", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex = 1;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout flex inside of an empty element", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.align_items = CSS_ALIGN_STRETCH;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.margin[CSS_LEFT] = 10;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 10;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 10;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout alignItems stretch and margin", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.padding[CSS_LEFT] = 5;
node_0->style.padding[CSS_TOP] = 5;
node_0->style.padding[CSS_RIGHT] = 5;
node_0->style.padding[CSS_BOTTOM] = 5;
2014-04-19 14:26:19 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 10;
node_0->layout.dimensions[CSS_HEIGHT] = 10;
2014-04-19 14:26:19 -07:00
}
2014-04-19 14:35:54 -07:00
test("should layout node with padding", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.padding[CSS_LEFT] = 5;
node_0->style.padding[CSS_TOP] = 5;
node_0->style.padding[CSS_RIGHT] = 5;
node_0->style.padding[CSS_BOTTOM] = 5;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 10;
node_0->layout.dimensions[CSS_HEIGHT] = 10;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 5;
node_1->layout.position[CSS_LEFT] = 5;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with padding and a child", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.padding[CSS_LEFT] = 5;
node_0->style.padding[CSS_TOP] = 5;
node_0->style.padding[CSS_RIGHT] = 5;
node_0->style.padding[CSS_BOTTOM] = 5;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.margin[CSS_LEFT] = 5;
node_1->style.margin[CSS_TOP] = 5;
node_1->style.margin[CSS_RIGHT] = 5;
node_1->style.margin[CSS_BOTTOM] = 5;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 20;
node_0->layout.dimensions[CSS_HEIGHT] = 20;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 10;
node_1->layout.position[CSS_LEFT] = 10;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with padding and a child with margin", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.align_self = CSS_ALIGN_STRETCH;
node_1->style.padding[CSS_LEFT] = 10;
node_1->style.padding[CSS_TOP] = 10;
node_1->style.padding[CSS_RIGHT] = 10;
node_1->style.padding[CSS_BOTTOM] = 10;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 20;
node_0->layout.dimensions[CSS_HEIGHT] = 20;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 20;
node_1->layout.dimensions[CSS_HEIGHT] = 20;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with padding and stretch", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.padding[CSS_LEFT] = 50;
node_0->style.padding[CSS_TOP] = 50;
node_0->style.padding[CSS_RIGHT] = 50;
node_0->style.padding[CSS_BOTTOM] = 50;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.align_self = CSS_ALIGN_STRETCH;
node_1->style.padding[CSS_LEFT] = 10;
node_1->style.padding[CSS_TOP] = 10;
node_1->style.padding[CSS_RIGHT] = 10;
node_1->style.padding[CSS_BOTTOM] = 10;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 120;
node_0->layout.dimensions[CSS_HEIGHT] = 120;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 50;
node_1->layout.position[CSS_LEFT] = 50;
node_1->layout.dimensions[CSS_WIDTH] = 20;
node_1->layout.dimensions[CSS_HEIGHT] = 20;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with inner & outer padding and stretch", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.align_self = CSS_ALIGN_STRETCH;
init_css_node_children(node_1, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-05-16 18:04:24 -07:00
node_2->style.margin[CSS_LEFT] = 16;
node_2->style.margin[CSS_TOP] = 16;
node_2->style.margin[CSS_RIGHT] = 16;
node_2->style.margin[CSS_BOTTOM] = 16;
2014-04-19 14:26:19 -07:00
}
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 32;
node_0->layout.dimensions[CSS_HEIGHT] = 32;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 32;
node_1->layout.dimensions[CSS_HEIGHT] = 32;
init_css_node_children(node_1, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-05-16 18:04:24 -07:00
node_2->layout.position[CSS_TOP] = 16;
node_2->layout.position[CSS_LEFT] = 16;
node_2->layout.dimensions[CSS_WIDTH] = 0;
node_2->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with stretch and child with margin", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.position[CSS_LEFT] = 5;
node_0->style.position[CSS_TOP] = 5;
2014-04-19 14:26:19 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 5;
node_0->layout.position[CSS_LEFT] = 5;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
2014-04-19 14:35:54 -07:00
test("should layout node with top and left", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_AROUND;
node_0->style.dimensions[CSS_HEIGHT] = 10;
node_0->style.padding[CSS_TOP] = 5;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:26:19 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 10;
init_css_node_children(node_0, 1);
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 7.5;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
}
2014-04-19 14:35:54 -07:00
test("should layout node with height, padding and space-around", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.position[CSS_BOTTOM] = 5;
2014-04-19 14:26:19 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = -5;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
2014-04-19 14:35:54 -07:00
test("should layout node with bottom", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.position[CSS_TOP] = 10;
node_0->style.position[CSS_BOTTOM] = 5;
2014-04-19 14:26:19 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 14:26:19 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 10;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 14:26:19 -07:00
}
2014-04-19 14:35:54 -07:00
test("should layout node with both top and bottom", root_node, root_layout);
2014-04-18 17:15:03 -07:00
}
2014-04-19 22:08:10 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 500;
init_css_node_children(node_0, 3);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex = 1;
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.dimensions[CSS_WIDTH] = 50;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 2);
node_1->style.flex = 1;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 500;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 3);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 250;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 250;
node_1->layout.dimensions[CSS_WIDTH] = 50;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 2);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 250;
node_1->layout.dimensions[CSS_WIDTH] = 250;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with position: absolute", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.margin[CSS_RIGHT] = 15;
2014-04-19 22:08:10 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 22:08:10 -07:00
}
}
2014-04-22 13:18:05 -07:00
test("should layout node with child with position: absolute and margin", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.align_self = CSS_ALIGN_CENTER;
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.padding[CSS_RIGHT] = 12;
2014-04-19 22:08:10 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 12;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 22:08:10 -07:00
}
}
2014-04-22 13:18:05 -07:00
test("should layout node with position: absolute, padding and alignSelf: center", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_HEIGHT] = 5;
node_0->style.padding[CSS_BOTTOM] = 20;
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 20;
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should work with height smaller than paddingBottom", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 5;
node_0->style.padding[CSS_LEFT] = 20;
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 20;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should work with width smaller than paddingLeft", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 2);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
init_css_node_children(node_1, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-05-16 18:04:24 -07:00
node_2->style.dimensions[CSS_WIDTH] = 400;
2014-04-22 13:18:05 -07:00
}
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.align_self = CSS_ALIGN_STRETCH;
node_1->style.dimensions[CSS_WIDTH] = 200;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 400;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 2);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 400;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_1, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-05-16 18:04:24 -07:00
node_2->layout.position[CSS_TOP] = 0;
node_2->layout.position[CSS_LEFT] = 0;
node_2->layout.dimensions[CSS_WIDTH] = 400;
node_2->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 200;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with specified width and stretch", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.padding[CSS_LEFT] = 5;
node_0->style.padding[CSS_TOP] = 5;
node_0->style.padding[CSS_RIGHT] = 5;
node_0->style.padding[CSS_BOTTOM] = 5;
init_css_node_children(node_0, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 10;
node_0->layout.dimensions[CSS_HEIGHT] = 10;
init_css_node_children(node_0, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 5;
node_1->layout.position[CSS_LEFT] = 5;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with padding and child with position absolute", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 2);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.position[CSS_LEFT] = 10;
node_1->style.position[CSS_TOP] = 10;
2014-04-19 22:08:10 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 2);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 10;
node_1->layout.position[CSS_LEFT] = 10;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 22:08:10 -07:00
}
}
2014-04-22 13:18:05 -07:00
test("should layout node with position absolute, top and left", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.padding[CSS_LEFT] = 20;
node_0->style.padding[CSS_TOP] = 20;
node_0->style.padding[CSS_RIGHT] = 20;
node_0->style.padding[CSS_BOTTOM] = 20;
init_css_node_children(node_0, 1);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.position[CSS_LEFT] = 5;
2014-04-19 22:08:10 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 40;
node_0->layout.dimensions[CSS_HEIGHT] = 40;
init_css_node_children(node_0, 1);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 20;
node_1->layout.position[CSS_LEFT] = 5;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 22:08:10 -07:00
}
}
2014-04-22 13:18:05 -07:00
test("should layout node with padding and child position absolute, left", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.margin[CSS_TOP] = 5;
node_1->style.position[CSS_TOP] = 5;
2014-04-19 22:08:10 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 10;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 22:08:10 -07:00
}
}
2014-04-22 13:18:05 -07:00
test("should layout node with position: absolute, top and marginTop", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.margin[CSS_LEFT] = 5;
node_1->style.position[CSS_LEFT] = 5;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 10;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with position: absolute, left and marginLeft", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_AROUND;
node_0->style.dimensions[CSS_HEIGHT] = 200;
init_css_node_children(node_0, 2);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 200;
init_css_node_children(node_0, 2);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 100;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 100;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with space-around and child position absolute", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 700;
init_css_node_children(node_0, 1);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex = 1;
2014-05-16 18:04:24 -07:00
node_1->style.margin[CSS_LEFT] = 5;
2014-04-19 22:08:10 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 700;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 5;
node_1->layout.dimensions[CSS_WIDTH] = 695;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 22:08:10 -07:00
}
}
2014-04-22 13:18:05 -07:00
test("should layout node with flex and main margin", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 700;
init_css_node_children(node_0, 2);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex = 1;
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.flex = 1;
2014-05-16 18:04:24 -07:00
node_1->style.padding[CSS_RIGHT] = 5;
2014-04-19 22:08:10 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 700;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 2);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 347.5;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 347.5;
node_1->layout.dimensions[CSS_WIDTH] = 352.5;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 22:08:10 -07:00
}
}
2014-04-22 13:18:05 -07:00
test("should layout node with multiple flex and padding", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 700;
init_css_node_children(node_0, 2);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex = 1;
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.flex = 1;
2014-05-16 18:04:24 -07:00
node_1->style.margin[CSS_LEFT] = 5;
2014-04-19 22:08:10 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 700;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 2);
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 347.5;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 352.5;
node_1->layout.dimensions[CSS_WIDTH] = 347.5;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-19 22:08:10 -07:00
}
}
2014-04-22 13:18:05 -07:00
test("should layout node with multiple flex and margin", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_HEIGHT] = 300;
init_css_node_children(node_0, 2);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.dimensions[CSS_HEIGHT] = 600;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.flex = 1;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 300;
init_css_node_children(node_0, 2);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 600;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 600;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with flex and overflow", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 600;
init_css_node_children(node_0, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
2014-09-11 09:23:30 -07:00
node_1->style.flex = 1;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 600;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with flex and position absolute", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_HEIGHT] = 500;
init_css_node_children(node_0, 2);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex = 1;
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
2014-09-11 09:23:30 -07:00
node_1->style.flex = 1;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 500;
init_css_node_children(node_0, 2);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 500;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 500;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with double flex and position absolute", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.border[CSS_LEFT] = 5;
node_0->style.border[CSS_TOP] = 5;
node_0->style.border[CSS_RIGHT] = 5;
node_0->style.border[CSS_BOTTOM] = 5;
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 10;
node_0->layout.dimensions[CSS_HEIGHT] = 10;
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with borderWidth", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.border[CSS_TOP] = 1;
init_css_node_children(node_0, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.position[CSS_TOP] = -1;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 1;
init_css_node_children(node_0, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with borderWidth and position: absolute, top", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.border[CSS_TOP] = 1;
node_0->style.border[CSS_RIGHT] = 1;
node_0->style.border[CSS_BOTTOM] = 1;
init_css_node_children(node_0, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.position[CSS_LEFT] = 5;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-19 22:08:10 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 2;
node_0->layout.dimensions[CSS_HEIGHT] = 2;
init_css_node_children(node_0, 1);
2014-04-22 13:18:05 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 1;
node_1->layout.position[CSS_LEFT] = 6;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 13:18:05 -07:00
}
2014-04-19 22:08:10 -07:00
}
2014-04-22 13:18:05 -07:00
test("should layout node with borderWidth and position: absolute, top. cross axis", root_node, root_layout);
2014-04-19 22:08:10 -07:00
}
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 50;
init_css_node_children(node_0, 1);
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.align_self = CSS_ALIGN_STRETCH;
node_1->style.margin[CSS_LEFT] = 20;
node_1->style.padding[CSS_LEFT] = 20;
node_1->style.padding[CSS_TOP] = 20;
node_1->style.padding[CSS_RIGHT] = 20;
node_1->style.padding[CSS_BOTTOM] = 20;
2014-04-22 14:59:59 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 50;
node_0->layout.dimensions[CSS_HEIGHT] = 40;
init_css_node_children(node_0, 1);
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 20;
node_1->layout.dimensions[CSS_WIDTH] = 40;
node_1->layout.dimensions[CSS_HEIGHT] = 40;
2014-04-22 14:59:59 -07:00
}
}
test("should correctly take into account min padding for stretch", root_node, root_layout);
}
2014-04-22 17:37:55 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 17:37:55 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
2014-04-22 17:37:55 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.border[CSS_RIGHT] = 5;
2014-04-22 17:37:55 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 17:37:55 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 5;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-22 17:37:55 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 5;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 17:37:55 -07:00
}
}
test("should layout node with negative width", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 17:37:55 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.border[CSS_RIGHT] = 1;
init_css_node_children(node_0, 1);
2014-04-22 17:37:55 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.margin[CSS_RIGHT] = -8;
2014-04-22 17:37:55 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 17:37:55 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-22 17:37:55 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 17:37:55 -07:00
}
}
test("should handle negative margin and min padding correctly", root_node, root_layout);
}
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 34.671875;
2014-05-16 18:04:24 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 18;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("should layout node with just text", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 10;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 10;
node_0->layout.dimensions[CSS_HEIGHT] = 18;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("should layout node with text and width", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 172.421875;
node_0->layout.dimensions[CSS_HEIGHT] = 18;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("should layout node with text, padding and margin", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 300;
2014-05-16 18:04:24 -07:00
init_css_node_children(node_0, 1);
2014-04-28 12:34:04 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.align_self = CSS_ALIGN_STRETCH;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.align_self = CSS_ALIGN_STRETCH;
}
2014-04-28 12:34:04 -07:00
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 300;
2014-05-16 18:04:24 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
2014-04-28 12:34:04 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 300;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 0;
node_2->layout.position[CSS_LEFT] = 0;
node_2->layout.dimensions[CSS_WIDTH] = 300;
node_2->layout.dimensions[CSS_HEIGHT] = 0;
}
2014-04-28 12:34:04 -07:00
}
2014-04-22 14:59:59 -07:00
}
test("should layout node with nested alignSelf: stretch", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_1->style.dimensions[CSS_WIDTH] = 500;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.flex = 1;
2014-06-11 21:00:57 -07:00
node_2->measure = measure;
node_2->context = "loooooooooong with space";
}
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 500;
node_0->layout.dimensions[CSS_HEIGHT] = 18;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 500;
node_1->layout.dimensions[CSS_HEIGHT] = 18;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 0;
node_2->layout.position[CSS_LEFT] = 0;
node_2->layout.dimensions[CSS_WIDTH] = 500;
node_2->layout.dimensions[CSS_HEIGHT] = 18;
}
}
}
test("should layout node with text and flex", root_node, root_layout);
}
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 130;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.align_items = CSS_ALIGN_STRETCH;
node_1->style.align_self = CSS_ALIGN_STRETCH;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-06-11 21:00:57 -07:00
node_2->measure = measure;
node_2->context = "loooooooooong with space";
}
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 130;
node_0->layout.dimensions[CSS_HEIGHT] = 36;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 130;
node_1->layout.dimensions[CSS_HEIGHT] = 36;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 0;
node_2->layout.position[CSS_LEFT] = 0;
node_2->layout.dimensions[CSS_WIDTH] = 130;
node_2->layout.dimensions[CSS_HEIGHT] = 36;
}
}
2014-04-22 14:59:59 -07:00
}
test("should layout node with text and stretch", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 200;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.align_items = CSS_ALIGN_STRETCH;
node_1->style.align_self = CSS_ALIGN_STRETCH;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.dimensions[CSS_WIDTH] = 130;
2014-06-11 21:00:57 -07:00
node_2->measure = measure;
node_2->context = "loooooooooong with space";
}
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 200;
node_0->layout.dimensions[CSS_HEIGHT] = 36;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 200;
node_1->layout.dimensions[CSS_HEIGHT] = 36;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 0;
node_2->layout.position[CSS_LEFT] = 0;
node_2->layout.dimensions[CSS_WIDTH] = 130;
node_2->layout.dimensions[CSS_HEIGHT] = 36;
}
}
2014-04-22 14:59:59 -07:00
}
test("should layout node with text stretch and width", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 100;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "loooooooooong with space";
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 100;
node_0->layout.dimensions[CSS_HEIGHT] = 36;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100.453125;
node_1->layout.dimensions[CSS_HEIGHT] = 36;
}
2014-04-22 14:59:59 -07:00
}
test("should layout node with text bounded by parent", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 100;
node_0->style.padding[CSS_LEFT] = 10;
node_0->style.padding[CSS_TOP] = 10;
node_0->style.padding[CSS_RIGHT] = 10;
node_0->style.padding[CSS_BOTTOM] = 10;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.margin[CSS_LEFT] = 10;
node_1->style.margin[CSS_TOP] = 10;
node_1->style.margin[CSS_RIGHT] = 10;
node_1->style.margin[CSS_BOTTOM] = 10;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
2014-06-11 21:00:57 -07:00
node_2->measure = measure;
node_2->context = "loooooooooong with space";
}
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
2014-05-16 18:04:24 -07:00
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 100;
node_0->layout.dimensions[CSS_HEIGHT] = 76;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 20;
node_1->layout.position[CSS_LEFT] = 20;
node_1->layout.dimensions[CSS_WIDTH] = 100.453125;
node_1->layout.dimensions[CSS_HEIGHT] = 36;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 0;
node_2->layout.position[CSS_LEFT] = 0;
node_2->layout.dimensions[CSS_WIDTH] = 100.453125;
node_2->layout.dimensions[CSS_HEIGHT] = 36;
}
}
2014-04-22 14:59:59 -07:00
}
test("should layout node with text bounded by grand-parent", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_BETWEEN;
node_0->style.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.dimensions[CSS_HEIGHT] = 900;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 900;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->layout.position[CSS_TOP] = 900;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
}
2014-04-22 14:59:59 -07:00
}
test("should layout space-between when remaining space is negative", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_0->style.dimensions[CSS_WIDTH] = 200;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.dimensions[CSS_WIDTH] = 900;
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 200;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = -700;
node_1->layout.dimensions[CSS_WIDTH] = 900;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
}
}
test("should layout flex-end when remaining space is negative", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_1->style.dimensions[CSS_WIDTH] = 200;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.margin[CSS_LEFT] = 20;
node_2->style.margin[CSS_TOP] = 20;
node_2->style.margin[CSS_RIGHT] = 20;
node_2->style.margin[CSS_BOTTOM] = 20;
2014-06-11 21:00:57 -07:00
node_2->measure = measure;
node_2->context = "loooooooooong with space";
}
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 200;
node_0->layout.dimensions[CSS_HEIGHT] = 58;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 200;
node_1->layout.dimensions[CSS_HEIGHT] = 58;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 20;
node_2->layout.position[CSS_LEFT] = 20;
node_2->layout.dimensions[CSS_WIDTH] = 172.421875;
node_2->layout.dimensions[CSS_HEIGHT] = 18;
}
}
}
test("should layout text with flexDirection row", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.dimensions[CSS_WIDTH] = 200;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.margin[CSS_LEFT] = 20;
node_2->style.margin[CSS_TOP] = 20;
node_2->style.margin[CSS_RIGHT] = 20;
node_2->style.margin[CSS_BOTTOM] = 20;
2014-06-11 21:00:57 -07:00
node_2->measure = measure;
node_2->context = "loooooooooong with space";
}
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 200;
node_0->layout.dimensions[CSS_HEIGHT] = 76;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 200;
node_1->layout.dimensions[CSS_HEIGHT] = 76;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 20;
node_2->layout.position[CSS_LEFT] = 20;
node_2->layout.dimensions[CSS_WIDTH] = 160;
node_2->layout.dimensions[CSS_HEIGHT] = 36;
}
}
}
test("should layout with text and margin", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 100;
node_0->style.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.position[CSS_LEFT] = 0;
node_1->style.position[CSS_TOP] = 0;
node_1->style.position[CSS_RIGHT] = 0;
node_1->style.position[CSS_BOTTOM] = 0;
}
}
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 100;
node_0->layout.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
}
}
test("should layout with position absolute, top, left, bottom, right", root_node, root_layout);
}
{
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 100;
node_0->style.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex = 2.5;
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.flex = 7.5;
}
}
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 100;
node_0->layout.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 25;
node_1 = node_0->get_child(node_0->context, 1);
node_1->layout.position[CSS_TOP] = 25;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 75;
}
}
test("should layout with arbitrary flex", root_node, root_layout);
}
{
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 100;
node_0->style.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.flex = 0;
}
}
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 100;
node_0->layout.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
node_1 = node_0->get_child(node_0->context, 1);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
}
}
test("should layout with negative flex", root_node, root_layout);
}
{
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.dimensions[CSS_WIDTH] = 50;
node_1->style.dimensions[CSS_HEIGHT] = 100;
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.position[CSS_LEFT] = 0;
node_1->style.position[CSS_RIGHT] = 0;
}
}
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 50;
node_0->layout.dimensions[CSS_HEIGHT] = 100;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 50;
node_1->layout.dimensions[CSS_HEIGHT] = 100;
node_1 = node_0->get_child(node_0->context, 1);
node_1->layout.position[CSS_TOP] = 100;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 50;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
}
}
test("should layout with absolutely position bottom", root_node, root_layout);
}
2014-09-11 09:23:30 -07:00
{
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
node_0->style.align_items = CSS_ALIGN_STRETCH;
node_0->style.dimensions[CSS_WIDTH] = 80;
node_0->style.padding[CSS_LEFT] = 7;
node_0->style.padding[CSS_TOP] = 7;
node_0->style.padding[CSS_RIGHT] = 7;
node_0->style.padding[CSS_BOTTOM] = 7;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 80;
node_0->layout.dimensions[CSS_HEIGHT] = 68;
}
test("should layout text with alignItems: stretch", root_node, root_layout);
}
2014-06-11 21:00:57 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-06-11 21:00:57 -07:00
{
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "loooooooooong with space";
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-06-11 21:00:57 -07:00
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-06-11 21:00:57 -07:00
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 100;
node_1->layout.dimensions[CSS_HEIGHT] = 36;
}
}
test("should layout node with text and position absolute", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_0->style.dimensions[CSS_WIDTH] = 620;
node_0->style.dimensions[CSS_HEIGHT] = 595;
node_0->style.margin[CSS_BOTTOM] = 13;
node_0->style.padding[CSS_LEFT] = 7;
node_0->style.padding[CSS_TOP] = 7;
node_0->style.padding[CSS_RIGHT] = 7;
node_0->style.padding[CSS_BOTTOM] = 7;
node_0->style.border[CSS_RIGHT] = 3;
node_0->measure = measure;
node_0->context = "loooooooooong with space";
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_WIDTH] = 620;
node_0->layout.dimensions[CSS_HEIGHT] = 595;
}
test("Random #0", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 603;
node_0->style.margin[CSS_LEFT] = -5;
node_0->style.padding[CSS_TOP] = 18;
node_0->style.padding[CSS_BOTTOM] = 14;
node_0->style.border[CSS_LEFT] = 2;
node_0->style.border[CSS_TOP] = 2;
node_0->style.border[CSS_RIGHT] = 2;
node_0->style.border[CSS_BOTTOM] = 2;
node_0->style.border[CSS_LEFT] = 2;
node_0->style.position[CSS_TOP] = 6;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 6;
node_0->layout.position[CSS_LEFT] = -5;
node_0->layout.dimensions[CSS_WIDTH] = 603;
node_0->layout.dimensions[CSS_HEIGHT] = 54;
}
test("Random #1", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
}
test("Random #2", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_HEIGHT] = 338;
node_0->style.margin[CSS_LEFT] = -5;
node_0->style.margin[CSS_TOP] = -5;
node_0->style.margin[CSS_RIGHT] = -5;
node_0->style.margin[CSS_BOTTOM] = -5;
node_0->style.margin[CSS_TOP] = 18;
node_0->style.padding[CSS_LEFT] = 10;
node_0->style.padding[CSS_RIGHT] = 13;
node_0->style.border[CSS_TOP] = 3;
node_0->style.border[CSS_BOTTOM] = 1;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 18;
node_0->layout.position[CSS_LEFT] = -5;
node_0->layout.dimensions[CSS_WIDTH] = 195.421875;
node_0->layout.dimensions[CSS_HEIGHT] = 338;
}
test("Random #3", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
2014-05-16 18:04:24 -07:00
node_0->style.dimensions[CSS_WIDTH] = 255;
node_0->style.margin[CSS_RIGHT] = -6;
node_0->style.margin[CSS_BOTTOM] = -3;
node_0->style.padding[CSS_LEFT] = 4;
node_0->style.padding[CSS_TOP] = 4;
node_0->style.padding[CSS_RIGHT] = 4;
node_0->style.padding[CSS_BOTTOM] = 4;
node_0->style.padding[CSS_TOP] = 8;
node_0->style.border[CSS_LEFT] = 2;
node_0->style.border[CSS_TOP] = 2;
node_0->style.border[CSS_RIGHT] = 2;
node_0->style.border[CSS_BOTTOM] = 2;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.border[CSS_RIGHT] = 2;
node_0->style.border[CSS_BOTTOM] = 1;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 255;
node_0->layout.dimensions[CSS_HEIGHT] = 15;
2014-04-22 14:59:59 -07:00
}
test("Random #4", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_HEIGHT] = 116;
node_0->style.margin[CSS_TOP] = 10;
init_css_node_children(node_0, 2);
2014-04-28 12:34:04 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.justify_content = CSS_JUSTIFY_CENTER;
2014-05-16 18:04:24 -07:00
node_1->style.align_self = CSS_ALIGN_FLEX_START;
node_1->style.dimensions[CSS_HEIGHT] = 633;
node_1->style.margin[CSS_LEFT] = 19;
node_1->style.margin[CSS_TOP] = 19;
node_1->style.margin[CSS_RIGHT] = 19;
node_1->style.margin[CSS_BOTTOM] = 19;
node_1->style.margin[CSS_LEFT] = 3;
node_1->style.margin[CSS_TOP] = 17;
node_1->style.margin[CSS_RIGHT] = 8;
node_1->style.border[CSS_LEFT] = 2;
node_1->style.border[CSS_BOTTOM] = 0;
node_1->style.position[CSS_LEFT] = -10;
node_1->style.position[CSS_TOP] = 8;
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "small";
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_1->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_1->style.align_items = CSS_ALIGN_FLEX_END;
2014-05-16 18:04:24 -07:00
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.margin[CSS_LEFT] = 4;
node_1->style.margin[CSS_TOP] = 13;
node_1->style.margin[CSS_RIGHT] = -2;
node_1->style.margin[CSS_BOTTOM] = 1;
node_1->style.padding[CSS_LEFT] = 2;
node_1->style.padding[CSS_TOP] = 2;
node_1->style.padding[CSS_RIGHT] = 2;
node_1->style.padding[CSS_BOTTOM] = 2;
node_1->style.padding[CSS_RIGHT] = 5;
node_1->style.border[CSS_TOP] = 3;
node_1->style.border[CSS_BOTTOM] = 3;
node_1->style.position[CSS_LEFT] = -7;
node_1->style.position[CSS_TOP] = -10;
2014-04-28 12:34:04 -07:00
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 10;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 47.671875;
2014-05-16 18:04:24 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 116;
init_css_node_children(node_0, 2);
2014-04-28 12:34:04 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 25;
node_1->layout.position[CSS_LEFT] = -7;
node_1->layout.dimensions[CSS_WIDTH] = 36.671875;
2014-05-16 18:04:24 -07:00
node_1->layout.dimensions[CSS_HEIGHT] = 633;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
2014-05-16 18:04:24 -07:00
node_1->layout.position[CSS_TOP] = 3;
node_1->layout.position[CSS_LEFT] = -3;
node_1->layout.dimensions[CSS_WIDTH] = 7;
node_1->layout.dimensions[CSS_HEIGHT] = 10;
2014-04-28 12:34:04 -07:00
}
2014-04-22 14:59:59 -07:00
}
test("Random #5", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
2014-05-16 18:04:24 -07:00
node_0->style.justify_content = CSS_JUSTIFY_SPACE_AROUND;
node_0->style.dimensions[CSS_WIDTH] = 426;
node_0->style.dimensions[CSS_HEIGHT] = 497;
node_0->style.margin[CSS_TOP] = 1;
node_0->style.margin[CSS_RIGHT] = 14;
node_0->style.padding[CSS_RIGHT] = 7;
node_0->style.border[CSS_LEFT] = 2;
node_0->style.border[CSS_RIGHT] = 2;
node_0->style.position[CSS_TOP] = -1;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 426;
node_0->layout.dimensions[CSS_HEIGHT] = 497;
2014-04-22 14:59:59 -07:00
}
test("Random #6", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #7", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_AROUND;
node_0->style.align_items = CSS_ALIGN_STRETCH;
node_0->style.dimensions[CSS_HEIGHT] = 757;
node_0->style.margin[CSS_LEFT] = 8;
node_0->style.margin[CSS_TOP] = 6;
node_0->style.margin[CSS_RIGHT] = -1;
node_0->style.margin[CSS_BOTTOM] = 15;
node_0->style.border[CSS_LEFT] = 2;
node_0->style.border[CSS_TOP] = 1;
node_0->style.border[CSS_BOTTOM] = 0;
node_0->style.position[CSS_LEFT] = 5;
node_0->style.position[CSS_TOP] = -2;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.justify_content = CSS_JUSTIFY_SPACE_BETWEEN;
node_1->style.align_items = CSS_ALIGN_CENTER;
node_1->style.margin[CSS_LEFT] = 16;
node_1->style.margin[CSS_TOP] = 16;
node_1->style.margin[CSS_RIGHT] = 16;
node_1->style.margin[CSS_BOTTOM] = 16;
node_1->style.margin[CSS_LEFT] = 11;
node_1->style.margin[CSS_TOP] = -2;
node_1->style.padding[CSS_LEFT] = 3;
node_1->style.padding[CSS_TOP] = 3;
node_1->style.padding[CSS_RIGHT] = 3;
node_1->style.padding[CSS_BOTTOM] = 3;
node_1->style.padding[CSS_TOP] = 18;
node_1->style.border[CSS_TOP] = 1;
node_1->style.border[CSS_BOTTOM] = 3;
node_1->style.position[CSS_LEFT] = -7;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_2->style.align_self = CSS_ALIGN_STRETCH;
node_2->style.dimensions[CSS_HEIGHT] = 626;
node_2->style.margin[CSS_LEFT] = 18;
node_2->style.margin[CSS_TOP] = 18;
node_2->style.margin[CSS_RIGHT] = 18;
node_2->style.margin[CSS_BOTTOM] = 18;
node_2->style.margin[CSS_BOTTOM] = 0;
node_2->style.padding[CSS_RIGHT] = 2;
node_2->style.border[CSS_RIGHT] = 3;
node_2->measure = measure;
node_2->context = "small";
}
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 4;
node_0->layout.position[CSS_LEFT] = 13;
node_0->layout.dimensions[CSS_WIDTH] = 110.671875;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 757;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 35.5;
node_1->layout.position[CSS_LEFT] = 6;
node_1->layout.dimensions[CSS_WIDTH] = 81.671875;
2014-09-11 09:23:30 -07:00
node_1->layout.dimensions[CSS_HEIGHT] = 669;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 37;
node_2->layout.position[CSS_LEFT] = 21;
node_2->layout.dimensions[CSS_WIDTH] = 39.671875;
2014-09-11 09:23:30 -07:00
node_2->layout.dimensions[CSS_HEIGHT] = 626;
}
}
2014-04-22 14:59:59 -07:00
}
test("Random #8", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #9", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
2014-05-16 18:04:24 -07:00
node_0->layout.dimensions[CSS_WIDTH] = 0;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #10", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.align_items = CSS_ALIGN_FLEX_END;
node_0->style.dimensions[CSS_WIDTH] = 179;
node_0->style.margin[CSS_TOP] = 7;
node_0->style.padding[CSS_LEFT] = 5;
node_0->style.padding[CSS_TOP] = 17;
node_0->style.padding[CSS_BOTTOM] = 16;
node_0->style.border[CSS_TOP] = 0;
node_0->style.border[CSS_BOTTOM] = 1;
node_0->style.position[CSS_LEFT] = -4;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_1->style.align_self = CSS_ALIGN_CENTER;
node_1->style.dimensions[CSS_WIDTH] = 277;
node_1->style.margin[CSS_RIGHT] = 6;
node_1->style.margin[CSS_BOTTOM] = -10;
node_1->style.padding[CSS_LEFT] = 4;
node_1->style.padding[CSS_TOP] = 4;
node_1->style.padding[CSS_RIGHT] = 4;
node_1->style.padding[CSS_BOTTOM] = 4;
node_1->style.padding[CSS_LEFT] = 11;
node_1->style.border[CSS_LEFT] = 1;
node_1->style.border[CSS_TOP] = 1;
node_1->style.border[CSS_RIGHT] = 1;
node_1->style.border[CSS_BOTTOM] = 1;
node_1->style.border[CSS_TOP] = 1;
node_1->style.position[CSS_TOP] = 1;
node_1->measure = measure;
node_1->context = "small";
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 7;
node_0->layout.position[CSS_LEFT] = -4;
node_0->layout.dimensions[CSS_WIDTH] = 179;
node_0->layout.dimensions[CSS_HEIGHT] = 52;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 18;
node_1->layout.position[CSS_LEFT] = -49.5;
node_1->layout.dimensions[CSS_WIDTH] = 277;
node_1->layout.dimensions[CSS_HEIGHT] = 28;
}
2014-04-22 14:59:59 -07:00
}
test("Random #11", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_HEIGHT] = 948;
node_0->style.margin[CSS_LEFT] = 10;
node_0->style.margin[CSS_TOP] = 10;
node_0->style.margin[CSS_RIGHT] = 10;
node_0->style.margin[CSS_BOTTOM] = 10;
node_0->style.margin[CSS_TOP] = 6;
node_0->style.margin[CSS_BOTTOM] = -2;
node_0->style.padding[CSS_LEFT] = 7;
node_0->style.padding[CSS_TOP] = 9;
node_0->style.padding[CSS_RIGHT] = 9;
node_0->style.border[CSS_TOP] = 3;
node_0->style.position[CSS_LEFT] = -8;
node_0->style.position[CSS_TOP] = 0;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 6;
node_0->layout.position[CSS_LEFT] = 2;
node_0->layout.dimensions[CSS_WIDTH] = 188.421875;
node_0->layout.dimensions[CSS_HEIGHT] = 948;
2014-04-22 14:59:59 -07:00
}
test("Random #12", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_AROUND;
node_0->style.dimensions[CSS_WIDTH] = 551;
node_0->style.margin[CSS_LEFT] = -9;
node_0->style.margin[CSS_TOP] = -9;
node_0->style.margin[CSS_RIGHT] = -9;
node_0->style.margin[CSS_BOTTOM] = -9;
node_0->style.margin[CSS_TOP] = 12;
node_0->style.border[CSS_TOP] = 1;
node_0->style.position[CSS_LEFT] = 8;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 12;
node_0->layout.position[CSS_LEFT] = -1;
node_0->layout.dimensions[CSS_WIDTH] = 551;
node_0->layout.dimensions[CSS_HEIGHT] = 19;
2014-04-22 14:59:59 -07:00
}
test("Random #13", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.flex = 0;
node_2->measure = measure;
node_2->context = "loooooooooong with space";
}
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 172.421875;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 36;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 172.421875;
2014-09-11 09:23:30 -07:00
node_1->layout.dimensions[CSS_HEIGHT] = 36;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 0;
node_2->layout.position[CSS_LEFT] = 0;
node_2->layout.dimensions[CSS_WIDTH] = 0;
node_2->layout.dimensions[CSS_HEIGHT] = 36;
}
}
2014-04-22 14:59:59 -07:00
}
test("Random #14", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.dimensions[CSS_WIDTH] = 809;
node_0->style.margin[CSS_LEFT] = 6;
node_0->style.margin[CSS_TOP] = 8;
node_0->style.margin[CSS_RIGHT] = 6;
node_0->style.padding[CSS_RIGHT] = 16;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 8;
node_0->layout.position[CSS_LEFT] = 6;
node_0->layout.dimensions[CSS_WIDTH] = 809;
node_0->layout.dimensions[CSS_HEIGHT] = 18;
2014-04-22 14:59:59 -07:00
}
test("Random #15", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #16", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 0;
}
test("Random #17", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #18", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_FLEX_START;
2014-05-16 18:04:24 -07:00
node_0->style.margin[CSS_LEFT] = 6;
node_0->style.margin[CSS_TOP] = 6;
node_0->style.margin[CSS_RIGHT] = 6;
node_0->style.margin[CSS_BOTTOM] = 6;
node_0->style.margin[CSS_RIGHT] = 5;
node_0->style.margin[CSS_BOTTOM] = 7;
node_0->style.padding[CSS_RIGHT] = 10;
node_0->style.position[CSS_LEFT] = 8;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 6;
node_0->layout.position[CSS_LEFT] = 14;
node_0->layout.dimensions[CSS_WIDTH] = 10;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #19", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 161;
node_0->style.dimensions[CSS_HEIGHT] = 261;
node_0->style.margin[CSS_LEFT] = 3;
node_0->style.margin[CSS_RIGHT] = 4;
node_0->style.padding[CSS_TOP] = 2;
2014-05-16 18:04:24 -07:00
node_0->style.border[CSS_LEFT] = 3;
node_0->style.border[CSS_TOP] = 3;
node_0->style.border[CSS_RIGHT] = 3;
2014-05-16 18:04:24 -07:00
node_0->style.border[CSS_BOTTOM] = 3;
node_0->style.border[CSS_RIGHT] = 0;
node_0->style.border[CSS_BOTTOM] = 2;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_1->style.flex = 1;
node_1->style.dimensions[CSS_WIDTH] = 860;
node_1->style.dimensions[CSS_HEIGHT] = 424;
node_1->style.margin[CSS_LEFT] = 10;
node_1->style.margin[CSS_TOP] = 10;
node_1->style.margin[CSS_RIGHT] = 10;
node_1->style.margin[CSS_BOTTOM] = 10;
node_1->style.margin[CSS_TOP] = 5;
node_1->style.margin[CSS_RIGHT] = -7;
node_1->style.padding[CSS_LEFT] = 5;
node_1->style.padding[CSS_TOP] = 5;
node_1->style.padding[CSS_RIGHT] = 5;
node_1->style.padding[CSS_BOTTOM] = 5;
node_1->style.padding[CSS_LEFT] = 5;
node_1->style.padding[CSS_TOP] = 15;
node_1->style.padding[CSS_BOTTOM] = 9;
node_1->style.border[CSS_TOP] = 2;
node_1->style.border[CSS_BOTTOM] = 3;
node_1->style.position[CSS_LEFT] = 4;
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "small";
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 3;
node_0->layout.dimensions[CSS_WIDTH] = 161;
node_0->layout.dimensions[CSS_HEIGHT] = 261;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 10;
2014-09-11 09:23:30 -07:00
node_1->layout.position[CSS_LEFT] = 17;
node_1->layout.dimensions[CSS_WIDTH] = 155;
node_1->layout.dimensions[CSS_HEIGHT] = 424;
}
2014-04-22 14:59:59 -07:00
}
test("Random #20", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 596;
node_0->style.margin[CSS_TOP] = 12;
node_0->style.margin[CSS_RIGHT] = 6;
node_0->style.margin[CSS_BOTTOM] = 16;
node_0->style.padding[CSS_LEFT] = 15;
node_0->style.padding[CSS_TOP] = 15;
node_0->style.padding[CSS_RIGHT] = 15;
node_0->style.padding[CSS_BOTTOM] = 15;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.border[CSS_TOP] = 1;
node_0->style.border[CSS_RIGHT] = 1;
node_0->style.border[CSS_BOTTOM] = 1;
node_0->style.position[CSS_LEFT] = -7;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 12;
node_0->layout.position[CSS_LEFT] = -7;
node_0->layout.dimensions[CSS_WIDTH] = 596;
node_0->layout.dimensions[CSS_HEIGHT] = 50;
2014-04-22 14:59:59 -07:00
}
test("Random #21", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #22", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #23", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_HEIGHT] = 605;
node_0->style.margin[CSS_BOTTOM] = 10;
2014-05-16 18:04:24 -07:00
node_0->style.padding[CSS_LEFT] = 6;
node_0->style.padding[CSS_TOP] = 6;
2014-05-16 18:04:24 -07:00
node_0->style.padding[CSS_RIGHT] = 6;
node_0->style.padding[CSS_BOTTOM] = 6;
node_0->style.padding[CSS_TOP] = 4;
node_0->style.position[CSS_LEFT] = 0;
node_0->style.position[CSS_TOP] = 7;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 7;
2014-05-16 18:04:24 -07:00
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 46.671875;
node_0->layout.dimensions[CSS_HEIGHT] = 605;
2014-04-22 14:59:59 -07:00
}
test("Random #24", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_SPACE_AROUND;
node_0->style.dimensions[CSS_HEIGHT] = 846;
node_0->style.margin[CSS_LEFT] = 19;
node_0->style.margin[CSS_TOP] = 19;
node_0->style.margin[CSS_RIGHT] = 19;
node_0->style.margin[CSS_BOTTOM] = 19;
node_0->style.margin[CSS_LEFT] = -7;
node_0->style.padding[CSS_LEFT] = 18;
node_0->style.padding[CSS_TOP] = 6;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 19;
node_0->layout.position[CSS_LEFT] = -7;
node_0->layout.dimensions[CSS_WIDTH] = 18;
node_0->layout.dimensions[CSS_HEIGHT] = 846;
2014-04-22 14:59:59 -07:00
}
test("Random #25", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 726;
node_0->style.margin[CSS_LEFT] = 16;
node_0->style.margin[CSS_TOP] = 16;
node_0->style.margin[CSS_RIGHT] = 16;
2014-05-16 18:04:24 -07:00
node_0->style.margin[CSS_BOTTOM] = 16;
node_0->style.margin[CSS_TOP] = 15;
node_0->style.margin[CSS_BOTTOM] = 1;
node_0->style.border[CSS_LEFT] = 2;
node_0->style.border[CSS_TOP] = 2;
node_0->style.border[CSS_RIGHT] = 2;
node_0->style.border[CSS_BOTTOM] = 2;
node_0->style.border[CSS_TOP] = 1;
node_0->style.position[CSS_LEFT] = -1;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 15;
node_0->layout.position[CSS_LEFT] = 15;
node_0->layout.dimensions[CSS_WIDTH] = 726;
node_0->layout.dimensions[CSS_HEIGHT] = 3;
2014-04-22 14:59:59 -07:00
}
test("Random #26", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #27", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_0->style.align_items = CSS_ALIGN_STRETCH;
node_0->style.margin[CSS_LEFT] = 1;
node_0->style.margin[CSS_RIGHT] = -2;
node_0->style.padding[CSS_LEFT] = 4;
node_0->style.padding[CSS_TOP] = 4;
node_0->style.padding[CSS_RIGHT] = 4;
node_0->style.padding[CSS_BOTTOM] = 4;
node_0->style.padding[CSS_LEFT] = 19;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.border[CSS_TOP] = 1;
node_0->style.position[CSS_TOP] = -3;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = -3;
node_0->layout.position[CSS_LEFT] = 1;
node_0->layout.dimensions[CSS_WIDTH] = 24;
node_0->layout.dimensions[CSS_HEIGHT] = 9;
2014-04-22 14:59:59 -07:00
}
test("Random #28", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-04-28 12:34:04 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-28 12:34:04 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-28 12:34:04 -07:00
}
test("Random #29", root_node, root_layout);
2014-04-28 12:34:04 -07:00
}
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #30", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #31", root_node, root_layout);
2014-04-28 12:34:04 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-28 12:34:04 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-28 12:34:04 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-28 12:34:04 -07:00
}
test("Random #32", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.dimensions[CSS_HEIGHT] = 315;
node_0->style.margin[CSS_TOP] = -2;
node_0->style.margin[CSS_RIGHT] = -4;
node_0->style.margin[CSS_BOTTOM] = 0;
node_0->style.padding[CSS_LEFT] = 18;
node_0->style.border[CSS_RIGHT] = 3;
node_0->style.position[CSS_LEFT] = 4;
node_0->style.position[CSS_TOP] = -2;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = -4;
node_0->layout.position[CSS_LEFT] = 4;
node_0->layout.dimensions[CSS_WIDTH] = 21;
node_0->layout.dimensions[CSS_HEIGHT] = 315;
2014-04-22 14:59:59 -07:00
}
test("Random #33", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #34", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_BETWEEN;
node_0->style.dimensions[CSS_HEIGHT] = 819;
node_0->style.margin[CSS_LEFT] = 1;
node_0->style.margin[CSS_TOP] = 1;
node_0->style.margin[CSS_RIGHT] = 1;
node_0->style.margin[CSS_BOTTOM] = 1;
node_0->style.margin[CSS_TOP] = -3;
node_0->style.margin[CSS_BOTTOM] = 5;
node_0->style.padding[CSS_LEFT] = 18;
node_0->style.border[CSS_LEFT] = 2;
node_0->style.border[CSS_RIGHT] = 3;
node_0->style.position[CSS_LEFT] = 5;
2014-05-16 18:04:24 -07:00
init_css_node_children(node_0, 1);
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
2014-05-16 18:04:24 -07:00
node_1->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
2014-09-11 09:23:30 -07:00
node_1->style.align_self = CSS_ALIGN_STRETCH;
node_1->style.flex = 8;
node_1->style.dimensions[CSS_WIDTH] = 532;
node_1->style.margin[CSS_LEFT] = 8;
node_1->style.margin[CSS_TOP] = 8;
node_1->style.margin[CSS_RIGHT] = 8;
node_1->style.margin[CSS_BOTTOM] = 8;
node_1->style.margin[CSS_LEFT] = 16;
node_1->style.margin[CSS_BOTTOM] = 9;
node_1->style.padding[CSS_LEFT] = 7;
node_1->style.padding[CSS_TOP] = 7;
node_1->style.padding[CSS_RIGHT] = 7;
node_1->style.padding[CSS_BOTTOM] = 7;
node_1->style.padding[CSS_LEFT] = 8;
node_1->style.padding[CSS_TOP] = 5;
node_1->style.position[CSS_LEFT] = 4;
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "small";
2014-04-22 14:59:59 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = -3;
node_0->layout.position[CSS_LEFT] = 6;
node_0->layout.dimensions[CSS_WIDTH] = 579;
node_0->layout.dimensions[CSS_HEIGHT] = 819;
2014-05-16 18:04:24 -07:00
init_css_node_children(node_0, 1);
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 8;
node_1->layout.position[CSS_LEFT] = 40;
node_1->layout.dimensions[CSS_WIDTH] = 532;
node_1->layout.dimensions[CSS_HEIGHT] = 802;
2014-04-22 14:59:59 -07:00
}
}
test("Random #35", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.align_items = CSS_ALIGN_CENTER;
node_0->style.margin[CSS_LEFT] = 13;
node_0->style.margin[CSS_TOP] = 13;
node_0->style.margin[CSS_RIGHT] = 13;
node_0->style.margin[CSS_BOTTOM] = 13;
node_0->style.margin[CSS_BOTTOM] = 0;
node_0->style.border[CSS_TOP] = 1;
node_0->style.border[CSS_RIGHT] = 1;
node_0->style.position[CSS_TOP] = 8;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 21;
node_0->layout.position[CSS_LEFT] = 13;
node_0->layout.dimensions[CSS_WIDTH] = 1;
node_0->layout.dimensions[CSS_HEIGHT] = 1;
2014-04-28 12:34:04 -07:00
}
2014-04-22 14:59:59 -07:00
test("Random #36", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.align_items = CSS_ALIGN_FLEX_END;
node_0->style.dimensions[CSS_WIDTH] = 632;
node_0->style.dimensions[CSS_HEIGHT] = 907;
node_0->style.margin[CSS_LEFT] = -3;
node_0->style.margin[CSS_TOP] = 5;
node_0->style.margin[CSS_RIGHT] = -6;
node_0->style.margin[CSS_BOTTOM] = -5;
node_0->style.padding[CSS_LEFT] = 1;
node_0->style.padding[CSS_TOP] = 1;
node_0->style.padding[CSS_RIGHT] = 1;
node_0->style.padding[CSS_BOTTOM] = 1;
node_0->style.padding[CSS_BOTTOM] = 6;
node_0->style.border[CSS_BOTTOM] = 3;
node_0->style.position[CSS_LEFT] = -9;
node_0->style.position[CSS_TOP] = 4;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 9;
node_0->layout.position[CSS_LEFT] = -12;
node_0->layout.dimensions[CSS_WIDTH] = 632;
node_0->layout.dimensions[CSS_HEIGHT] = 907;
2014-04-22 14:59:59 -07:00
}
test("Random #37", root_node, root_layout);
2014-04-28 12:34:04 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-28 12:34:04 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-28 12:34:04 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-28 12:34:04 -07:00
}
test("Random #38", root_node, root_layout);
2014-04-28 12:34:04 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-28 12:34:04 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_HEIGHT] = 635;
node_0->style.margin[CSS_LEFT] = 3;
node_0->style.margin[CSS_TOP] = 6;
node_0->style.border[CSS_BOTTOM] = 1;
node_0->style.position[CSS_LEFT] = -5;
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-28 12:34:04 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-28 12:34:04 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 6;
node_0->layout.position[CSS_LEFT] = -2;
node_0->layout.dimensions[CSS_WIDTH] = 172.421875;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 635;
2014-04-28 12:34:04 -07:00
}
test("Random #39", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
}
test("Random #40", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
}
test("Random #41", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_0->style.dimensions[CSS_WIDTH] = 398;
node_0->style.dimensions[CSS_HEIGHT] = 198;
node_0->style.margin[CSS_LEFT] = 9;
node_0->style.margin[CSS_TOP] = -9;
node_0->style.margin[CSS_RIGHT] = 13;
node_0->style.margin[CSS_BOTTOM] = 6;
node_0->style.position[CSS_LEFT] = -2;
node_0->style.position[CSS_TOP] = -2;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = -11;
node_0->layout.position[CSS_LEFT] = 7;
node_0->layout.dimensions[CSS_WIDTH] = 398;
node_0->layout.dimensions[CSS_HEIGHT] = 198;
2014-04-22 14:59:59 -07:00
}
test("Random #42", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_AROUND;
node_0->style.dimensions[CSS_HEIGHT] = 514;
node_0->style.margin[CSS_LEFT] = 16;
node_0->style.margin[CSS_TOP] = 16;
node_0->style.margin[CSS_RIGHT] = 16;
node_0->style.margin[CSS_BOTTOM] = 16;
node_0->style.margin[CSS_TOP] = 5;
node_0->style.margin[CSS_RIGHT] = 3;
2014-05-16 18:04:24 -07:00
node_0->style.padding[CSS_RIGHT] = 6;
node_0->style.border[CSS_LEFT] = 0;
node_0->style.border[CSS_TOP] = 0;
node_0->style.border[CSS_RIGHT] = 0;
node_0->style.border[CSS_BOTTOM] = 0;
node_0->style.position[CSS_LEFT] = 5;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 5;
node_0->layout.position[CSS_LEFT] = 21;
node_0->layout.dimensions[CSS_WIDTH] = 6;
node_0->layout.dimensions[CSS_HEIGHT] = 514;
2014-04-22 14:59:59 -07:00
}
test("Random #43", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #44", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_CENTER;
node_0->style.dimensions[CSS_WIDTH] = 952;
node_0->style.margin[CSS_LEFT] = -2;
node_0->style.margin[CSS_TOP] = -2;
node_0->style.margin[CSS_RIGHT] = -2;
node_0->style.margin[CSS_BOTTOM] = -2;
node_0->style.margin[CSS_TOP] = 1;
node_0->style.margin[CSS_BOTTOM] = 2;
node_0->style.padding[CSS_LEFT] = 12;
node_0->style.border[CSS_TOP] = 3;
node_0->style.position[CSS_TOP] = -10;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = -9;
node_0->layout.position[CSS_LEFT] = -2;
node_0->layout.dimensions[CSS_WIDTH] = 952;
node_0->layout.dimensions[CSS_HEIGHT] = 3;
2014-04-22 14:59:59 -07:00
}
test("Random #45", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 937;
node_0->style.border[CSS_LEFT] = 0;
node_0->style.border[CSS_TOP] = 0;
node_0->style.border[CSS_RIGHT] = 0;
node_0->style.border[CSS_BOTTOM] = 0;
node_0->style.border[CSS_TOP] = 1;
node_0->style.position[CSS_LEFT] = -2;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
}
2014-04-22 14:59:59 -07:00
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = -2;
node_0->layout.dimensions[CSS_WIDTH] = 937;
node_0->layout.dimensions[CSS_HEIGHT] = 19;
}
test("Random #46", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 530;
node_0->style.dimensions[CSS_HEIGHT] = 726;
node_0->style.margin[CSS_LEFT] = -5;
node_0->style.margin[CSS_TOP] = -5;
node_0->style.margin[CSS_RIGHT] = -5;
node_0->style.margin[CSS_BOTTOM] = -5;
node_0->style.margin[CSS_LEFT] = 10;
node_0->style.padding[CSS_LEFT] = 2;
node_0->style.border[CSS_TOP] = 3;
node_0->style.position[CSS_LEFT] = 0;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_1->style.dimensions[CSS_WIDTH] = 195;
node_1->style.margin[CSS_TOP] = -2;
node_1->style.margin[CSS_RIGHT] = 15;
node_1->style.margin[CSS_BOTTOM] = 12;
node_1->style.padding[CSS_RIGHT] = 14;
node_1->style.border[CSS_TOP] = 2;
node_1->style.position[CSS_TOP] = -1;
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "small";
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.justify_content = CSS_JUSTIFY_SPACE_BETWEEN;
node_1->style.dimensions[CSS_WIDTH] = 638;
node_1->style.dimensions[CSS_HEIGHT] = 753;
node_1->style.margin[CSS_LEFT] = 19;
node_1->style.margin[CSS_TOP] = 3;
node_1->style.margin[CSS_RIGHT] = 10;
node_1->style.padding[CSS_LEFT] = 14;
node_1->style.padding[CSS_TOP] = 14;
node_1->style.padding[CSS_RIGHT] = 14;
node_1->style.padding[CSS_BOTTOM] = 14;
node_1->style.padding[CSS_TOP] = 18;
node_1->style.position[CSS_LEFT] = -7;
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "loooooooooong with space";
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = -5;
node_0->layout.position[CSS_LEFT] = 10;
node_0->layout.dimensions[CSS_WIDTH] = 530;
node_0->layout.dimensions[CSS_HEIGHT] = 726;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
2014-09-11 09:23:30 -07:00
node_1->layout.position[CSS_LEFT] = 2;
node_1->layout.dimensions[CSS_WIDTH] = 195;
node_1->layout.dimensions[CSS_HEIGHT] = 20;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->layout.position[CSS_TOP] = 6;
2014-09-11 09:23:30 -07:00
node_1->layout.position[CSS_LEFT] = 224;
node_1->layout.dimensions[CSS_WIDTH] = 638;
node_1->layout.dimensions[CSS_HEIGHT] = 753;
}
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #47", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_HEIGHT] = 712;
node_0->style.margin[CSS_LEFT] = 16;
node_0->style.margin[CSS_TOP] = 16;
node_0->style.margin[CSS_RIGHT] = 16;
node_0->style.margin[CSS_BOTTOM] = 16;
node_0->style.margin[CSS_RIGHT] = -2;
node_0->style.margin[CSS_BOTTOM] = 15;
node_0->style.padding[CSS_TOP] = 19;
node_0->style.position[CSS_TOP] = 1;
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 17;
node_0->layout.position[CSS_LEFT] = 16;
node_0->layout.dimensions[CSS_WIDTH] = 172.421875;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 712;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #48", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_0->style.align_items = CSS_ALIGN_STRETCH;
node_0->style.dimensions[CSS_HEIGHT] = 194;
node_0->style.margin[CSS_LEFT] = 1;
node_0->style.margin[CSS_TOP] = 1;
node_0->style.margin[CSS_RIGHT] = 1;
node_0->style.margin[CSS_BOTTOM] = 1;
node_0->style.margin[CSS_TOP] = -7;
node_0->style.margin[CSS_RIGHT] = -6;
node_0->style.padding[CSS_LEFT] = 18;
node_0->style.padding[CSS_TOP] = 18;
node_0->style.padding[CSS_RIGHT] = 18;
node_0->style.padding[CSS_BOTTOM] = 18;
node_0->style.border[CSS_BOTTOM] = 0;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = -7;
node_0->layout.position[CSS_LEFT] = 1;
node_0->layout.dimensions[CSS_WIDTH] = 36;
node_0->layout.dimensions[CSS_HEIGHT] = 194;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #49", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.dimensions[CSS_HEIGHT] = 335;
node_0->style.margin[CSS_LEFT] = -6;
node_0->style.margin[CSS_TOP] = -9;
node_0->style.margin[CSS_BOTTOM] = -2;
node_0->style.border[CSS_TOP] = 2;
node_0->style.position[CSS_LEFT] = -9;
node_0->style.position[CSS_TOP] = -1;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = -10;
node_0->layout.position[CSS_LEFT] = -15;
node_0->layout.dimensions[CSS_WIDTH] = 172.421875;
node_0->layout.dimensions[CSS_HEIGHT] = 335;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #50", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 648;
node_0->style.margin[CSS_LEFT] = -1;
node_0->style.margin[CSS_TOP] = 15;
node_0->style.margin[CSS_BOTTOM] = 8;
node_0->style.padding[CSS_LEFT] = 17;
node_0->style.padding[CSS_TOP] = 19;
node_0->style.padding[CSS_BOTTOM] = 2;
node_0->style.border[CSS_LEFT] = 2;
node_0->style.border[CSS_TOP] = 2;
node_0->style.border[CSS_RIGHT] = 2;
node_0->style.border[CSS_BOTTOM] = 2;
node_0->style.position[CSS_TOP] = 7;
init_css_node_children(node_0, 3);
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.justify_content = CSS_JUSTIFY_SPACE_BETWEEN;
node_1->style.align_items = CSS_ALIGN_FLEX_END;
2014-09-11 09:23:30 -07:00
node_1->style.align_self = CSS_ALIGN_FLEX_START;
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.dimensions[CSS_WIDTH] = 928;
node_1->style.margin[CSS_LEFT] = 5;
node_1->style.margin[CSS_RIGHT] = -3;
node_1->style.margin[CSS_BOTTOM] = -2;
node_1->style.padding[CSS_LEFT] = 19;
node_1->style.padding[CSS_TOP] = 12;
node_1->style.padding[CSS_RIGHT] = 2;
node_1->style.padding[CSS_BOTTOM] = 2;
node_1->style.position[CSS_LEFT] = 1;
node_1->style.position[CSS_TOP] = 0;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_2->style.align_items = CSS_ALIGN_FLEX_START;
node_2->style.position_type = CSS_POSITION_RELATIVE;
2014-09-11 09:23:30 -07:00
node_2->style.flex = 9;
node_2->style.dimensions[CSS_HEIGHT] = 898;
node_2->style.margin[CSS_LEFT] = 11;
node_2->style.margin[CSS_TOP] = 11;
node_2->style.margin[CSS_RIGHT] = 11;
node_2->style.margin[CSS_BOTTOM] = 11;
node_2->style.margin[CSS_LEFT] = -7;
node_2->style.margin[CSS_RIGHT] = 9;
node_2->style.margin[CSS_BOTTOM] = -10;
node_2->style.padding[CSS_BOTTOM] = 8;
node_2->style.border[CSS_TOP] = 0;
node_2->style.position[CSS_LEFT] = 4;
node_2->style.position[CSS_TOP] = 8;
init_css_node_children(node_2, 1);
{
css_node_t *node_3;
2014-09-11 09:23:30 -07:00
node_3 = node_2->get_child(node_2->context, 0);
node_3->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
2014-09-11 09:23:30 -07:00
node_3->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_3->style.dimensions[CSS_HEIGHT] = 274;
node_3->style.margin[CSS_LEFT] = 6;
node_3->style.margin[CSS_TOP] = 6;
node_3->style.margin[CSS_RIGHT] = 6;
node_3->style.margin[CSS_BOTTOM] = 6;
node_3->style.margin[CSS_TOP] = 10;
node_3->style.padding[CSS_LEFT] = 16;
node_3->style.padding[CSS_BOTTOM] = 13;
node_3->style.border[CSS_LEFT] = 2;
node_3->style.position[CSS_TOP] = -9;
init_css_node_children(node_3, 2);
{
css_node_t *node_4;
2014-09-11 09:23:30 -07:00
node_4 = node_3->get_child(node_3->context, 0);
node_4->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_4->style.justify_content = CSS_JUSTIFY_SPACE_BETWEEN;
node_4->style.align_items = CSS_ALIGN_STRETCH;
node_4->style.position_type = CSS_POSITION_ABSOLUTE;
node_4->style.margin[CSS_LEFT] = 3;
node_4->style.margin[CSS_TOP] = 3;
node_4->style.margin[CSS_RIGHT] = 3;
node_4->style.margin[CSS_BOTTOM] = 3;
node_4->style.margin[CSS_RIGHT] = -5;
node_4->style.padding[CSS_RIGHT] = 8;
node_4->style.border[CSS_BOTTOM] = 3;
node_4->style.position[CSS_LEFT] = -8;
2014-09-11 09:23:30 -07:00
node_4 = node_3->get_child(node_3->context, 1);
node_4->style.margin[CSS_LEFT] = 16;
node_4->style.margin[CSS_TOP] = 16;
node_4->style.margin[CSS_RIGHT] = 16;
node_4->style.margin[CSS_BOTTOM] = 16;
node_4->style.margin[CSS_TOP] = 1;
node_4->style.padding[CSS_LEFT] = 6;
node_4->style.padding[CSS_RIGHT] = 14;
node_4->style.padding[CSS_BOTTOM] = 19;
2014-06-11 21:00:57 -07:00
node_4->measure = measure;
node_4->context = "small";
}
}
}
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_1->style.align_self = CSS_ALIGN_FLEX_START;
node_1->style.dimensions[CSS_HEIGHT] = 49;
node_1->style.margin[CSS_TOP] = 8;
node_1->style.margin[CSS_BOTTOM] = 9;
node_1->style.padding[CSS_RIGHT] = 11;
node_1->style.border[CSS_RIGHT] = 3;
node_1->style.position[CSS_LEFT] = 4;
node_1->style.position[CSS_TOP] = 4;
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "small";
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 2);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_1->style.align_self = CSS_ALIGN_CENTER;
node_1->style.margin[CSS_RIGHT] = 18;
2014-05-16 18:04:24 -07:00
node_1->style.margin[CSS_BOTTOM] = -1;
node_1->style.padding[CSS_TOP] = 14;
node_1->style.padding[CSS_BOTTOM] = 11;
node_1->style.border[CSS_TOP] = 0;
node_1->style.border[CSS_BOTTOM] = 3;
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "small";
2014-04-22 14:59:59 -07:00
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 22;
node_0->layout.position[CSS_LEFT] = -1;
node_0->layout.dimensions[CSS_WIDTH] = 648;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 91;
init_css_node_children(node_0, 3);
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 2;
node_1->layout.position[CSS_LEFT] = 8;
node_1->layout.dimensions[CSS_WIDTH] = 928;
node_1->layout.dimensions[CSS_HEIGHT] = 913;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 31;
node_2->layout.position[CSS_LEFT] = 804.328125;
node_2->layout.dimensions[CSS_WIDTH] = 116.671875;
node_2->layout.dimensions[CSS_HEIGHT] = 898;
init_css_node_children(node_2, 1);
{
css_node_t *node_3;
2014-09-11 09:23:30 -07:00
node_3 = node_2->get_child(node_2->context, 0);
node_3->layout.position[CSS_TOP] = 1;
node_3->layout.position[CSS_LEFT] = 6;
node_3->layout.dimensions[CSS_WIDTH] = 104.671875;
node_3->layout.dimensions[CSS_HEIGHT] = 274;
init_css_node_children(node_3, 2);
{
css_node_t *node_4;
2014-09-11 09:23:30 -07:00
node_4 = node_3->get_child(node_3->context, 0);
node_4->layout.position[CSS_TOP] = 210;
node_4->layout.position[CSS_LEFT] = -3;
node_4->layout.dimensions[CSS_WIDTH] = 8;
node_4->layout.dimensions[CSS_HEIGHT] = 3;
2014-09-11 09:23:30 -07:00
node_4 = node_3->get_child(node_3->context, 1);
node_4->layout.position[CSS_TOP] = 208;
node_4->layout.position[CSS_LEFT] = 34;
node_4->layout.dimensions[CSS_WIDTH] = 54.671875;
node_4->layout.dimensions[CSS_HEIGHT] = 37;
}
}
}
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->layout.position[CSS_TOP] = 33;
node_1->layout.position[CSS_LEFT] = 23;
node_1->layout.dimensions[CSS_WIDTH] = 48.671875;
node_1->layout.dimensions[CSS_HEIGHT] = 49;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 2);
node_1->layout.position[CSS_TOP] = 31.5;
node_1->layout.position[CSS_LEFT] = 67.671875;
node_1->layout.dimensions[CSS_WIDTH] = 34.671875;
node_1->layout.dimensions[CSS_HEIGHT] = 46;
2014-04-22 14:59:59 -07:00
}
}
2014-04-28 12:34:04 -07:00
test("Random #51", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 803;
node_0->style.dimensions[CSS_HEIGHT] = 826;
node_0->style.margin[CSS_LEFT] = 19;
node_0->style.margin[CSS_RIGHT] = -3;
node_0->style.margin[CSS_BOTTOM] = -6;
node_0->style.padding[CSS_BOTTOM] = 5;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.border[CSS_TOP] = 2;
node_0->style.position[CSS_LEFT] = -6;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 13;
node_0->layout.dimensions[CSS_WIDTH] = 803;
node_0->layout.dimensions[CSS_HEIGHT] = 826;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #52", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_0->style.dimensions[CSS_HEIGHT] = 861;
node_0->style.margin[CSS_LEFT] = 0;
node_0->style.margin[CSS_TOP] = 0;
node_0->style.margin[CSS_RIGHT] = 0;
node_0->style.margin[CSS_BOTTOM] = 0;
node_0->style.margin[CSS_LEFT] = -4;
node_0->style.margin[CSS_RIGHT] = 5;
node_0->style.margin[CSS_BOTTOM] = 18;
node_0->style.position[CSS_LEFT] = -8;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = -12;
node_0->layout.dimensions[CSS_WIDTH] = 34.671875;
node_0->layout.dimensions[CSS_HEIGHT] = 861;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #53", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #54", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 134;
node_0->style.dimensions[CSS_HEIGHT] = 394;
node_0->style.margin[CSS_LEFT] = 16;
node_0->style.margin[CSS_TOP] = 16;
node_0->style.margin[CSS_RIGHT] = 16;
node_0->style.margin[CSS_BOTTOM] = 16;
node_0->style.margin[CSS_TOP] = 9;
node_0->style.margin[CSS_BOTTOM] = 9;
node_0->style.padding[CSS_LEFT] = 17;
node_0->style.padding[CSS_RIGHT] = 3;
node_0->style.border[CSS_LEFT] = 3;
node_0->style.border[CSS_TOP] = 3;
2014-05-16 18:04:24 -07:00
node_0->style.border[CSS_RIGHT] = 3;
node_0->style.border[CSS_BOTTOM] = 3;
node_0->style.border[CSS_BOTTOM] = 1;
node_0->style.position[CSS_TOP] = -2;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 7;
node_0->layout.position[CSS_LEFT] = 16;
node_0->layout.dimensions[CSS_WIDTH] = 134;
node_0->layout.dimensions[CSS_HEIGHT] = 394;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #55", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.dimensions[CSS_WIDTH] = 216;
node_0->style.dimensions[CSS_HEIGHT] = 721;
node_0->style.margin[CSS_LEFT] = -6;
node_0->style.margin[CSS_TOP] = -6;
node_0->style.margin[CSS_RIGHT] = -6;
node_0->style.margin[CSS_BOTTOM] = -6;
node_0->style.margin[CSS_LEFT] = 2;
node_0->style.margin[CSS_TOP] = -1;
node_0->style.margin[CSS_RIGHT] = -8;
2014-05-16 18:04:24 -07:00
node_0->style.margin[CSS_BOTTOM] = -10;
node_0->style.padding[CSS_LEFT] = 4;
node_0->style.padding[CSS_TOP] = 19;
node_0->style.padding[CSS_BOTTOM] = 2;
node_0->style.border[CSS_LEFT] = 0;
node_0->style.border[CSS_BOTTOM] = 0;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = -1;
node_0->layout.position[CSS_LEFT] = 2;
node_0->layout.dimensions[CSS_WIDTH] = 216;
node_0->layout.dimensions[CSS_HEIGHT] = 721;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #56", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #57", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.align_items = CSS_ALIGN_FLEX_START;
node_0->style.dimensions[CSS_WIDTH] = 173;
node_0->style.margin[CSS_LEFT] = 11;
node_0->style.margin[CSS_TOP] = 11;
node_0->style.margin[CSS_RIGHT] = 11;
node_0->style.margin[CSS_BOTTOM] = 11;
node_0->style.margin[CSS_LEFT] = 10;
node_0->style.margin[CSS_TOP] = 17;
node_0->style.margin[CSS_RIGHT] = 15;
node_0->style.padding[CSS_BOTTOM] = 5;
2014-05-16 18:04:24 -07:00
node_0->style.border[CSS_BOTTOM] = 0;
node_0->style.position[CSS_LEFT] = 8;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 17;
node_0->layout.position[CSS_LEFT] = 18;
node_0->layout.dimensions[CSS_WIDTH] = 173;
node_0->layout.dimensions[CSS_HEIGHT] = 5;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #58", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #59", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.align_items = CSS_ALIGN_CENTER;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1 = node_0->get_child(node_0->context, 1);
node_1->measure = measure;
node_1->context = "loooooooooong with space";
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 172.421875;
node_0->layout.dimensions[CSS_HEIGHT] = 18;
2014-09-11 09:23:30 -07:00
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 86.203125;
node_1->layout.dimensions[CSS_WIDTH] = 0;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 172.421875;
node_1->layout.dimensions[CSS_HEIGHT] = 18;
2014-09-11 09:23:30 -07:00
}
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #60", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
2014-05-16 18:04:24 -07:00
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #61", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 671;
node_0->style.dimensions[CSS_HEIGHT] = 603;
node_0->style.margin[CSS_LEFT] = 14;
node_0->style.margin[CSS_RIGHT] = 6;
node_0->style.margin[CSS_BOTTOM] = -10;
node_0->style.padding[CSS_LEFT] = 5;
node_0->style.padding[CSS_TOP] = 17;
node_0->style.border[CSS_TOP] = 0;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 14;
node_0->layout.dimensions[CSS_WIDTH] = 671;
node_0->layout.dimensions[CSS_HEIGHT] = 603;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #62", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
}
test("Random #63", root_node, root_layout);
}
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #64", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #65", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #66", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_BETWEEN;
node_0->style.dimensions[CSS_WIDTH] = 516;
node_0->style.dimensions[CSS_HEIGHT] = 712;
node_0->style.margin[CSS_LEFT] = 15;
node_0->style.margin[CSS_TOP] = 15;
node_0->style.margin[CSS_RIGHT] = 15;
node_0->style.margin[CSS_BOTTOM] = 15;
node_0->style.margin[CSS_LEFT] = -8;
node_0->style.margin[CSS_RIGHT] = 11;
node_0->style.padding[CSS_LEFT] = 17;
node_0->style.padding[CSS_TOP] = 17;
node_0->style.padding[CSS_RIGHT] = 17;
node_0->style.padding[CSS_BOTTOM] = 17;
node_0->style.padding[CSS_TOP] = 4;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.border[CSS_TOP] = 1;
node_0->style.border[CSS_RIGHT] = 1;
node_0->style.border[CSS_BOTTOM] = 1;
node_0->style.position[CSS_TOP] = 4;
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 19;
node_0->layout.position[CSS_LEFT] = -8;
node_0->layout.dimensions[CSS_WIDTH] = 516;
node_0->layout.dimensions[CSS_HEIGHT] = 712;
2014-04-22 14:59:59 -07:00
}
test("Random #67", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.dimensions[CSS_WIDTH] = 1000;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->style.align_self = CSS_ALIGN_CENTER;
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "small";
}
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
{
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 1000;
node_0->layout.dimensions[CSS_HEIGHT] = 18;
init_css_node_children(node_0, 2);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 1000;
node_1->layout.dimensions[CSS_HEIGHT] = 0;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 1);
node_1->layout.position[CSS_TOP] = 0;
node_1->layout.position[CSS_LEFT] = 482.65625;
node_1->layout.dimensions[CSS_WIDTH] = 34.671875;
node_1->layout.dimensions[CSS_HEIGHT] = 18;
}
}
test("Random #68", root_node, root_layout);
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.dimensions[CSS_WIDTH] = 486;
node_0->style.margin[CSS_LEFT] = 19;
node_0->style.margin[CSS_TOP] = 19;
node_0->style.margin[CSS_RIGHT] = 19;
node_0->style.margin[CSS_BOTTOM] = 19;
node_0->style.margin[CSS_LEFT] = 16;
node_0->style.margin[CSS_RIGHT] = 10;
node_0->style.border[CSS_TOP] = 3;
node_0->style.position[CSS_LEFT] = 8;
node_0->style.position[CSS_TOP] = -6;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
2014-09-11 09:23:30 -07:00
node_1->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_1->style.align_items = CSS_ALIGN_STRETCH;
node_1->style.flex = 1;
node_1->style.dimensions[CSS_WIDTH] = 482;
node_1->style.dimensions[CSS_HEIGHT] = 818;
node_1->style.margin[CSS_RIGHT] = 14;
node_1->style.margin[CSS_BOTTOM] = -9;
node_1->style.padding[CSS_BOTTOM] = 14;
node_1->style.border[CSS_LEFT] = 1;
node_1->style.border[CSS_TOP] = 2;
node_1->style.border[CSS_RIGHT] = 0;
node_1->style.position[CSS_TOP] = 0;
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 13;
node_0->layout.position[CSS_LEFT] = 24;
node_0->layout.dimensions[CSS_WIDTH] = 486;
node_0->layout.dimensions[CSS_HEIGHT] = 812;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 3;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 482;
node_1->layout.dimensions[CSS_HEIGHT] = 818;
}
2014-04-22 14:59:59 -07:00
}
test("Random #69", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #70", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.align_items = CSS_ALIGN_STRETCH;
node_0->style.margin[CSS_LEFT] = -7;
node_0->style.margin[CSS_TOP] = -7;
node_0->style.margin[CSS_RIGHT] = -7;
node_0->style.margin[CSS_BOTTOM] = -7;
node_0->style.margin[CSS_TOP] = -6;
node_0->style.margin[CSS_RIGHT] = 3;
node_0->style.margin[CSS_BOTTOM] = 1;
node_0->style.padding[CSS_LEFT] = 19;
node_0->style.padding[CSS_TOP] = 19;
node_0->style.padding[CSS_RIGHT] = 19;
node_0->style.padding[CSS_BOTTOM] = 19;
node_0->style.padding[CSS_LEFT] = 3;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.border[CSS_TOP] = 1;
node_0->style.border[CSS_RIGHT] = 1;
node_0->style.border[CSS_BOTTOM] = 1;
node_0->style.border[CSS_LEFT] = 0;
node_0->style.border[CSS_TOP] = 3;
node_0->style.border[CSS_RIGHT] = 1;
node_0->style.position[CSS_LEFT] = -3;
node_0->style.position[CSS_TOP] = 8;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_1->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_1->style.align_items = CSS_ALIGN_CENTER;
node_1->style.align_self = CSS_ALIGN_FLEX_END;
node_1->style.position_type = CSS_POSITION_RELATIVE;
node_1->style.dimensions[CSS_WIDTH] = 422;
node_1->style.dimensions[CSS_HEIGHT] = 971;
node_1->style.margin[CSS_BOTTOM] = 10;
node_1->style.padding[CSS_BOTTOM] = 3;
node_1->style.border[CSS_RIGHT] = 1;
node_1->style.position[CSS_LEFT] = -3;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_2->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_2->style.align_items = CSS_ALIGN_CENTER;
node_2->style.position_type = CSS_POSITION_ABSOLUTE;
node_2->style.margin[CSS_LEFT] = 6;
node_2->style.padding[CSS_LEFT] = 0;
node_2->style.padding[CSS_TOP] = 0;
node_2->style.padding[CSS_RIGHT] = 0;
node_2->style.padding[CSS_BOTTOM] = 0;
node_2->style.padding[CSS_RIGHT] = 2;
node_2->style.border[CSS_TOP] = 1;
init_css_node_children(node_2, 3);
{
css_node_t *node_3;
node_3 = node_2->get_child(node_2->context, 0);
node_3->style.margin[CSS_LEFT] = 6;
node_3->style.margin[CSS_TOP] = 6;
node_3->style.margin[CSS_RIGHT] = 6;
node_3->style.margin[CSS_BOTTOM] = 6;
node_3->style.margin[CSS_BOTTOM] = 2;
node_3->style.padding[CSS_TOP] = 8;
node_3->style.padding[CSS_RIGHT] = 6;
node_3->style.padding[CSS_BOTTOM] = 6;
node_3->style.position[CSS_LEFT] = -5;
node_3->measure = measure;
node_3->context = "loooooooooong with space";
node_3 = node_2->get_child(node_2->context, 1);
node_3->style.margin[CSS_LEFT] = 4;
node_3->style.margin[CSS_TOP] = 8;
node_3->style.margin[CSS_RIGHT] = 15;
node_3->style.padding[CSS_LEFT] = 18;
node_3->style.padding[CSS_TOP] = 18;
node_3->style.padding[CSS_RIGHT] = 18;
node_3->style.padding[CSS_BOTTOM] = 18;
init_css_node_children(node_3, 2);
{
css_node_t *node_4;
node_4 = node_3->get_child(node_3->context, 0);
node_4->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_4->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_4->style.align_self = CSS_ALIGN_CENTER;
node_4->style.dimensions[CSS_HEIGHT] = 96;
node_4->style.margin[CSS_RIGHT] = 7;
node_4->style.margin[CSS_BOTTOM] = -4;
node_4->style.padding[CSS_TOP] = 0;
node_4->style.padding[CSS_RIGHT] = 16;
node_4->style.position[CSS_TOP] = 8;
node_4->measure = measure;
node_4->context = "small";
node_4 = node_3->get_child(node_3->context, 1);
node_4->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_4->style.align_items = CSS_ALIGN_CENTER;
node_4->style.position_type = CSS_POSITION_ABSOLUTE;
node_4->style.dimensions[CSS_WIDTH] = 493;
node_4->style.margin[CSS_LEFT] = 12;
node_4->style.margin[CSS_TOP] = 12;
node_4->style.margin[CSS_RIGHT] = 12;
node_4->style.margin[CSS_BOTTOM] = 12;
node_4->style.margin[CSS_LEFT] = -5;
node_4->style.margin[CSS_TOP] = 13;
node_4->style.margin[CSS_RIGHT] = -10;
node_4->style.margin[CSS_BOTTOM] = 1;
node_4->style.border[CSS_LEFT] = 0;
node_4->style.border[CSS_TOP] = 0;
node_4->style.border[CSS_RIGHT] = 0;
node_4->style.border[CSS_BOTTOM] = 0;
node_4->style.position[CSS_LEFT] = 9;
init_css_node_children(node_4, 1);
{
css_node_t *node_5;
node_5 = node_4->get_child(node_4->context, 0);
node_5->style.align_self = CSS_ALIGN_FLEX_START;
node_5->style.dimensions[CSS_WIDTH] = 450;
node_5->style.dimensions[CSS_HEIGHT] = 863;
node_5->style.margin[CSS_LEFT] = 5;
node_5->style.margin[CSS_TOP] = 5;
node_5->style.margin[CSS_RIGHT] = 5;
node_5->style.margin[CSS_BOTTOM] = 5;
node_5->style.margin[CSS_RIGHT] = -2;
node_5->style.padding[CSS_RIGHT] = 10;
node_5->style.border[CSS_RIGHT] = 2;
node_5->measure = measure;
node_5->context = "small";
}
}
node_3 = node_2->get_child(node_2->context, 2);
node_3->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_3->style.align_self = CSS_ALIGN_FLEX_END;
node_3->style.margin[CSS_LEFT] = 13;
node_3->style.margin[CSS_BOTTOM] = -2;
node_3->style.padding[CSS_LEFT] = 16;
node_3->style.padding[CSS_RIGHT] = 9;
node_3->style.border[CSS_BOTTOM] = 0;
node_3->style.position[CSS_LEFT] = 4;
node_3->style.position[CSS_TOP] = 6;
node_3->measure = measure;
node_3->context = "loooooooooong with space";
}
}
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 2;
node_0->layout.position[CSS_LEFT] = -10;
node_0->layout.dimensions[CSS_WIDTH] = 445;
node_0->layout.dimensions[CSS_HEIGHT] = 1023;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 22;
node_1->layout.position[CSS_LEFT] = 0;
node_1->layout.dimensions[CSS_WIDTH] = 422;
node_1->layout.dimensions[CSS_HEIGHT] = 971;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 0;
node_2->layout.position[CSS_LEFT] = 6;
node_2->layout.dimensions[CSS_WIDTH] = 212.421875;
2014-09-11 09:23:30 -07:00
node_2->layout.dimensions[CSS_HEIGHT] = 193;
init_css_node_children(node_2, 3);
{
css_node_t *node_3;
node_3 = node_2->get_child(node_2->context, 0);
node_3->layout.position[CSS_TOP] = 7;
node_3->layout.position[CSS_LEFT] = 11;
node_3->layout.dimensions[CSS_WIDTH] = 178.421875;
2014-09-11 09:23:30 -07:00
node_3->layout.dimensions[CSS_HEIGHT] = 32;
node_3 = node_2->get_child(node_2->context, 1);
node_3->layout.position[CSS_TOP] = 49;
node_3->layout.position[CSS_LEFT] = 52.875;
node_3->layout.dimensions[CSS_WIDTH] = 93.671875;
2014-09-11 09:23:30 -07:00
node_3->layout.dimensions[CSS_HEIGHT] = 128;
init_css_node_children(node_3, 2);
{
css_node_t *node_4;
node_4 = node_3->get_child(node_3->context, 0);
node_4->layout.position[CSS_TOP] = 26;
node_4->layout.position[CSS_LEFT] = 18;
node_4->layout.dimensions[CSS_WIDTH] = 50.671875;
2014-09-11 09:23:30 -07:00
node_4->layout.dimensions[CSS_HEIGHT] = 96;
node_4 = node_3->get_child(node_3->context, 1);
node_4->layout.position[CSS_TOP] = 123;
node_4->layout.position[CSS_LEFT] = 4;
node_4->layout.dimensions[CSS_WIDTH] = 493;
node_4->layout.dimensions[CSS_HEIGHT] = 873;
init_css_node_children(node_4, 1);
{
css_node_t *node_5;
node_5 = node_4->get_child(node_4->context, 0);
node_5->layout.position[CSS_TOP] = 5;
node_5->layout.position[CSS_LEFT] = 5;
node_5->layout.dimensions[CSS_WIDTH] = 450;
node_5->layout.dimensions[CSS_HEIGHT] = 863;
}
}
node_3 = node_2->get_child(node_2->context, 2);
node_3->layout.position[CSS_TOP] = 183;
node_3->layout.position[CSS_LEFT] = 17;
node_3->layout.dimensions[CSS_WIDTH] = 197.421875;
2014-09-11 09:23:30 -07:00
node_3->layout.dimensions[CSS_HEIGHT] = 18;
}
}
}
2014-04-22 14:59:59 -07:00
}
test("Random #71", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.margin[CSS_LEFT] = 12;
node_0->style.margin[CSS_TOP] = 12;
node_0->style.margin[CSS_RIGHT] = 12;
node_0->style.margin[CSS_BOTTOM] = 12;
node_0->style.margin[CSS_LEFT] = -9;
node_0->style.margin[CSS_BOTTOM] = 10;
node_0->style.padding[CSS_LEFT] = 18;
node_0->style.padding[CSS_TOP] = 10;
node_0->style.padding[CSS_RIGHT] = 1;
node_0->style.padding[CSS_BOTTOM] = 2;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.position[CSS_TOP] = 7;
2014-05-16 18:04:24 -07:00
init_css_node_children(node_0, 1);
2014-04-28 12:34:04 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.align_items = CSS_ALIGN_FLEX_START;
node_1->style.align_self = CSS_ALIGN_CENTER;
node_1->style.position_type = CSS_POSITION_ABSOLUTE;
node_1->style.margin[CSS_LEFT] = -6;
node_1->style.margin[CSS_TOP] = -6;
node_1->style.margin[CSS_RIGHT] = -6;
node_1->style.margin[CSS_BOTTOM] = -6;
node_1->style.margin[CSS_RIGHT] = 10;
node_1->style.margin[CSS_BOTTOM] = 0;
node_1->style.padding[CSS_LEFT] = 15;
node_1->style.padding[CSS_TOP] = 15;
node_1->style.padding[CSS_RIGHT] = 15;
node_1->style.padding[CSS_BOTTOM] = 15;
node_1->style.border[CSS_LEFT] = 1;
node_1->style.border[CSS_TOP] = 1;
node_1->style.border[CSS_RIGHT] = 1;
node_1->style.border[CSS_BOTTOM] = 1;
node_1->style.border[CSS_LEFT] = 3;
node_1->style.border[CSS_TOP] = 1;
node_1->style.border[CSS_BOTTOM] = 0;
node_1->style.position[CSS_LEFT] = -7;
node_1->style.position[CSS_TOP] = -9;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_2->style.justify_content = CSS_JUSTIFY_CENTER;
node_2->style.align_items = CSS_ALIGN_FLEX_END;
node_2->style.margin[CSS_RIGHT] = 6;
node_2->style.margin[CSS_BOTTOM] = 16;
node_2->style.padding[CSS_TOP] = 6;
node_2->style.border[CSS_LEFT] = 2;
node_2->style.border[CSS_TOP] = 1;
}
2014-04-28 12:34:04 -07:00
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 19;
node_0->layout.position[CSS_LEFT] = -9;
node_0->layout.dimensions[CSS_WIDTH] = 20;
node_0->layout.dimensions[CSS_HEIGHT] = 12;
2014-05-16 18:04:24 -07:00
init_css_node_children(node_0, 1);
2014-04-28 12:34:04 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = -15;
node_1->layout.position[CSS_LEFT] = -12;
node_1->layout.dimensions[CSS_WIDTH] = 42;
node_1->layout.dimensions[CSS_HEIGHT] = 54;
init_css_node_children(node_1, 1);
{
css_node_t *node_2;
2014-09-11 09:23:30 -07:00
node_2 = node_1->get_child(node_1->context, 0);
node_2->layout.position[CSS_TOP] = 16;
node_2->layout.position[CSS_LEFT] = 18;
node_2->layout.dimensions[CSS_WIDTH] = 2;
node_2->layout.dimensions[CSS_HEIGHT] = 7;
}
2014-04-28 12:34:04 -07:00
}
2014-04-22 14:59:59 -07:00
}
test("Random #72", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_0->style.margin[CSS_LEFT] = 17;
node_0->style.margin[CSS_TOP] = 17;
node_0->style.margin[CSS_RIGHT] = 17;
node_0->style.margin[CSS_BOTTOM] = 17;
node_0->style.margin[CSS_LEFT] = -5;
node_0->style.padding[CSS_RIGHT] = 12;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.border[CSS_TOP] = 1;
node_0->style.border[CSS_RIGHT] = 1;
node_0->style.border[CSS_BOTTOM] = 1;
node_0->style.border[CSS_RIGHT] = 3;
node_0->style.position[CSS_TOP] = 3;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 20;
node_0->layout.position[CSS_LEFT] = -5;
node_0->layout.dimensions[CSS_WIDTH] = 188.421875;
node_0->layout.dimensions[CSS_HEIGHT] = 20;
2014-04-22 14:59:59 -07:00
}
test("Random #73", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #74", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.align_items = CSS_ALIGN_FLEX_END;
node_0->style.dimensions[CSS_WIDTH] = 332;
node_0->style.margin[CSS_LEFT] = 18;
node_0->style.margin[CSS_TOP] = 18;
node_0->style.margin[CSS_RIGHT] = 18;
node_0->style.margin[CSS_BOTTOM] = 18;
node_0->style.margin[CSS_RIGHT] = -5;
node_0->style.padding[CSS_LEFT] = 12;
node_0->style.padding[CSS_TOP] = 12;
node_0->style.padding[CSS_RIGHT] = 12;
node_0->style.padding[CSS_BOTTOM] = 12;
node_0->style.padding[CSS_BOTTOM] = 2;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.border[CSS_TOP] = 1;
node_0->style.border[CSS_RIGHT] = 1;
node_0->style.border[CSS_BOTTOM] = 1;
node_0->style.border[CSS_LEFT] = 1;
node_0->style.position[CSS_LEFT] = -9;
node_0->style.position[CSS_TOP] = -5;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_1->style.dimensions[CSS_WIDTH] = 818;
node_1->style.dimensions[CSS_HEIGHT] = 543;
node_1->style.margin[CSS_LEFT] = -2;
node_1->style.margin[CSS_TOP] = -2;
node_1->style.margin[CSS_RIGHT] = -2;
node_1->style.margin[CSS_BOTTOM] = -2;
node_1->style.margin[CSS_LEFT] = 8;
node_1->style.margin[CSS_TOP] = 14;
node_1->style.padding[CSS_TOP] = 10;
node_1->measure = measure;
node_1->context = "small";
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 13;
node_0->layout.position[CSS_LEFT] = 9;
node_0->layout.dimensions[CSS_WIDTH] = 332;
node_0->layout.dimensions[CSS_HEIGHT] = 571;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = 27;
node_1->layout.position[CSS_LEFT] = 21;
node_1->layout.dimensions[CSS_WIDTH] = 818;
node_1->layout.dimensions[CSS_HEIGHT] = 543;
}
2014-04-22 14:59:59 -07:00
}
test("Random #75", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_HEIGHT] = 885;
node_0->style.margin[CSS_LEFT] = 13;
node_0->style.margin[CSS_BOTTOM] = -2;
node_0->style.padding[CSS_LEFT] = 7;
node_0->style.position[CSS_LEFT] = -4;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 9;
node_0->layout.dimensions[CSS_WIDTH] = 7;
node_0->layout.dimensions[CSS_HEIGHT] = 885;
2014-04-22 14:59:59 -07:00
}
test("Random #76", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #77", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
test("Random #78", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_0->style.dimensions[CSS_HEIGHT] = 332;
node_0->style.margin[CSS_LEFT] = 7;
node_0->style.margin[CSS_TOP] = 7;
node_0->style.margin[CSS_RIGHT] = 7;
node_0->style.margin[CSS_BOTTOM] = 7;
node_0->style.margin[CSS_TOP] = 17;
node_0->style.margin[CSS_RIGHT] = -6;
node_0->style.padding[CSS_LEFT] = 4;
node_0->style.padding[CSS_TOP] = 4;
node_0->style.padding[CSS_RIGHT] = 4;
node_0->style.padding[CSS_BOTTOM] = 4;
node_0->style.padding[CSS_LEFT] = 16;
node_0->style.padding[CSS_TOP] = 6;
node_0->style.border[CSS_LEFT] = 0;
node_0->style.border[CSS_TOP] = 0;
2014-05-16 18:04:24 -07:00
node_0->style.position[CSS_LEFT] = 1;
node_0->style.position[CSS_TOP] = -2;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 15;
node_0->layout.position[CSS_LEFT] = 8;
node_0->layout.dimensions[CSS_WIDTH] = 20;
node_0->layout.dimensions[CSS_HEIGHT] = 332;
2014-04-22 14:59:59 -07:00
}
test("Random #79", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_BETWEEN;
node_0->style.dimensions[CSS_WIDTH] = 410;
node_0->style.dimensions[CSS_HEIGHT] = 614;
node_0->style.margin[CSS_LEFT] = -2;
node_0->style.margin[CSS_TOP] = -2;
node_0->style.margin[CSS_RIGHT] = -2;
node_0->style.margin[CSS_BOTTOM] = -2;
node_0->style.margin[CSS_TOP] = 16;
node_0->style.margin[CSS_RIGHT] = 3;
node_0->style.margin[CSS_BOTTOM] = -7;
node_0->style.padding[CSS_TOP] = 6;
node_0->style.border[CSS_LEFT] = 3;
node_0->style.border[CSS_TOP] = 3;
node_0->style.border[CSS_RIGHT] = 3;
node_0->style.border[CSS_BOTTOM] = 3;
node_0->style.border[CSS_BOTTOM] = 0;
node_0->style.position[CSS_TOP] = 1;
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 17;
node_0->layout.position[CSS_LEFT] = -2;
node_0->layout.dimensions[CSS_WIDTH] = 410;
node_0->layout.dimensions[CSS_HEIGHT] = 614;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #80", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #81", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #82", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.dimensions[CSS_WIDTH] = 978;
node_0->style.dimensions[CSS_HEIGHT] = 446;
node_0->style.margin[CSS_LEFT] = 10;
node_0->style.margin[CSS_TOP] = 10;
node_0->style.margin[CSS_RIGHT] = 10;
node_0->style.margin[CSS_BOTTOM] = 10;
node_0->style.margin[CSS_LEFT] = -4;
node_0->style.margin[CSS_TOP] = -4;
node_0->style.position[CSS_LEFT] = -4;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->style.align_self = CSS_ALIGN_FLEX_END;
node_1->style.dimensions[CSS_WIDTH] = 256;
node_1->style.dimensions[CSS_HEIGHT] = 883;
node_1->style.margin[CSS_LEFT] = -8;
node_1->style.border[CSS_LEFT] = 0;
node_1->style.border[CSS_TOP] = 3;
node_1->style.border[CSS_BOTTOM] = 0;
node_1->style.position[CSS_LEFT] = 8;
node_1->style.position[CSS_TOP] = -3;
2014-06-11 21:00:57 -07:00
node_1->measure = measure;
node_1->context = "small";
}
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = -4;
node_0->layout.position[CSS_LEFT] = -8;
node_0->layout.dimensions[CSS_WIDTH] = 978;
node_0->layout.dimensions[CSS_HEIGHT] = 446;
init_css_node_children(node_0, 1);
{
css_node_t *node_1;
2014-09-11 09:23:30 -07:00
node_1 = node_0->get_child(node_0->context, 0);
node_1->layout.position[CSS_TOP] = -3;
node_1->layout.position[CSS_LEFT] = 730;
node_1->layout.dimensions[CSS_WIDTH] = 256;
node_1->layout.dimensions[CSS_HEIGHT] = 883;
}
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #83", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.justify_content = CSS_JUSTIFY_CENTER;
node_0->style.margin[CSS_LEFT] = 18;
node_0->style.margin[CSS_TOP] = 18;
node_0->style.margin[CSS_RIGHT] = 18;
node_0->style.margin[CSS_BOTTOM] = 18;
node_0->style.margin[CSS_LEFT] = 18;
node_0->style.margin[CSS_TOP] = -8;
node_0->style.padding[CSS_BOTTOM] = 2;
node_0->style.position[CSS_TOP] = -5;
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = -13;
node_0->layout.position[CSS_LEFT] = 18;
node_0->layout.dimensions[CSS_WIDTH] = 172.421875;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 20;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #84", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
2014-05-16 18:04:24 -07:00
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #85", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_CENTER;
node_0->style.margin[CSS_RIGHT] = -4;
node_0->style.margin[CSS_BOTTOM] = 6;
node_0->style.padding[CSS_LEFT] = 11;
node_0->style.padding[CSS_BOTTOM] = 3;
node_0->style.border[CSS_TOP] = 0;
node_0->style.position[CSS_LEFT] = 7;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 7;
node_0->layout.dimensions[CSS_WIDTH] = 11;
node_0->layout.dimensions[CSS_HEIGHT] = 3;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #86", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_0->style.dimensions[CSS_WIDTH] = 335;
node_0->style.margin[CSS_LEFT] = 17;
node_0->style.margin[CSS_TOP] = 17;
node_0->style.margin[CSS_RIGHT] = 17;
node_0->style.margin[CSS_BOTTOM] = 17;
node_0->style.margin[CSS_LEFT] = 16;
node_0->style.margin[CSS_BOTTOM] = 4;
node_0->style.padding[CSS_RIGHT] = 9;
node_0->style.padding[CSS_BOTTOM] = 14;
node_0->style.position[CSS_TOP] = 7;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 24;
node_0->layout.position[CSS_LEFT] = 16;
node_0->layout.dimensions[CSS_WIDTH] = 335;
node_0->layout.dimensions[CSS_HEIGHT] = 32;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #87", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_SPACE_AROUND;
node_0->style.dimensions[CSS_WIDTH] = 903;
node_0->style.margin[CSS_LEFT] = 7;
node_0->style.margin[CSS_TOP] = 7;
node_0->style.margin[CSS_RIGHT] = 7;
node_0->style.margin[CSS_BOTTOM] = 7;
node_0->style.margin[CSS_BOTTOM] = 13;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 7;
node_0->layout.position[CSS_LEFT] = 7;
node_0->layout.dimensions[CSS_WIDTH] = 903;
node_0->layout.dimensions[CSS_HEIGHT] = 18;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #88", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
node_0->style.dimensions[CSS_WIDTH] = 380;
node_0->style.dimensions[CSS_HEIGHT] = 824;
node_0->style.margin[CSS_LEFT] = 13;
node_0->style.margin[CSS_TOP] = 13;
node_0->style.margin[CSS_RIGHT] = 13;
node_0->style.margin[CSS_BOTTOM] = 13;
node_0->style.margin[CSS_RIGHT] = 18;
2014-05-16 18:04:24 -07:00
node_0->style.padding[CSS_LEFT] = 4;
node_0->style.padding[CSS_TOP] = 4;
node_0->style.padding[CSS_RIGHT] = 4;
node_0->style.padding[CSS_BOTTOM] = 4;
node_0->style.padding[CSS_LEFT] = 6;
node_0->style.padding[CSS_RIGHT] = 17;
node_0->style.padding[CSS_BOTTOM] = 7;
node_0->style.border[CSS_RIGHT] = 0;
node_0->style.position[CSS_LEFT] = -6;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 13;
node_0->layout.position[CSS_LEFT] = 7;
node_0->layout.dimensions[CSS_WIDTH] = 380;
node_0->layout.dimensions[CSS_HEIGHT] = 824;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #89", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
{
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #90", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_COLUMN;
node_0->style.margin[CSS_BOTTOM] = 7;
node_0->style.padding[CSS_LEFT] = 3;
node_0->style.padding[CSS_TOP] = 3;
node_0->style.border[CSS_RIGHT] = 0;
node_0->style.position[CSS_LEFT] = -1;
node_0->style.position[CSS_TOP] = 4;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 4;
node_0->layout.position[CSS_LEFT] = -1;
node_0->layout.dimensions[CSS_WIDTH] = 37.671875;
node_0->layout.dimensions[CSS_HEIGHT] = 21;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #91", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.justify_content = CSS_JUSTIFY_SPACE_AROUND;
node_0->style.margin[CSS_LEFT] = -8;
node_0->style.margin[CSS_RIGHT] = -2;
node_0->style.margin[CSS_BOTTOM] = 4;
node_0->style.padding[CSS_RIGHT] = 0;
node_0->style.border[CSS_TOP] = 2;
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_LEFT] = -8;
node_0->layout.dimensions[CSS_WIDTH] = 34.671875;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_HEIGHT] = 20;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #92", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #93", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-09-11 09:23:30 -07:00
css_node_t *node_0 = root_node;
node_0->style.justify_content = CSS_JUSTIFY_FLEX_END;
node_0->style.dimensions[CSS_WIDTH] = 922;
node_0->style.margin[CSS_LEFT] = 6;
node_0->style.margin[CSS_TOP] = 6;
node_0->style.margin[CSS_RIGHT] = 6;
node_0->style.margin[CSS_BOTTOM] = 6;
node_0->style.margin[CSS_LEFT] = 18;
node_0->style.margin[CSS_TOP] = -10;
node_0->style.margin[CSS_BOTTOM] = 15;
node_0->style.padding[CSS_TOP] = 3;
node_0->style.border[CSS_LEFT] = 0;
node_0->style.border[CSS_TOP] = 0;
node_0->style.border[CSS_RIGHT] = 0;
node_0->style.border[CSS_BOTTOM] = 0;
node_0->style.border[CSS_LEFT] = 2;
node_0->style.border[CSS_TOP] = 1;
node_0->style.border[CSS_BOTTOM] = 0;
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = -10;
node_0->layout.position[CSS_LEFT] = 18;
node_0->layout.dimensions[CSS_WIDTH] = 922;
node_0->layout.dimensions[CSS_HEIGHT] = 22;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #94", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_CENTER;
node_0->style.dimensions[CSS_WIDTH] = 779;
node_0->style.margin[CSS_LEFT] = 3;
node_0->style.margin[CSS_BOTTOM] = 19;
node_0->style.padding[CSS_LEFT] = 17;
node_0->style.padding[CSS_TOP] = 17;
node_0->style.padding[CSS_RIGHT] = 17;
node_0->style.padding[CSS_BOTTOM] = 17;
node_0->style.padding[CSS_TOP] = 15;
node_0->style.position[CSS_LEFT] = 3;
node_0->style.position[CSS_TOP] = 9;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "loooooooooong with space";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 9;
node_0->layout.position[CSS_LEFT] = 6;
node_0->layout.dimensions[CSS_WIDTH] = 779;
node_0->layout.dimensions[CSS_HEIGHT] = 50;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #95", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.justify_content = CSS_JUSTIFY_FLEX_START;
node_0->style.dimensions[CSS_HEIGHT] = 863;
node_0->style.margin[CSS_TOP] = 6;
node_0->style.margin[CSS_RIGHT] = -7;
node_0->style.padding[CSS_LEFT] = 2;
2014-05-16 18:04:24 -07:00
node_0->style.padding[CSS_BOTTOM] = 19;
node_0->style.border[CSS_BOTTOM] = 1;
node_0->style.position[CSS_TOP] = -3;
2014-06-11 21:00:57 -07:00
node_0->measure = measure;
node_0->context = "small";
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 3;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 36.671875;
node_0->layout.dimensions[CSS_HEIGHT] = 863;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #96", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
2014-09-11 09:23:30 -07:00
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #97", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_node;
2014-09-11 09:23:30 -07:00
node_0->style.flex_direction = CSS_FLEX_DIRECTION_ROW;
node_0->style.dimensions[CSS_WIDTH] = 770;
node_0->style.dimensions[CSS_HEIGHT] = 873;
node_0->style.margin[CSS_BOTTOM] = 15;
node_0->style.padding[CSS_TOP] = 0;
node_0->style.padding[CSS_RIGHT] = 0;
node_0->style.border[CSS_TOP] = 0;
node_0->style.border[CSS_BOTTOM] = 0;
node_0->style.position[CSS_LEFT] = 9;
node_0->style.position[CSS_TOP] = 1;
2014-04-22 14:59:59 -07:00
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 1;
node_0->layout.position[CSS_LEFT] = 9;
node_0->layout.dimensions[CSS_WIDTH] = 770;
node_0->layout.dimensions[CSS_HEIGHT] = 873;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #98", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
{
2014-09-11 09:23:30 -07:00
css_node_t *root_node = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
}
2014-09-11 09:23:30 -07:00
css_node_t *root_layout = new_test_css_node();
2014-04-22 14:59:59 -07:00
{
2014-05-16 18:04:24 -07:00
css_node_t *node_0 = root_layout;
node_0->layout.position[CSS_TOP] = 0;
node_0->layout.position[CSS_LEFT] = 0;
2014-09-11 09:23:30 -07:00
node_0->layout.dimensions[CSS_WIDTH] = 0;
node_0->layout.dimensions[CSS_HEIGHT] = 0;
2014-04-22 14:59:59 -07:00
}
2014-04-28 12:34:04 -07:00
test("Random #99", root_node, root_layout);
2014-04-22 14:59:59 -07:00
}
tests_finished();
}