Haskeline and asynchronous messages

Greetings, Does anyone have a suggestion on using Haskeline in an environment where another thread may be writing messages to the terminal -- is it possible to somehow print incoming messages above the input line without disturbing the input line? Thanks for any advice. -- Rob Leslie rob@mars.org

I've done something like this by using
Haskeline.MonadException.handle, and then using throwTo to interrupt
Haskeline.getInputLine. Unfortunately it wipes out the contents of
the input, so it wouldn't be very good for you, unless you can have
haskeline save it.
I too would like a way to interrupt and resume getInputLine without
messing up its state.
On Tue, Jan 6, 2015 at 1:57 PM, Rob Leslie
Greetings,
Does anyone have a suggestion on using Haskeline in an environment where another thread may be writing messages to the terminal -- is it possible to somehow print incoming messages above the input line without disturbing the input line?
Thanks for any advice.
-- Rob Leslie rob@mars.org
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

On Tue, Jan 6, 2015 at 3:27 AM, Rob Leslie
Does anyone have a suggestion on using Haskeline in an environment where another thread may be writing messages to the terminal -- is it possible to somehow print incoming messages above the input line without disturbing the input line?
Terminals don't really work that way; you need to be looking at something like curses or vty. -- brandon s allbery kf8nh sine nomine associates allbery.b@gmail.com ballbery@sinenomine.net unix, openafs, kerberos, infrastructure, xmonad http://sinenomine.net
participants (3)
-
Brandon Allbery
-
Evan Laforge
-
Rob Leslie