haskus-system-0.6.0.0: Haskus system programming framework

Safe HaskellNone
LanguageHaskell2010

Haskus.System.Terminal

Description

Terminal helpers

Synopsis

Documentation

data Terminal Source #

Terminal (input and output, no error output)

defaultTerminal :: Sys Terminal Source #

Initialize a default terminal (using stdin, stdout)

readTermBytes :: Terminal -> Word64 -> Ptr a -> Sys (Future ()) Source #

Read bytes (asynchronous)

readTerm :: Storable a => Terminal -> Sys a Source #

Read a Storable (synchronous)

writeTermBytes :: Terminal -> Word64 -> Ptr a -> STM (Future ()) Source #

Write bytes

writeStrLn :: Terminal -> String -> Sys () Source #

Write a string

writeBuffer :: Terminal -> Buffer -> Sys () Source #

Write a buffer

writeBufferLn :: Terminal -> Buffer -> Sys () Source #

Write a buffer

writeText :: Terminal -> Text -> Sys () Source #

Write a text using UTF8 encoding

writeTextLn :: Terminal -> Text -> Sys () Source #

Write a text using UTF8 encoding

waitForKey :: Terminal -> Sys () Source #

Wait for a key to pressed