how add action group in toolbar?

Here's the place for discussion related to coding in FreeCAD, C++ or Python. Design, interfaces and structures.
yhw-miracle
Posts: 13
Joined: Sat Jan 04, 2020 5:01 am

how add action group in toolbar?

Postby yhw-miracle » Thu Jan 16, 2020 9:09 am

hello, everyone, I need to use python to add a group actions in toolbar, as is described in the picture.

I need to help.
Attachments
yhw-miracle_2020-01-16_17-08-03.png
yhw-miracle_2020-01-16_17-08-03.png (9.58 KiB) Viewed 145 times
openBrain
Posts: 2835
Joined: Fri Nov 09, 2018 5:38 pm

Re: how add action group in toolbar?

Postby openBrain » Thu Jan 16, 2020 10:02 am

I don't know which level of help you need, but in a general way, you need to use QToolButton, QMenu & QAction classes of QtGui.
You get access to it with :

Code: Select all

from PySide import QtGui
User avatar
JoshuaCall
Posts: 44
Joined: Tue Dec 17, 2019 3:43 am

Re: how add action group in toolbar?

Postby JoshuaCall » Thu Jan 16, 2020 4:08 pm

yhw-miracle,

Have you already seen the creating interface tools manual page?