views:

17

answers:

1

Hi! So I'm developing an app in PyQT and I need to implement user authentification. Basically I have drawn 3 layouts (all same size window)...on login layout, one layout for user A and one layout for user B. The the thing I want to achieve is that when user A logins he gets his specialized layout and so does B. And I want it to if possible happen in the same window (so it looks smooth...). Thanks in advance...

A: 

If the optional screens will contain completely different controls, I think a QStackedWidget with a page for each layout option would suit your needs provided that each optional layout will take up roughly the same size area.

Arnold Spence
How would I achieve this if I have drawn all three layouts in QTDesigner? And yes all windows are exactly the same size.
Icoo
You can create a main window/widget in Designer and drop a QStackedWidget on it. Right-Clicking on the stacked widget will give you a menu option to add pages. You should be able to switch to each page, open your other designed windows and cut and past your controls on to each page.
Arnold Spence
Thanks seems this is exactly what I need!
Icoo