hermit-0.7.1.0: Haskell Equational Reasoning Model-to-Implementation Tunnel

Safe HaskellNone
LanguageHaskell2010

HERMIT.PrettyPrinter.Common

Contents

Synopsis

Documents

type DocH = MDoc HermitMark Source

newtype HTML Source

Constructors

HTML String 

Instances

Monoid HTML 
RenderCode HTML

Use css to do the colors - - > type="text/css" - > .hermit-syntax { - > color: red; - > /style

RenderSpecial HTML 

Colors

Renderers

class (RenderSpecial a, Monoid a) => RenderCode a where Source

Minimal complete definition

rDoHighlight, rPutStr

Methods

rStart :: a Source

rEnd :: a Source

rDoHighlight Source

Arguments

:: Maybe Attr

Attr just popped, if any

-> [Attr]

Attr stack

-> a 

rPutStr :: String -> a Source

Instances

RenderCode HTML

Use css to do the colors - - > type="text/css" - > .hermit-syntax { - > color: red; - > /style

RenderCode ASCII 
RenderCode UnicodeTerminal 

newtype Unicode Source

Constructors

Unicode Char 

Pretty Printer Traversals

Pretty Printer Options

data PrettyOptions Source

Constructors

PrettyOptions 

Fields

po_fullyQualified :: Bool

Do you show fully qualified names?

po_exprTypes :: ShowOption

Do you hide types, and type arguments, as <>?

po_coercions :: ShowOption

Do you hide coercions?

po_typesForBinders :: ShowOption

Do you give the types for all bindings?

po_showUniques :: Bool

Append uniques to OccNames? (Like GHC does)

po_focus :: Maybe PathH

This region should be highlighted (is the current focus)

po_depth :: Maybe Int

below this depth are ..., Nothing => infinite

po_notes :: Bool

notes might be added to output

po_ribbon :: Float
 
po_width :: Int
 

Utilities

pad :: MDoc a -> MDoc a Source

wrap a document in spaces

hlist :: [MDoc a] -> MDoc a Source

like vcat and hcat, only make the list syntax explicit

vlist :: [MDoc a] -> MDoc a Source

like vcat and hcat, only make the list syntax explicit