Results 1 to 3 of 3

Thread: Qt 4.8.1: Printing from non-GUI thread is unavailable

  1. #1
    Join Date
    Apr 2012
    Posts
    6
    Qt products
    Qt4
    Platforms
    Windows

    Question Qt 4.8.1: Printing from non-GUI thread is unavailable

    Hello everybody.

    Our project is based on Qt version 4.7.3 and everything works nice.
    But several days ago we tried to port our solution to 4.8.1. One problem appears.
    Application includes sophisticated report printing subsystem which performs painting in another (non-GUI) thread.

    This warning appears in ouput and has a source in QPrinter insides:

    QPixmap: It is not safe to use pixmaps outside the GUI thread
    Printing of images doesn't work because of this.
    Does anyone know the solutions? Excepting to perform printing from GUI-thread...

    Thanks.

  2. #2
    Join Date
    Sep 2011
    Location
    Manchester
    Posts
    538
    Thanks
    3
    Thanked 106 Times in 103 Posts
    Qt products
    Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qt 4.8.1: Printing from non-GUI thread is unavailable

    Start your app with
    -graphicssystem raster
    .
    In 4.8.x pixmap thread test was changed to prevent using pixmaps in non-gui thread for all graphics systems other than 'raster'.

  3. #3
    Join Date
    Apr 2012
    Posts
    6
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Qt 4.8.1: Printing from non-GUI thread is unavailable

    Thank you, it works!

Similar Threads

  1. gdb error 'Unavailable synchronous data'
    By glafauci in forum Qt Programming
    Replies: 0
    Last Post: 6th August 2011, 11:37
  2. If GPS is unavailable, application crashes!!!
    By wizarda in forum Qt Programming
    Replies: 5
    Last Post: 16th May 2011, 10:58
  3. Replies: 13
    Last Post: 18th December 2009, 09:43
  4. SQLite driver unavailable
    By kandalf in forum Installation and Deployment
    Replies: 5
    Last Post: 11th February 2009, 16:36
  5. QSound Unavailable
    By superutsav in forum Newbie
    Replies: 2
    Last Post: 3rd February 2006, 16:38

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.