Re: Type of combo-box-get-active-text
Rupert Swarbrick <[email protected]> Thu, 13 Nov 2008 16:07:26 +0000
| Newsgroups | gmane.lisp.clg.devel |
|---|---|
| Message-ID | <[email protected]> |
--===============6540481273203038689== Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Rupert Swarbrick <[email protected]> writes: > Rupert Swarbrick <[email protected]> writes: > >> If one calls combo-box-get-active-text on a combo with no selection, it >> returns NULL/nil, which contradicts the type specification. The >> following (trivial) patch fixes this. > > *sigh* No it doesn't. I meant (or string null), but that doesn't work > either since %defbinding actually uses from-alien-form to turn the > return value into something lisp understands... and isn't specialised > for (or string null) (of course). Gaargh. Right. It appears that (or null string) works. So is the following the right thing? Rupert --=-=-= Content-Type: text/x-diff Content-Disposition: inline *** gtk.lisp.~1.96.~ 2008-11-09 01:07:28.000000000 +0000 --- gtk.lisp 2008-11-13 15:56:07.000000000 +0000 *************** *** 788,794 **** (text string)) #?(pkg-exists-p "gtk+-2.0" :atleast-version "2.6.0") ! (defbinding combo-box-get-active-text () string (combo-box combo-box)) (defbinding combo-box-popup () nil --- 788,794 ---- (text string)) #?(pkg-exists-p "gtk+-2.0" :atleast-version "2.6.0") ! (defbinding combo-box-get-active-text () (or null string) (combo-box combo-box)) (defbinding combo-box-popup () nil --=-=-=-- --==-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iJwEAQECAAYFAkkcUL4ACgkQRtd/pJbYVobpNwQAgi3649/rKSDwg1jEn26GDO1H rrZ7nLeHRvu+XHoo13qFtpv1L4pnz1TG7WASGscZwT0sl4JeblYA+qWwUcDgWpIf BfNISAPMo0RXeaUt8OpbH4xkvZHo8VGktHt/yznGwmaV6J5WOj4saH+2tDfRMLXU b60NzNFZWDoeSIP+R/g= =IuCp -----END PGP SIGNATURE----- --==-=-=-- --===============6540481273203038689== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ --===============6540481273203038689== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Clg-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/clg-devel --===============6540481273203038689==--