Main Menu
Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Topics - Austriker

#1
Help requests / TGUI on raspberry pi
24 August 2015, 15:39:23
Hi,

Does TGUI supports raspberry ?
I managed to build it but when i launch my app it stops with this error :


Failed to create window
X Error of failed request:  BadWindow (invalid Window parameter)
  Major opcode of failed request:  3 (X_GetWindowAttributes)
  Resource id in failed request:  0x140000d
  Serial number of failed request:  65
  Current serial number in output stream:  66


Sincerely
#2
Help requests / Change setText on clic
21 August 2015, 15:33:56
Hi,

I am having trouble finding a solution to my problem. I would like to change the state of my button when it's triggered. But I can't find the way to do it.


tgui::Callback callback;
    while (_gui.pollCallback(callback))
    {
        if (callback.id == 1)
        {
            _gui.get("startbutton")->setText("Stop");

        }
    }


Here is the widget :

// Create the login button
    tgui::Button::Ptr startbutton(gui, "startbutton");
    startbutton->load("./widgets/Black.conf");
    startbutton->setSize(260, 60);
    startbutton->setPosition(270, 300);
    startbutton->setText("Start");
    startbutton->bindCallback(tgui::Button::LeftMouseClicked);
    startbutton->setCallbackId(1);


Thanks for your help,