I'm trying to get a simple button showing but it does not work.
I'm sure that all events are handled and gui.draw() is called (loop).
Code Select
try {
tgui::Button::Ptr button = tgui::Button::create("Test Button");
button->setSize(50, 40);
button->setPosition(0, 0);
button->connect("pressed", [this]()
{
this->onButtonPressed();
});
gui.add(button);
}
catch (tgui::Exception exception)
{
std::cout << exception.what() << std::endl;
}
I'm sure that all events are handled and gui.draw() is called (loop).