Results 1 to 6 of 6

Thread: Resizing Qwidget with app window

  1. #1
    Join Date
    Jul 2015
    Posts
    13
    Thanks
    8
    Qt products
    Qt5
    Platforms
    Windows

    Default Resizing Qwidget with app window

    Hi,
    I am using Qwidget to play video streams.
    I am looking of a way to synchronize the Qwidget window with the app window, meaning when I minimize the app window or maximize it, the Qwidget's resolution will grow small or big with the app(same as happens with youtube windows for example).
    I've searched and couldn't find a solution for this.
    Thanks.

  2. #2
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Resizing Qwidget with app window

    Is the widget part of the window or a separate window on its own?
    If the former, then you seem to be missing a layout somewhere between the widget and the window.

    Cheers,
    _

  3. #3
    Join Date
    Jul 2015
    Posts
    13
    Thanks
    8
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: Resizing Qwidget with app window

    Qt_objects.JPG

    These are the objects, where do I need to add a layout?

    thanks.

  4. #4
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Resizing Qwidget with app window

    See in the top left corner, that "App", the QDialog class: icon for no layout

    Cheers,
    _

  5. The following user says thank you to anda_skoa for this useful post:

    Shibby284 (12th September 2015)

  6. #5
    Join Date
    Jul 2015
    Posts
    13
    Thanks
    8
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: Resizing Qwidget with app window

    thanks for the reply.
    I changed it and now I can't change the app window'sQdialog) size.
    I want it to be to be able to change and just the Qwidget to adjust to it.
    Thanks.

  7. #6
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Resizing Qwidget with app window

    There must be something wrong.

    The only thing the layout should be doing is to adjust the size of the elements inside it when you make the window larger.
    It should not prevent the window from being resized to a greater size by the user or the program code.

    You should be able to freely resize between the minimum size required by the window's content and basically full screen.

    Cheers,
    _

Similar Threads

  1. Replies: 1
    Last Post: 12th December 2013, 17:08
  2. resizing child window with parent window
    By sujan.dasmahapatra in forum Qt Programming
    Replies: 3
    Last Post: 8th May 2012, 20:02
  3. Replies: 3
    Last Post: 2nd March 2010, 21:58
  4. Prevent a QLabel resizing the parent QWidget
    By danc81 in forum Qt Programming
    Replies: 6
    Last Post: 10th November 2009, 21:54
  5. Problems resizing QWidget & Phonon
    By gmclachl in forum Qt Programming
    Replies: 2
    Last Post: 18th April 2009, 17:32

Tags for this Thread

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.