Re: [Interest] QPrintPreviewWidget

2017-04-04 Thread Dan Allen
No problem. Thanks Roland. On 04/04/17 18:32, Roland Hughes wrote: Not ignoring your question Bill, but this response answered it better. There is always __something__ which gets in the way. Ultimately you end up needing an object which can only exist in the primary thread due to the tight c

Re: [Interest] QPrintPreviewWidget

2017-04-04 Thread Roland Hughes
Not ignoring your question Bill, but this response answered it better. There is always __something__ which gets in the way. Ultimately you end up needing an object which can only exist in the primary thread due to the tight coupling of that thread to the underlying windowing system and that ob

Re: [Interest] QPrintPreviewWidget

2017-04-04 Thread Dan Allen
Thanks for your help Bill. On 04/04/17 17:56, william.croc...@analog.com wrote: On 04/04/2017 11:52 AM, Dan Allen wrote: Hi Bill, What you've listed below is pretty much how my printing mechanism works. This works perfectly and I'm happy with it. I'm still a little confused as to why the

Re: [Interest] QPrintPreviewWidget

2017-04-04 Thread william.croc...@analog.com
On 04/04/2017 11:52 AM, Dan Allen wrote: Hi Bill, What you've listed below is pretty much how my printing mechanism works. This works perfectly and I'm happy with it. I'm still a little confused as to why the preview can't operate in the same way. If another thread paints into a QImage and th

Re: [Interest] QPrintPreviewWidget

2017-04-04 Thread Dan Allen
Hi Roland, Not 100% sure what you mean in the first part. Are you also saying I shouldn't use a another thread? Thanks, Dan Allen. On 04/04/17 12:24, Roland Hughes wrote: You know, "painting into an off screen image is not GUI related" __should__ be true. Haven't tried it since 4.8.x, b

Re: [Interest] QPrintPreviewWidget

2017-04-04 Thread Dan Allen
Hi Bill, What you've listed below is pretty much how my printing mechanism works. This works perfectly and I'm happy with it. I'm still a little confused as to why the preview can't operate in the same way. If another thread paints into a QImage and then informs the dialog using a signal s

Re: [Interest] QPrintPreviewWidget

2017-04-04 Thread Roland Hughes
You know, "painting into an off screen image is not GUI related" __should__ be true. Haven't tried it since 4.8.x, but it certainly wasn't true back then. Desperately wanted to thread off the generating of many pixmaps which would be later BLITted onto the touch screen as needed by application.

Re: [Interest] QPrintPreviewWidget

2017-04-03 Thread william.croc...@analog.com
On 04/01/2017 09:48 AM, Dan Allen wrote: Hi Bill, I agree, however when the print is quite complex it makes the GUI very unresponsive. Painting into an off screen image is not GUI related. The print preview could show something like "Generating Preview" while a background thread generates it an

Re: [Interest] QPrintPreviewWidget

2017-04-01 Thread Dan Allen
Hi Bill, I agree, however when the print is quite complex it makes the GUI very unresponsive. Painting into an off screen image is not GUI related. The print preview could show something like "Generating Preview" while a background thread generates it and then show it when it's ready for exa

Re: [Interest] QPrintPreviewWidget

2017-04-01 Thread Konstantin Tokarev
01.04.2017, 15:44, "william.croc...@analog.com" : > On 04/01/2017 03:41 AM, Dan Allen wrote: >>  Hi, >> >>  Could anyone tell me if it's possible to paint into a QPrintPreviewWidget in >>  another thread, and if so, how? >> >>  I have created a class to perform printing and this runs in another t

Re: [Interest] QPrintPreviewWidget

2017-04-01 Thread william.croc...@analog.com
On 04/01/2017 03:41 AM, Dan Allen wrote: Hi, Could anyone tell me if it's possible to paint into a QPrintPreviewWidget in another thread, and if so, how? I have created a class to perform printing and this runs in another thread. When used for printing it works fine. However when used for the

[Interest] QPrintPreviewWidget

2017-04-01 Thread Dan Allen
Hi, Could anyone tell me if it's possible to paint into a QPrintPreviewWidget in another thread, and if so, how? I have created a class to perform printing and this runs in another thread. When used for printing it works fine. However when used for the print preview, nothing is shown unles