[PyKDE] Basic question about custom slot/function
shlomme at gmx.net
Sun Jun 19 08:31:09 BST 2005
-----BEGIN PGP SIGNED MESSAGE-----
Kevin Walzer schrieb:
> I'm working on my first PyQt application, and to get a feel for signals
> and slots, I'm trying to have my application echo the text entered into
> a line edit widget to stdout. However, when I test this, what is printed
> is "Not implemented yet," which tells me I'm doing something wrong.
> Here is my ui.h code:
> void form1::LaunchFoo()
> ~ # get the text typed in the line edit
> ~ e = self.lineEdit1.text().ascii()
> ~ #show output
> ~ os.system('echo %s', e)
> ~ }
> I've also tried the simple statement "print %s, e", but I also get the
> "not implemented yet" error.
> Can anyone help point me in the right direction?
does the file generated by pyuic contain the code from LaunchFoo? Normally,
pyuic also prints out messages to the command line, if it imports function code.
Did you connect the signal "textChanged(const QString&)" to the slot LaunchFoo?
It seems unlikely to me, because LaunchFoo() has the wrong signature.
Maybe you might want to have a look at one of the tutorials listed in the wiki,
and also the tutorial of Qt Designer.
Torsten Marek <shlomme at gmx.net>
ID: A244C858 -- FP: 1902 0002 5DFC 856B F146 894C 7CC5 451E A244 C858
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
More information about the PyQt