Results 1 to 2 of 2

Thread: changing Parent/Ancestor of Widget

  1. #1
    Join Date
    Jan 2014
    Posts
    1
    Platforms
    Unix/X11

    Exclamation changing Parent/Ancestor of Widget

    Hi,

    i am new to QT and i am trying to create an application which does the following:

    I will have some buttons and when a user presses those button different Widget should pop up(in this case I am using Group Box form Containers. The programming logic do that works for me. But the issue that I need to have the Widgets on top of each other and when you try to design it, it automatically makes my next widget parent of the previous one. I don't know how to break the relationship. I did read about the .setParent method, but that would mean i need to create the Widgets programmatically, which I don't want to, since drag and drop is easy.

    So my question is can I break the child and parent relationship or change the widget parent and still have them stacked up on top of each other?

    Hope you understand the question!

    BTW using QT5.1

    Thanks

  2. #2
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: changing Parent/Ancestor of Widget


Similar Threads

  1. How to resize parent widget when child widget is resized
    By ainne810329 in forum Qt Programming
    Replies: 4
    Last Post: 29th November 2011, 07:47
  2. Replies: 1
    Last Post: 11th March 2011, 19:34
  3. Replies: 7
    Last Post: 14th January 2010, 08:47
  4. Resizing child widget on changing size of parent?
    By anupamgee in forum Qt Programming
    Replies: 3
    Last Post: 13th November 2009, 08:39
  5. Inherit size from ancestor Widget/QFrame
    By SenSej in forum Newbie
    Replies: 4
    Last Post: 26th September 2008, 11:55

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.