Subject: Re: [linux-audio-dev] Howto grab keys?
From: jaromil (jaromil_AT_dyne.org)
Date: Wed Sep 01 2004 - 13:00:18 EEST
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Fri, Aug 20, 2004 at 08:42:18AM -0400, Paul Davis wrote:
> the key element is setting up the tty in medium-raw mode so that you
> can get actual key events from the keyboard rather than ASCII chars
> the way that ncurses normally does.
hi Paul,
actually i found the S-Lang library to be also a good alternative to
absolve this task.
i used the callback technique described in the S-Lang programmer's
manual, implementing a non-blocking getkey using SLang_input_pending,
you can see the code i use in FreeJ here:
generally S-Lang results in being as portable as ncurses, but way
smaller in terms of size and slightly faster in terms of performance,
plus it's implementation in Apple-OSX is native.
ciao
- --
jaromil, dyne.org rasta coder, http://rastasoft.org
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)
Comment: Cryptographically signed mail, see http://gnupg.org
iD8DBQFBNZ2yWLCC1ltubZcRAg8nAJ0VAT6u5H5bP2gxU5AScVKyGaO2pwCffFNK
nk0DhYJ9UuWj1ZS5ukpSaZs=
=/ZsC
-----END PGP SIGNATURE-----
This archive was generated by hypermail 2b28 : Wed Sep 01 2004 - 13:04:05 EEST