Results 1 to 3 of 3

Thread: How to get background pixmap?

  1. #1
    Join Date
    Oct 2006
    Posts
    11
    Thanks
    4
    Qt products
    Qt3
    Platforms
    Unix/X11

    Default How to get background pixmap?

    Good day. I hawe such problem: I put some picture on my widget

    pwgt->setBackgroundPixmap(*temp);

    They are several pwgt widgets(it is dock windows)

    1. How can I get BackgroundPixmap from widget?

    2. When I try to get pixmap from main window
    void MainWindow::Image () {
    Window* pdoc=(Window*)myws->activeWindow();
    if(pdoc){
    pdoc->openImage();
    }
    }

    void window::Image()
    {}
    Everything crushes

  2. #2
    Join Date
    Oct 2006
    Posts
    11
    Thanks
    4
    Qt products
    Qt3
    Platforms
    Unix/X11

    Default Re: How to get background pixmap?

    To the next post:
    I tryed to do so
    void window::Image(){
    const QPixmap* pm = backgroundPixmap();
    //convert to QImage
    //invert pixels
    //convert to pixmap pix
    pwgt->setBackgroundPixmap(*pix);
    }

  3. #3
    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: How to get background pixmap?

    Make a backtrace using a debugger to see where the problem occurs.

Similar Threads

  1. Replies: 3
    Last Post: 8th December 2006, 18:51
  2. QLabel background color
    By munna in forum Newbie
    Replies: 3
    Last Post: 1st May 2006, 15:36
  3. Paint XP radio button to pixmap
    By Ben.Hines in forum Qt Programming
    Replies: 2
    Last Post: 26th April 2006, 21:15
  4. background colour
    By kw in forum Qt Programming
    Replies: 6
    Last Post: 11th April 2006, 00:44
  5. Replies: 1
    Last Post: 5th April 2006, 16: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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.