chatty-0.6.1.0: Some monad transformers and typeclasses for abstraction of global dependencies.

Safe HaskellSafe-Inferred

Text.Chatty.Extended.Printer

Description

Provides an extended printer class that supports colours.

Synopsis

Documentation

class ChPrinter m => ChExtendedPrinter m whereSource

Typeclass for all printers that support colourized output.

Methods

ebracket :: Colour -> m a -> m aSource

Run the function with the given colour.

eprint :: Colour -> String -> m ()Source

Print the string in the given colour.

eprintLn :: Colour -> String -> m ()Source

Print the string in the given colour and terminate the line.

enomask :: Colour -> String -> m ()Source

Print the string in the given colour without masking.

enomaskLn :: Colour -> String -> m ()Source

Print the string in the given colour without masking and terminate the line.

estart :: Colour -> m ()Source

Start using the specified colour.

efin :: m ()Source

Reset colour.

data Tone Source

Colour tone.

Constructors

Green 
Red 
Yellow 
Blue 
Black 
White 
Cyan 
Magenta 

data Colour Source

Colour brightness

Constructors

Dull Tone 
Vivid Tone