Results 1 to 2 of 2

Thread: How to make splitter fill the window?

  1. #1
    Join Date
    Apr 2011
    Posts
    58
    Thanks
    1

    Default How to make splitter fill the window?

    Hi.

    I created a mainwindow.
    I then create a splitter.
    and then I added 2 different QTextEdit to the splitter.
    Compile and show the window.

    All is fine except that the window showed 2 textedit that are filling just a small part of the screen.
    1. How do I make the splitter (with the 2 textedit in the splitter) to fill up the whole mainwindow?
    2. How do I make the splitter also to resize when I resize my mainwindow?

    Thank you.
    marc

  2. #2
    Join Date
    May 2010
    Location
    Romania
    Posts
    1,021
    Thanks
    62
    Thanked 260 Times in 246 Posts
    Qt products
    Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: How to make splitter fill the window?

    Use setCentralWidget(...) to put a widget into a QMainWindow.

Similar Threads

  1. How to get splitter objects to fill the screen when maximized
    By jshafferman in forum Qt Programming
    Replies: 1
    Last Post: 8th March 2011, 21:53
  2. Replies: 2
    Last Post: 23rd November 2010, 05:43
  3. Replies: 2
    Last Post: 18th November 2010, 22:50
  4. lineedit fill in new dialog window.
    By mkarakaplan in forum Newbie
    Replies: 1
    Last Post: 7th October 2007, 07:00
  5. Window OS make distclean && qmake && make one line
    By patrik08 in forum General Programming
    Replies: 4
    Last Post: 22nd March 2007, 10:43

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.