Results 1 to 5 of 5

Thread: modal QWidget

  1. #1
    Join Date
    Mar 2010
    Location
    Brasília, Brasil
    Posts
    15
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60

    Question modal QWidget

    How do I create a modal QWidget, I'm just managing to create a modal QDialog, but not a modal QWidget.

    Thanks in advance.

  2. #2
    Join Date
    Oct 2010
    Location
    Berlin, Germany
    Posts
    358
    Qt products
    Qt4
    Platforms
    Windows
    Thanks
    18
    Thanked 68 Times in 66 Posts

    Default Re: modal QWidget

    QWidget::show()

  3. #3
    Join Date
    Mar 2010
    Location
    Brasília, Brasil
    Posts
    15
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60

    Default Re: modal QWidget

    hum....
    I tried this, but not work ! : /

    hum....
    I tried this, but not work, simply displays the window on the screen, but not modal : /

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,376
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Thanks
    4
    Thanked 5,019 Times in 4,795 Posts
    Wiki edits
    10

    Default Re: modal QWidget

    Derive your widget from QDialog instead of QWidget and call QDialog::setModal() or QDialog::exec(). By the way, a modal non-dialog window is some kind of misdesign.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  5. #5
    Join Date
    Mar 2010
    Location
    Brasília, Brasil
    Posts
    15
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60

    Default Re: modal QWidget

    Well work, wysote thank you very much!

Similar Threads

  1. Non-Modal about dialog?
    By N3wb in forum Qt Programming
    Replies: 1
    Last Post: 8th December 2010, 06:47
  2. Qt non modal form how to
    By ras in forum Qt Programming
    Replies: 0
    Last Post: 5th August 2010, 20:20
  3. QWidget "allways on top + modal to all windows"
    By boblatino in forum Qt Programming
    Replies: 2
    Last Post: 24th July 2010, 20:30
  4. QT Modal Dialog
    By jiapei100 in forum Qt Programming
    Replies: 1
    Last Post: 16th January 2010, 18:15
  5. Bug with modal windows on Mac? [Qt 3.3]
    By kalos80 in forum Qt Programming
    Replies: 0
    Last Post: 15th February 2008, 17:52

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
  •  
Qt is a trademark of The Qt Company.