Results 1 to 2 of 2

Thread: How place a table right in the middle of a qtabwidget?

  1. #1
    Join Date
    Mar 2015
    Posts
    105
    Thanks
    50

    Default How place a table right in the middle of a qtabwidget?

    Hello!

    I would like to know how can i centralize a qtablewidget in a qtabwidget using qtcreator 3.5.0 design. I know i can use layouts, but when i use them the table's size changes and i don't want that because i cannot resize. I tried some methods from stackoverflow and other websites but did not work because when i choose the layout my table changes the size! Only if a break the layout i can do that.

    I want to set a size for this table and place it right in the middle of my qtabwidget.

    How can i do that using design?

  2. #2
    Join Date
    Mar 2015
    Posts
    105
    Thanks
    50

    Default Re: How place a table right in the middle of a qtabwidget?

    Guys, i discovered by myself.

    Lets say you have an widget with dimentions like:
    width: 30
    height: 50

    And you want place it right in the middle of your window. In Design, is just set minimum and maximum size with the same dimentions, 30 and 50 for both, like in my example. Then, you can use layouts. This way your widget doesn't get resized when you set an layout.

Similar Threads

  1. QTabWidget Place icon with no text and stretch icon over tab
    By alenn.masic in forum Qt Programming
    Replies: 2
    Last Post: 11th April 2013, 12:25
  2. QGridLayout: insert row in middle
    By ctgrund in forum Qt Programming
    Replies: 5
    Last Post: 31st May 2012, 16:29
  3. Replies: 0
    Last Post: 1st March 2012, 22:35
  4. Place QMessageBox on middle of screen
    By lllturtle in forum Qt Programming
    Replies: 6
    Last Post: 25th November 2011, 01:36
  5. Middle Button Mouse
    By jaime in forum Qt Programming
    Replies: 1
    Last Post: 25th August 2006, 03:01

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.