[PyKDE] C++ conversion to python, using sip

Jonathan Gardner jgardner at jonathangardner.net
Sat Jun 28 19:55:01 BST 2003


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Friday 27 June 2003 19:32, Park joon cheol wrote:
>
>     bool            write (const QString  &section,
>                            const QString  &entry,
>                            int             value);
>
>     bool            write (const QString  &section,
>                            const QString  &entry,
>                            double          value);
>

I think you should abstract this out a little more if you expect mere 
mortals to use it. Python has been going in the way of merging the int and 
float types closer together than in C/C++ (For instance, 1/2 may equal 0.5 
in the future)

These two functions look pretty much the same to me from Python's 
perspective. I would put them together into one function call. It'll also 
save you a bit on the documentation side because you won't have to explain 
that the int function behaves differently from the float function.

That's just my opinion, though.

- -- 
Jonathan Gardner
jgardner at jonathangardner.net
(was jgardn at alumni.washington.edu)
Live Free, Use Linux!
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQE+/dYpWgwF3QvpWNwRAtyjAKCSb1A7Ri5ClWpQN1fO3Q3hIkbjcgCeM7Zc
eXbPGJN/CT26OikxpTYApcY=
=anSt
-----END PGP SIGNATURE-----




More information about the PyQt mailing list