开发者

QDockWidgets, set nested state from UIDesigner

I created a QtGui with the GuiCreator and added some DockWidgets. I can only allow the nested state from the property editor but how can I set it active for the DockWidgets?

At runtime the user can move the DockWidgets and if one DockWidget is moved over another it goes into the nested state resulting in a TabView.

Now I want to Launch the Application with the DockWidgets in nested state and closed. When the user toggles a DockWidget visible it shall be added as a Tab (nested) and on toggling off it the tab shall be removed.

I know I could use a TabWidget for this, but I want to have the option to undock the DockWidget and have it open as a single Window, so I need the DockWidgets.

Furhter the GUICreator handles all the Widgets as visible and they are shown in the creator resulting in a resize of my MainWindow and this results in strange behavior when I manually set fixed size and values.

Is it better to create those DockWidgets from within the Source Code? It seems that the GuiCreator lacks 开发者_Go百科some of the features I need.

I don't like the fact that I cannot completely build a independent Gui with the creator. I always have to do resizing and adding UI-related stuff to my source code. Am I doing something wrong?


I don't think you are doing anything wrong. Those QDockWidgets are a pain to work with. (But they are really cool for the user.)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜