Results 1 to 2 of 2

Thread: A child widget turns up as a new window

  1. #1
    Join Date
    Jan 2008
    Posts
    155
    Thanks
    4
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default A child widget turns up as a new window

    I create a QWidget subclass and supply a group box in my main window as a parent to it in the creation. Still, it turns up as a free window next to my main window.
    Am I doing a common mistake that any of you have done before?
    Any suggestions what I should look for?

    BN
    MacOSX user dabbling with Linux and Windows.

  2. #2
    Join Date
    Sep 2007
    Location
    Rome, GA
    Posts
    199
    Thanks
    14
    Thanked 41 Times in 35 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: A child widget turns up as a new window

    From what you describe I would make a layout, add the widget subclass to the layout, then set the layout to the groupbox. I believe that's the preferred way of putting widgets inside a groupbox. Haven't really used them that much.

  3. The following user says thank you to JimDaniel for this useful post:

    bnilsson (20th July 2008)

Similar Threads

  1. Set a window as child at runtime
    By sabeesh in forum Qt Programming
    Replies: 1
    Last Post: 26th November 2007, 09:30
  2. how to find a child widget?
    By TheRonin in forum Qt Programming
    Replies: 1
    Last Post: 8th November 2006, 10:30
  3. minimize child widget
    By sreedhar in forum Qt Programming
    Replies: 5
    Last Post: 15th May 2006, 12:02
  4. Move child widget along with the parent widget
    By sreedhar in forum Qt Programming
    Replies: 2
    Last Post: 15th May 2006, 12:00
  5. Referencing Parent Widget from Child
    By taylor34 in forum Qt Programming
    Replies: 8
    Last Post: 11th April 2006, 15:13

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.