Qt4 file dialogs not rendering correctly

Report bugs, bug fixes and workarounds here.
Topic author
ajtribick
Posts: 1780
Joined: 11.08.2003
With us: 16 years 4 months
Location: Switzerland

Qt4 file dialogs not rendering correctly

Post #1by ajtribick » 31.01.2010, 14:49

Hello,

I am having problems with the qt4 version: the open and save file dialogs are not being rendered correctly. This appears to be Celestia-specific and not a problem with the installation of qt4, as the following quick test program renders the save file dialog correctly...

Code: Select all

#include <QtGui>

int main(int argc, char *argv[])
{
    QApplication app(argc, argv);
    QString filename = QFileDialog::getSaveFileName(0, "Get save file name", "/home", "Images (*.png *.jpg)");
    QLabel label(filename);
    label.show();
    return app.exec();
}

In Celestia, no controls are rendered in the Grab Image dialog, and only a small portion of the Open Script dialog is rendered (clicking on a control in this dialog box does cause the rest of the window to render - this fix doesn't work in the Grab Image dialog box because no controls are rendered to click), see attached screenshots.

Building on Xubuntu 9.10 (Karmic) using gcc 4.4.1

Avatar
t00fri
Developer
Posts: 8772
Joined: 29.03.2002
Age: 17
With us: 17 years 8 months
Location: Hamburg, Germany

Re: Qt4 file dialogs not rendering correctly

Post #2by t00fri » 31.01.2010, 15:13

Andrew,


just running on Windows XP: I guess you will have to restrict your problem with the open/save dialogs to Linux, since under Windows XP/SP3 and Qt= 4.5.2, everything looks fine for the latest SVN version.

Later, after returning to Linux, I'll check it with my openSuSE 10.3 installation.

Fridger
Image

Topic author
ajtribick
Posts: 1780
Joined: 11.08.2003
With us: 16 years 4 months
Location: Switzerland

Re: Qt4 file dialogs not rendering correctly

Post #3by ajtribick » 31.01.2010, 17:08

Should have put some more details in previous post: I'm compiling on AMD64, Qt version is 4.5.3.

Avatar
t00fri
Developer
Posts: 8772
Joined: 29.03.2002
Age: 17
With us: 17 years 8 months
Location: Hamburg, Germany

Re: Qt4 file dialogs not rendering correctly

Post #4by t00fri » 31.01.2010, 18:46

Andrew,

just checked my latest SVN version, built under Qt4-4.3.1 (openSuSE 10.3).

Everything looks perfectly fine also under my Linux installation.

One frequent problem with Qt-installations under Linux is a potential version/header mixup due to incorrect PATH settings.

Fridger
Image

Topic author
ajtribick
Posts: 1780
Joined: 11.08.2003
With us: 16 years 4 months
Location: Switzerland

Re: Qt4 file dialogs not rendering correctly

Post #5by ajtribick » 31.01.2010, 20:01

Ah found the problem.

Apparently the GTK+ theme for qt4 does not play nice with the static QFileDialog methods. Annoying.

Avatar
t00fri
Developer
Posts: 8772
Joined: 29.03.2002
Age: 17
With us: 17 years 8 months
Location: Hamburg, Germany

Re: Qt4 file dialogs not rendering correctly

Post #6by t00fri » 31.01.2010, 21:51

ajtribick wrote:Ah found the problem.

Apparently the GTK+ theme for qt4 does not play nice with the static QFileDialog methods. Annoying.

That's what I was thinking, too, after I saw that small part of the file selector dialog which was GTK-type. Remember that Steve C. had plenty of GTK trouble with file selectors some time ago in Celestia?

Fridger
Image

cartrite
Posts: 1786
Joined: 15.09.2005
With us: 14 years 2 months
Location: Pocono Mountains, Pennsylvania, USA

Re: Qt4 file dialogs not rendering correctly

Post #7by cartrite » 04.02.2010, 22:10

t00fri wrote:
ajtribick wrote:Ah found the problem.

Apparently the GTK+ theme for qt4 does not play nice with the static QFileDialog methods. Annoying.

That's what I was thinking, too, after I saw that small part of the file selector dialog which was GTK-type. Remember that Steve C. had plenty of GTK trouble with file selectors some time ago in Celestia?

Fridger
Did you mean Steve P.? I never did get GTK to work correctly. Doesn't surprise me that it is causing other problems too.

By the way, sorry for the long absence. I was able to hold on to building for a while by downloading svn files to a usb stick from a library computer but my AMD64 finally broke down completely. I can't even get it to run for 5 minutes without freezing up. So I don't even use it anymore. I'm starting a new job soon and maybe I'll get back into this soon.
cartrite
Toshiba Satellite P875=S7200 laptop, Intel i5 processor 2.5 ghz 6 gb ram, Graphics Intel(R) HD Graphics 4000 openSUSE Leap 15.0

Avatar
t00fri
Developer
Posts: 8772
Joined: 29.03.2002
Age: 17
With us: 17 years 8 months
Location: Hamburg, Germany

Re: Qt4 file dialogs not rendering correctly

Post #8by t00fri » 04.02.2010, 23:44

cartrite wrote:
t00fri wrote:
ajtribick wrote:Ah found the problem.

Apparently the GTK+ theme for qt4 does not play nice with the static QFileDialog methods. Annoying.

That's what I was thinking, too, after I saw that small part of the file selector dialog which was GTK-type. Remember that Steve C. had plenty of GTK trouble with file selectors some time ago in Celestia?

Fridger
Did you mean Steve P.? I never did get GTK to work correctly. Doesn't surprise me that it is causing other problems too.

By the way, sorry for the long absence. I was able to hold on to building for a while by downloading svn files to a usb stick from a library computer but my AMD64 finally broke down completely. I can't even get it to run for 5 minutes without freezing up. So I don't even use it anymore. I'm starting a new job soon and maybe I'll get back into this soon.
cartrite

Hey Steve,

great to hear from you again...and the news sound very good!

Well Steve C. was a mix of Steve and Cartrite ;-) . Of course I meant YOU.

Fridger
Image


Return to “Bugs”

Who is online