I am new to QT Creator. I did create a menu: Login || Open. When login is clicked I would like to see a line edit and a press button. When Open is clicked I would like to see a picture in the window. Can I change the interface of the same window depending on what I click in the menu bar? How can I do that?
Share
I did something similar to this – an app with several major areas, toggled by an icon bar at the top.
I used a
QStackWidgetto stack the different application areas on top of each other, a set ofQActions that I created using the designer, and aQActionGroupto implement the toggling.When the actions are marked as “checkable” and grouped in a
QActionGroup, theQToolBaronly lets one be active at the time.Here’s a simplified extract of my code: