Can someone please tell me how can I connect my toolbar ACTION with some some void private slots ??? It's emergency THX
Can someone please tell me how can I connect my toolbar ACTION with some some void private slots ??? It's emergency THX
And what is the problem? Be a little more specific and show some code if you have to.
You don't know how to make a connection?
Read the signal and slots documentation
Is private slots the problem?
There is no problem here, private slots are available for connection, they are only private when executed as normal member functions.
//this is somehow an incomplete answer, since the slot execution invoked by connect is done inside the object itself - but this is "Qt internals" already and the first answer is enough for most users
Or maybe he means QAction, but the answer is the same, check the docs or post a smart question
Or maybe he needs a simple example:
Try this:
Qt Code:
connect (ui->actionName, SIGNAL(triggered()), SLOT(slotName()));To copy to clipboard, switch view to plain text mode
It's emergency THX
==========================signature=============== ==================
S.O.L.I.D principles (use them!):
https://en.wikipedia.org/wiki/SOLID_...iented_design)
Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.
Bookmarks