[Interest] QDatastream, QMap, QImage serialization

Jason H jhihn at gmx.com
Tue May 22 19:35:28 CEST 2018


> On Tue, May 22, 2018 at 3:15 PM, Jason H <jhihn at gmx.com> wrote:
> > (...)
> > Admittedly I don't understand the nuances of QPixmap. But I know working with a QImage should not require a windowing server.
> 
> Where did you see QImage needs a windowing server ?
> Which QPA plugin are you using for headless apps ?
> 
> QGuiApplication should work fine for command-line-only apps, just use
> a QPA plugin that doesn't require a window system, try the offscreen
> plugin.
> 
> A good example of a gui app running on headless server is PhantomJS,
> which runs the entire QtWebKit stack.

Your point is correct. I misspoke when I said "windowing server". But QGuiApplication brings a lot in that isn't needed. Like screens, input methods, windows, sessions, clipboards, font, palettes, etc. Maybe these things are lighter weight than I think they are (particularly for the "offscreen" plugin ) and this is all much ado about nothing? If so then I apologize, but I think I am write to be confused by QCoreApplication, QGuiApplication, QApplication.

"The QApplication class manages the GUI application's control flow and main settings."
vs 
"The QGuiApplication class manages the GUI application's control flow and main settings." 
continuing...
"QGuiApplication contains the main event loop, where all events from the window system and other sources are processed and dispatched."

I got the idea of "window server" because QGuiApplication refers to "window system". So my next thought was "I don't want or need all that jazz." Maybe I'm wrong, maybe the language is not the best. But I don't seem to be alone in my desire to work with QImages without bringing in a window system. Maybe "offscreen" is the Pareto solution. 











More information about the Interest mailing list