Results 1 to 2 of 2

Thread: how to put the tabbar at the left in a tabwidget

  1. #1
    Join Date
    Oct 2006
    Posts
    15
    Qt products

    Default how to put the tabbar at the left in a tabwidget

    hi, all

    I want to implement a tabwidget, which puts the tabbar at the left or right. and the other behaviors are the same with QTabWidget.

    what i need to do is firstly to implement a tabbar which layout vertically and then to rearrange the tabbar and widgetstack in tabwidget.
    but i find out that the layout related member funtions of QTabbar and QTabWidget are
    private. so i cannot subclass them to rearrange.

    now maybe two ways can resolve it.
    1. copy the entire code of QTabWidget or QTabbar, and modify the Layout and sizeHint funtions.
    2. set my implement class friend of the QTabWidget and QTabbar, thus i can access the private members of them. This method need to compile Qt library over again.

    anyone has better solutions?Thanks.

  2. #2
    Join Date
    Jan 2006
    Location
    Alingsås, Sweden
    Posts
    437
    Thanks
    3
    Thanked 39 Times in 39 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: how to put the tabbar at the left in a tabwidget

    Qt has support for that, but it seems that Qt three does not... I think that you will have to create your own tab widget and combine it with a widget stack, just as you say.

Similar Threads

  1. left and right margins in QPrinter
    By igor_x in forum Newbie
    Replies: 0
    Last Post: 2nd November 2006, 10:42

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.