Language.Haskell.HsColour.Colourise

hscolour-1.24.1: Colourise Haskell code.

Safe Haskell | Safe
Language | Haskell98

Language.Haskell.HsColour.Colourise

Synopsis

- module Language.Haskell.HsColour.ColourHighlight
- data ColourPrefs = ColourPrefs {
  - keyword, keyglyph, layout, comment, conid, varid, conop, varop, string, char, number, cpp, selection, variantselection, definition :: [Highlight]
  }
- readColourPrefs :: IO ColourPrefs
- defaultColourPrefs :: ColourPrefs
- colourise :: ColourPrefs -> TokenType -> [Highlight]

# Documentation

module Language.Haskell.HsColour.ColourHighlight

data ColourPrefs #

Colour preferences.

Constructors

ColourPrefs |
Fields keyword, keyglyph, layout, comment, conid, varid, conop, varop, string, char, number, cpp, selection, variantselection, definition :: [Highlight]

Instances

Eq ColourPrefs # |
Methods (==) :: ColourPrefs -> ColourPrefs -> Bool # (/=) :: ColourPrefs -> ColourPrefs -> Bool #
Read ColourPrefs # |
Methods readsPrec :: Int -> ReadS ColourPrefs # readList :: ReadS [ColourPrefs] # readPrec :: ReadPrec ColourPrefs # readListPrec :: ReadPrec [ColourPrefs] #
Show ColourPrefs # |
Methods showsPrec :: Int -> ColourPrefs -> ShowS # show :: ColourPrefs -> String # showList :: [ColourPrefs] -> ShowS #

readColourPrefs :: IO ColourPrefs #

Read colour preferences from .hscolour file in the current directory, or failing that, from $HOME/.hscolour, and failing that, returns a default set of prefs.

defaultColourPrefs :: ColourPrefs #

colourise :: ColourPrefs -> TokenType -> [Highlight] #

Convert token classification to colour highlights.