Re: Gnome makes application crash
the debugger stops at the line
QColor changed = QColorDialog::getColor(Qt::white);
I can not step in to the code anymore
In the status I see no code at ......
when I press continue program the dialog pops up
when I press OK the program exits
regix
Re: Gnome makes application crash
Quote:
Originally Posted by regix
I can not step in to the code anymore
Did you try to set a breakpoint after that line?
Re: Gnome makes application crash
Yes I put a breakpoint at
QPixmap colpixmap(30,30);
the application continued through the changeTitleColor function
then I arrived at shared.h
deref...
and it went to
bool DlgEditCssBase::qt_invoke( int _id, QUObject* _o )
where it returned true
then I could not step further inside
I jumped out of the function
and arrived at
return qApp.exec();
regix
1 Attachment(s)
Re: Gnome makes application crash
Quote:
Originally Posted by regix
the application continued through the changeTitleColor function
This is a bit weird. I've checked Qt 3.3.5 sources and it seems that QColorDialog doesn't use anything specific to GNOME.
What signal triggers EditCSSDlg::changeTitleColor()? Is it connected to any other slot?
Also check the attachment. I have modified the test program, so that the color dialog is invoked from a modal dialog.
Re: Gnome makes application crash
dlgeditcssbase.cpp :
connect( pushButtonColor, SIGNAL( clicked() ), this, SLOT( changeTitleColor() ) );
void DlgEditCssBase::changeTitleColor()
{
qWarning( "DlgEditCssBase::changeTitleColor(): Not implemented yet" );
}
dlgeditcssbase.h:
virtual void changeTitleColor();
dlgeditcss.h
virtual void changeTitleColor();
there are no other slots connected to this signal
regix
Re: Gnome makes application crash
Quote:
Originally Posted by regix
there are no other slots connected to this signal
Then maybe you should try to isolate the problem by stripping down your application?
Also check if it works with Qt 3.3.6 (although I didn't find anything related to your problem in the changelog).
Re: Gnome makes application crash
this is what I dit to trace the problem:
I commented everthing out inside changeTitleColor()
result : the application behaves normally
I comment out the line with QColorDialog
result : the application behaves normally
I comment everything out except for the line with QColorDialog
result : the application stops
The application that jacek posted worked fine.
I started it with gdb and it exited normally.
regix :eek:
Re: Gnome makes application crash
Quote:
Originally Posted by regix
The application that jacek posted worked fine.
Does it still work if you replace:
with
?
As long as my application works, it might mean that the problem lies in your code, not in Qt.
I should ask it earlier, but do you use threads in your application?
Re: Gnome makes application crash
g++ -c -pipe -O2 -fmessage-length=0 -Wall -D_FORTIFY_SOURCE=2 -g -DUSE_LIB64_PATHES -fno-strict-aliasing -Wall -W -g -O0 -DQT_SHARED -DQT_TABLET_SUPPORT -DQT_NO_DEBUG -DQT_THREAD_SUPPORT -I/usr/lib/qt3/mkspecs/default -I. -I/usr/include/Magick++ -I/usr/include/magick -I/usr/include -I/usr/lib/qt3/include -o editcssdlg.o editcssdlg.cpp
test -d ../bin/ || mkdir -p ../bin/
I had changed the changeTitleColor() function and compiled.
This is how the compiler compiles
The result remained the same : on GNOME the application stops
First I used a thread in my program, but later I decided not to use threads.
this is part of the .pro file :
LIBS += -lMagick \
-lMagick++
INCLUDEPATH += /usr/include/Magick++ \
/usr/include/magick
QMAKE_CXXFLAGS_DEBUG += -O0
TARGET = websitecreator
DESTDIR = ../bin
CONFIG += debug \
warn_on \
qt
TEMPLATE = app
Re: Gnome makes application crash
Quote:
Originally Posted by regix
The application that jacek posted worked fine.
I started it with gdb and it exited normally.
Maybe it works only in gdb? :confused:
Re: Gnome makes application crash
If you want I can send the source code and the kdevelop project file I am working with
I didn't test it with qt 3.3.6 as I have already installed two versions of qt and I wouldn't like this to clash with other applications.
regix
Re: Gnome makes application crash
Quote:
Originally Posted by regix
If you want I can send the source code and the kdevelop project file I am working with
The problem is that I don't have GNOME installed.
Re: Gnome makes application crash
I will try to put QColorDialogs in different parts of my application and see what that gives.
regix
Re: Gnome makes application crash
I found out that in certain dialogs I can put a QColorDialog::getColor call while in others this would end the application.
This was not limited to QColorDialog. Also some of the dialogs I created myself showed a similar behaviour.
Typicaly this occurs when I put the dialog in a dialog that is instatiated in another dialog, which on its turn is instatiated in another dialog. I occurs to me that it has to do with the depth of dialogresult call or something like that.
As I said this behaviour is not seen in KDE.
regix
1 Attachment(s)
Re: Gnome makes application crash
Quote:
Originally Posted by regix
Typicaly this occurs when I put the dialog in a dialog that is instatiated in another dialog, which on its turn is instatiated in another dialog.
That would be a quite weird bug. Check the attachment and see if it reproduces it.
Re: Gnome makes application crash
I tested your application and it behaves correctly.
The only thing I can think of is that I have a weird bug in my application.
regix :o