Results 1 to 2 of 2

Thread: Show maximize button in the title bar of a QDialog under GNOME

  1. #1
    Join Date
    Oct 2009
    Location
    Craiova, Romania
    Posts
    46
    Thanks
    3
    Qt products
    Qt5
    Platforms
    Unix/X11 Windows

    Default Show maximize button in the title bar of a QDialog under GNOME

    Hello!

    I need to show the maximize (and minimize) buttons in the title bar of a QDialog. I made this:

    Qt Code:
    1. dialog->setWindowFlags(dialog->windowFlags() | Qt::WindowMinMaxButtonsHint);
    To copy to clipboard, switch view to plain text mode 

    which I call for the QDialog* dialog.

    Under KDE and Windows, the min max buttons are shown and working. Under GNOME, the buttons are not shown (I only see the close button).

    How can I solve this? Is it safe to do:

    Qt Code:
    1. dialog->setWindowFlags(Qt::WindowMinMaxButtonsHint | Qt::WindowCloseButtonHint);
    To copy to clipboard, switch view to plain text mode 

    (this works, practically, under GNOME)

    so that the flags for this dialog will not contain Qt:ialog anymore, but will contain Qt::Window?

    I tried also setting Qt::CustomizeWindowHint under GNOME, but it does not work.

    I also found this link to a similar problem: http://www.archivum.info/qt-interest...-Metacity.html

    Thank you!

  2. #2
    Join Date
    Oct 2009
    Location
    Craiova, Romania
    Posts
    46
    Thanks
    3
    Qt products
    Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Show maximize button in the title bar of a QDialog under GNOME

    I have another question: what is the reason/explanation of Qt::CustomizeWindowHint? Practically, it seems that it is not necessary to set this, even if I am customizing, by adding minmax buttons hint (minmax buttons are added even without setting Qt::CustomizeWindowHint).

Similar Threads

  1. QDialog with Close, Maximize and Context Help Buttons
    By mclark in forum Qt Programming
    Replies: 7
    Last Post: 1st May 2020, 17:53
  2. how to disable the maximize button?
    By zabeehkhan in forum Qt Programming
    Replies: 4
    Last Post: 14th April 2010, 08:26
  3. 'resize/maximize' button not visible
    By sindhumol_s in forum Qt Programming
    Replies: 2
    Last Post: 31st July 2009, 03:15
  4. Replies: 5
    Last Post: 21st April 2008, 08:54
  5. custom maximize button---
    By Naveen in forum Qt Programming
    Replies: 1
    Last Post: 24th February 2006, 14:11

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.