Number of "connect"-commands limited (Qt/KDE-programming)?
ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Number of "connect"-commands limited (Qt/KDE-programming)?
Hi there,
I've a problem:
I tried to write a program using Qt. One of my dialogs (its a class derived from public KDialogBase) includes a number of QCheckBoxes. Each QCheckBox gets a QToolTip with the command QToolTip::add (). You can choose, wether all should be displayed, or not. (The QCheckBoxes are organized in seven packages you can choose for display.)
So far, so good. Everything works fine.
But it works only as long as I don't create 272 QCheckBoxes. Then, the program crashes.
-------------------------------
The crash-handler of KDE shows the following message:
[New Thread 1024 (LWP 1329)]
0x40b2e8c9 in wait4 () from /lib/libc.so.6
#0 0x40b2e8c9 in wait4 () from /lib/libc.so.6
#1 0x40ba9c90 in __DTOR_END__ () from /lib/libc.so.6
#2 0x400ef555 in KCrash::defaultCrashHandler(int) ()
from /opt/kde3/lib/libkdecore.so.4
#3 0x40d3f12b in pthread_sighandler () from /lib/libpthread.so.0
#4 <signal handler called>
#5 0x405c71b2 in QObject::connect(QObject const*, char const*, QObject const*, char const*) () from /usr/lib/libqt-mt.so.3
#6 0x406ddb86 in QTipManager::add(QRect const&, QWidget*, QRect const&, QString const&, QToolTipGroup*, QString const&, QToolTip*, bool) ()
from /usr/lib/libqt-mt.so.3
#7 0x406ddc24 in QTipManager::add(QWidget*, QRect const&, QString const&, QToolTipGroup*, QString const&, QToolTip*, bool) () from /usr/lib/libqt-mt.so.3
#8 0x406df59a in QToolTip::add(QWidget*, QString const&) ()
from /usr/lib/libqt-mt.so.3
#9 0x080776c1 in KartenWahlDialog::DistributeCheckBoxes(...)
-------------------------------
("KartenWahlDialog::DistributeCheckBoxes()" is my function.)
When I changed the functionality of my program, no longer using QToolTips but connect-commands instead, the program does exactly the same: Crashing, if I want to show all 272 possible QCheckBoxes, otherwise (~40 QCheckBoxes less) it works fine.
So I ask myself wether the number of "connect"-commands I can use is limited and when it is so, I can expand the limit.
By the way: If I disable the "QToolTip::add ()"-command, the 272 QCheckBoxes are shown without any problems.
For I need displaying the Tooltips if it's posiible, I ask YOU: Can anybody help me?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.