KDE 4 porting: KBabel Project configuration crashes, help needed
faure at kde.org
Wed Oct 11 23:33:59 BST 2006
On Saturday 07 October 2006 18:51, Stephan Johach wrote:
> KDbg shows, the assertion is triggered in
> KTabCtrl::Private::showTab(int index)
Ah, KTabCtl, not KTabCtrl, fooled my greps for a second ;)
Indeed ktabctltest showed the same crash on start.
Crash fixed, but now all widgets appear on start; ktabctl was trying to reimplement show() which isn't virtual.
Fixed, but now I see that the API mixes tab text and object names....
Changed API to use IDs like QTabBar/QTabWidget, isTabEnabled(text) is just broken api.
So anyway, how is KTabCtl different from QTabWidget? It uses a QTabBar too, it doesn't use
a stack widget, but it does pretty much the same. The docu said (among some wrong or confusing things)
that the difference was that the tabSelected signal is emitted before a page is selected,
so the page can be populated or updated at that point... but one can do that with QTabWidget
So I have to ask: how about we port the app code to QTabWidget and drop KTabCtl?
LXR says: kbabel, kbackgammon, kdeadmin/kdat, kdeadmin/lilo-config, some pykde examples,
and from playground: guidance and kbabeldebug. And I don't see any special use
of dynamic changes of contents or anything specific to KTabCtl.
(Note: ktabctltest looks crap because the large app-default font isn't taken into
account in any font metrics - but I see that the same happens with QTabWidget.
Strange; much be some unrelated bug, but probably using layouts instead of
calling adjustSize() once, would fix it.)
David Faure, faure at kde.org, sponsored by Trolltech to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).
More information about the kde-core-devel