Accelerator problems in KDevelop-2.1.3+Qt3+KDE-3
jens.zurheide at gmx.de
Sun Aug 4 17:17:02 UTC 2002
I am currently trying to hunt down an accelerator key problem of
KDevelop-2.1.3 (cvs) that I believe has its root in the libraries (qt
and/or kde-3) because it is only present in the version for KDE-3.1 (maybe
KDE-3 but disk space is limited) but not in the version for KDE-2.
Now my first question: does anybody see the problem that the "Repeat
search"-key (default: F3) does not work in KDE-3.1 but works fine in
KDE-2.x? The funny thing is that "Repeat backward search" (default:
Shift+F3) works for both setups.
My current setup: enhanced SuSE 7.3 (upgraded to XFree-4.2, QT (QT-copy,
3.0.6 beta), KDE-3.1cvs).
One possible reason I have found is a strange/unsafe conversion in
488 QWidget* w = (QWidget*) parent();
489 while ( w && !w->testWFlags( WSubWindow ) )
(gdb) whatis this => type = QAccel *
(gdb) print *(QAccel *)this => displays somewhere 'objname = 0x48be063c
(gdb) whatis this->parent() ) => type = QObject *
which is correct but
(gdb) print this->parent()->className() => "KActionCollection"
Maybe there should be a test like parent()->inherits( "QWidget" ) before
performing the cast or a dynamic_cast<QWidget *>( parent() ) (which of
course needs the handling of the resulting NULL-pointer).
For the record: valgrind reports "Invalid read of size 4" in
kernel/qwidget.h:674 (I hope, this is not the intended behaviour ;) ).
Even after looking some time at the kdelibs sources for the accelerators I
don't know from where QAccel gets a parent of type KActionCollection.
Who can help me solving this problem or should I just switch to Gideon? But
if the problem is really inside the libraries it would be good to fix it
PS: If you need a backtrace, just let me know
More information about the KDevelop-devel