ansi-terminal-0.8.2: Simple ANSI terminal support, with Windows compatibility

Safe HaskellSafe
LanguageHaskell98

System.Console.ANSI.Types

Description

Types used to represent SELECT GRAPHIC RENDITION (SGR) aspects.

Synopsis

Documentation

data SGR #

ANSI Select Graphic Rendition command

Constructors

Reset 
SetConsoleIntensity !ConsoleIntensity 
SetItalicized !Bool

Not widely supported: sometimes treated as swapping foreground and background

SetUnderlining !Underlining 
SetBlinkSpeed !BlinkSpeed 
SetVisible !Bool

Not widely supported

SetSwapForegroundBackground !Bool 
SetColor !ConsoleLayer !ColorIntensity !Color 
SetRGBColor !ConsoleLayer !(Colour Float)

Supported from Windows 10 Creators Update

Instances
Eq SGR # 
Instance details

Defined in System.Console.ANSI.Types

Methods

(==) :: SGR -> SGR -> Bool #

(/=) :: SGR -> SGR -> Bool #

Read SGR # 
Instance details

Defined in System.Console.ANSI.Types

Show SGR # 
Instance details

Defined in System.Console.ANSI.Types

Methods

showsPrec :: Int -> SGR -> ShowS #

show :: SGR -> String #

showList :: [SGR] -> ShowS #

data ConsoleLayer #

ANSI colors can be set on two different layers

Constructors

Foreground 
Background 
Instances
Bounded ConsoleLayer # 
Instance details

Defined in System.Console.ANSI.Types

Enum ConsoleLayer # 
Instance details

Defined in System.Console.ANSI.Types

Eq ConsoleLayer # 
Instance details

Defined in System.Console.ANSI.Types

Ord ConsoleLayer # 
Instance details

Defined in System.Console.ANSI.Types

Read ConsoleLayer # 
Instance details

Defined in System.Console.ANSI.Types

Show ConsoleLayer # 
Instance details

Defined in System.Console.ANSI.Types

Ix ConsoleLayer # 
Instance details

Defined in System.Console.ANSI.Types

data Color #

ANSI colors: come in various intensities, which are controlled by ColorIntensity

Constructors

Black 
Red 
Green 
Yellow 
Blue 
Magenta 
Cyan 
White 
Instances
Bounded Color # 
Instance details

Defined in System.Console.ANSI.Types

Enum Color # 
Instance details

Defined in System.Console.ANSI.Types

Eq Color # 
Instance details

Defined in System.Console.ANSI.Types

Methods

(==) :: Color -> Color -> Bool #

(/=) :: Color -> Color -> Bool #

Ord Color # 
Instance details

Defined in System.Console.ANSI.Types

Methods

compare :: Color -> Color -> Ordering #

(<) :: Color -> Color -> Bool #

(<=) :: Color -> Color -> Bool #

(>) :: Color -> Color -> Bool #

(>=) :: Color -> Color -> Bool #

max :: Color -> Color -> Color #

min :: Color -> Color -> Color #

Read Color # 
Instance details

Defined in System.Console.ANSI.Types

Show Color # 
Instance details

Defined in System.Console.ANSI.Types

Methods

showsPrec :: Int -> Color -> ShowS #

show :: Color -> String #

showList :: [Color] -> ShowS #

Ix Color # 
Instance details

Defined in System.Console.ANSI.Types

data ColorIntensity #

ANSI colors come in two intensities

Constructors

Dull 
Vivid 
Instances
Bounded ColorIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Enum ColorIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Eq ColorIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Ord ColorIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Read ColorIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Show ColorIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Ix ColorIntensity # 
Instance details

Defined in System.Console.ANSI.Types

data ConsoleIntensity #

ANSI general console intensity: usually treated as setting the font style (e.g. BoldIntensity causes text to be bold)

Constructors

BoldIntensity 
FaintIntensity

Not widely supported: sometimes treated as concealing text

NormalIntensity 
Instances
Bounded ConsoleIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Enum ConsoleIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Eq ConsoleIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Ord ConsoleIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Read ConsoleIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Show ConsoleIntensity # 
Instance details

Defined in System.Console.ANSI.Types

Ix ConsoleIntensity # 
Instance details

Defined in System.Console.ANSI.Types

data Underlining #

ANSI text underlining

Constructors

SingleUnderline 
DoubleUnderline

Not widely supported

NoUnderline 
Instances
Bounded Underlining # 
Instance details

Defined in System.Console.ANSI.Types

Enum Underlining # 
Instance details

Defined in System.Console.ANSI.Types

Eq Underlining # 
Instance details

Defined in System.Console.ANSI.Types

Ord Underlining # 
Instance details

Defined in System.Console.ANSI.Types

Read Underlining # 
Instance details

Defined in System.Console.ANSI.Types

Show Underlining # 
Instance details

Defined in System.Console.ANSI.Types

Ix Underlining # 
Instance details

Defined in System.Console.ANSI.Types

data BlinkSpeed #

ANSI blink speeds: values other than NoBlink are not widely supported

Constructors

SlowBlink

Less than 150 blinks per minute

RapidBlink

More than 150 blinks per minute

NoBlink 
Instances
Bounded BlinkSpeed # 
Instance details

Defined in System.Console.ANSI.Types

Enum BlinkSpeed # 
Instance details

Defined in System.Console.ANSI.Types

Eq BlinkSpeed # 
Instance details

Defined in System.Console.ANSI.Types

Ord BlinkSpeed # 
Instance details

Defined in System.Console.ANSI.Types

Read BlinkSpeed # 
Instance details

Defined in System.Console.ANSI.Types

Show BlinkSpeed # 
Instance details

Defined in System.Console.ANSI.Types

Ix BlinkSpeed # 
Instance details

Defined in System.Console.ANSI.Types