开发者

How do I insert QTabBar in Qt Designer?

This might very well be very stupid question, but I can not find QTabBar in Qt Designer. Th开发者_StackOverflow中文版ere is QTabWidged in the "Containers" group, but it is not the same - I don't need different pages, I just need the tab bar.

(I am using 4.7.2 version of Qt Designer under KDE4 on debian.)


There is no item in the designer that is a QTabBar, the only way you could accomplish this is by creating a plain QWidget and promoting it to a tabbar, but you will then have to set up the whole thing in code.

As for the pages you do realize that you can also promote the content widgets of a QTabWidget in designer to any subclass of QWidget, builtin or something that you created.


In Qt Designer 4.8 you can add a Widget where you want the QTabBar to be, and then right-click and choose "Promote To ▸ QTabBar". (Note: "Promote To", not "Morph Into")

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜