uni-util-2.3.0.3: Utilities for the uniform workbench
Safe HaskellNone
LanguageHaskell2010

Util.Messages

Description

This module contains the hooks for displaying messages to the user (errors, alerts, warnings and the like) and getting yes/no responses.

The idea is that these are by default textual, and go via stdin, stdout and stderr . However if the DialogWin function useHTk is invoked, windows will pop up.

Synopsis

Documentation

alertMess :: String -> IO () Source #

Display an alert

errorMess :: String -> IO () Source #

Display an error

warningMess :: String -> IO () Source #

Display a warning message

confirmMess :: String -> IO Bool Source #

Confirm something with the user.

messageMess :: String -> IO () Source #

Display some informational message.

htkPresent :: IO Bool Source #

If True, indicates that the flag corresponding to a graphical mode has been set. This is used occasionally for deciding whether to ask the user something on stdout, stdin or via a window.

textQuery :: String -> IO String Source #

queries the user on stdout getting the answer from stdin. Leading and trailing spaces are trimmed from the result.

errorMess2 :: String -> IO () Source #

Display a series of one-line messages, separated by newline characters, attempting to combine them together and eliminate duplicates as much as possible. If other identical messages come in while the error message is being delayed, we throw them away.

data MessFns Source #

Constructors

MessFns 

Fields