Rename stack to flex

This commit is contained in:
Corentin 2021-07-22 17:03:34 +09:00
commit e7753f244c
11 changed files with 32 additions and 31 deletions

View file

@ -3,8 +3,8 @@
#include "uui/config.hpp"
#include "uui/opengl/application.hpp"
#include "uui/opengl/component.hpp"
#include "uui/opengl/flex.hpp"
#include "uui/opengl/label.hpp"
#include "uui/opengl/stack.hpp"
using namespace std;
@ -31,14 +31,14 @@ int main()
label->set_background_color(0.5f, 0.5f, 0.1f);
label = window->create_label(0.75f, 0.75f, "Hello World!", {1.0f, 1.0f, 1.0f, 0.1f});
auto stack = window->create_stack(200, 0.6f, uui::Direction::HORIZONTAL);
auto stack = window->create_flex(200, 0.6f, uui::Direction::HORIZONTAL);
comp = stack->create_component(100, 50);
comp->set_background_color(0.2f, 0.75f, 0.25f);
stack->create_label("test", {0.8f, 0.2f, 0.2f, 1.0f});
comp = stack->create_component(100, 20);
comp->set_background_color(0.2f, 0.25f, 0.75f);
stack = window->create_stack(50, 400, uui::Direction::VERTICAL);
stack = window->create_flex(50, 400, uui::Direction::VERTICAL);
comp = stack->create_component(50, 100);
comp->set_background_color(0.2f, 0.75f, 0.25f);
stack->create_label("test", {0.8f, 0.2f, 0.2f, 1.0f});