Results 1 to 4 of 4

Thread: QDockWidget bugged??

  1. #1

    Default QDockWidget bugged??

    Hi there,

    I have two question about QDockWidget. I hope I haven't found a bug!


    1) I have a QDockWidget. I have set as widget a class derived from QWidget that contains 4 QFrames. Inside each frame there are different widgets.
    My goal is to save vertical space, by making the widgets really close among them.

    I have tried to use setSpacing(1) to the main QVBoxLayout (the one that separates the QFrames) and it works.

    The problem is inside the QFrame.. if I try to do the same inside the QFrame it doesn't work. I have read other posts and it seems that dealing with QDockWidget is not simple.. is this a known bug?

    2) I have set a background color for the QDockWidget doing:

    Qt Code:
    1. QPalette playbackPalette(playbackManagementDock_->palette());
    2. playbackPalette.setColor(playbackManagementDock_->backgroundRole(), QColor(207,205,202));
    3. playbackManagementDock_->setAutoFillBackground(true);
    4. playbackManagementDock_->setPalette(playbackPalette);
    To copy to clipboard, switch view to plain text mode 

    The background is correctly changed but there is a problem related to the various QLineEdits that it contains.
    When one of these widgets changes text (using the setText() method), for some reason, a rectangular object (by the way, of a different color) is being drawn in correspondence of the widget. The QLineEdit has rounded borders.. it's like if a bounding rectangle is being drawn without reason..

    Do you know a method to prevent this, possibly without setting properties on the various QLineEdit?


    Cheers

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

    Default Re: QDockWidget bugged??

    Can you post a minimal compilable example reproducing the problem?
    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.


  3. #3

    Default Re: QDockWidget bugged??

    Quote Originally Posted by wysota View Post
    Can you post a minimal compilable example reproducing the problem?
    Hi,

    it should be a lot of code but I think I'll try later..

    Any quick idea or comment about them?

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

    Default Re: QDockWidget bugged??

    Quote Originally Posted by valerianst View Post
    it should be a lot of code but I think I'll try later..
    If you can't reproduce it using 50 lines of code then that's not a bug in Qt but rather in your code.
    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.


Similar Threads

  1. QDockWidget inside QDockWidget
    By mqt in forum Qt Programming
    Replies: 3
    Last Post: 1st July 2013, 12:57
  2. Replies: 1
    Last Post: 7th December 2010, 21:46
  3. Help with QDockWidget
    By mindbender in forum Qt Programming
    Replies: 6
    Last Post: 10th March 2010, 16:13
  4. QDockwidget
    By peace_comp in forum Qt Programming
    Replies: 3
    Last Post: 30th June 2008, 05:19
  5. QDockWidget's
    By tanminh in forum Qt Programming
    Replies: 1
    Last Post: 26th February 2008, 23:33

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.