Results 1 to 2 of 2

Thread: QWorspace background, causes slow-down!

  1. #1
    Join Date
    Jul 2007
    Posts
    27
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    10

    Unhappy QWorspace background, causes slow-down!

    I'm using a QWorkspace in an MDI application, and I'm loading a picture into the background using:

    Qt Code:
    1. QPixmap backgroundImage("/picture.png");
    2. QBrush backgroundBrush(backgroundImage);
    3.  
    4. QWorkspace *mainWorkspace = new QWorkspace;
    5.  
    6. mainWorkspace->setBackground(backgroundBrush);
    To copy to clipboard, switch view to plain text mode 

    I've noticed that when I add child window to the Workspace (using addWindow), the application acts extremely slow. It seems to be due to the background image.

    Moving a child window within the QWorkspace causes the background image to redraw, and this causes the movment of the child window to be "jerky", and sometimes the child window doesn't want to move at all.

    So my question is this... is there any way to optimize my application so that it's not so slowed down? I think it's the background image that's causing it, but I've reduced the image to 160x120, and the application is still very slow.

    Any help would be GREATLY appreciated.

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

    Default Re: QWorspace background, causes slow-down!

    Could you provide a minimum compilable example reproducing the problem?

Similar Threads

  1. background colour
    By kw in forum Qt Programming
    Replies: 6
    Last Post: 11th April 2006, 01:44
  2. Replies: 1
    Last Post: 5th April 2006, 17:44

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.