QFontDatabase 4.8 vs 5.x
-
I am running a graphics renderer on Linux without X in a command line.
Under 4.8 the code used QCoreApplication to get Qpainter and QFontDatabase running.
Under 5.6 I changed it to QGuiAplication because QFontDatabase had changed requirements.The MS windows version is now running fine but the Linux versions insists on having a X window.
How can i compile QT 5.x in a way that QFontDatabase & QPainter are working without X system?
#include <QCoreApplication>
QFontDatabase * gfontDatabase;
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv,false);QFontDatabase fontDatabase;
gfontDatabase=&fontDatabase; -
@Jorg-Singendonk
which platform plugin are you using? -
@raven-worx said:
which platform plugin are you using?
to be honest: i dont'know. It complaints about No X connection during startup.
this is aviable (which comes with openSuse thumbleweed):
web79:/usr/lib64/qt5/plugins # dir platforms
total 724
-rwxr-xr-x 1 root root 10624 May 17 20:45 libqeglfs.so
-rwxr-xr-x 1 root root 342496 May 17 20:45 libqlinuxfb.so
-rwxr-xr-x 1 root root 39840 May 17 20:45 libqminimal.so
-rwxr-xr-x 1 root root 177216 May 17 20:45 libqminimalegl.so
-rwxr-xr-x 1 root root 148128 May 17 20:45 libqoffscreen.so
-rwxr-xr-x 1 root root 10624 May 17 20:45 libqxcb.so -
finally it works with:
" -platform linuxfb "
I never thought of platform issues, but that hint helped.
thx
-
@Jorg-Singendonk
that was i thinking of ;) -
Hi,
Since it was based on a QCoreApplication and depending on your needs the offscreen plugin might be more suited.
Hope it helps