Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- askEnter :: String -> IO ()
- askUser :: String -> IO String
- askUserListItem :: String -> [String] -> IO String
- data PromptConfig = PromptConfig {}
- promptYorn :: String -> IO Bool
- promptChar :: PromptConfig -> IO Char
User prompts
Ask the user for a line of input.
askUserListItem :: String -> [String] -> IO String Source #
askUserListItem prompt xs
enumerates xs
on the screen, allowing
the user to choose one of the items
promptChar :: PromptConfig -> IO Char Source #
Prompt the user for a character, among a list of possible ones. Always returns a lowercase character. This is because the default character (ie, the character shown in uppercase, that is automatically selected when the user presses the space bar) is shown as uppercase, hence users may want to enter it as uppercase.