trifecta-1.5: A modern parser combinator library with convenient diagnostics

Portabilitynon-portable
Stabilityexperimental
MaintainerEdward Kmett <ekmett@gmail.com>
Safe HaskellNone

Text.Trifecta.Rendering

Contents

Description

The type for Lines will very likely change over time, to enable drawing lit up multi-character versions of control characters for ^Z, ^[, 0xff, etc. This will make for much nicer diagnostics when working with protocols.

Synopsis

Documentation

class Source t whereSource

Methods

source :: t -> (Int64, Int64, Lines -> Lines)Source

rendered :: Source s => Delta -> s -> RenderingSource

create a drawing surface

Carets

data Caret Source

 In file included from baz.c:9
 In file included from bar.c:4
 foo.c:8:36: note
 int main(int argc, char ** argv) { int; }
                                    ^

Constructors

Caret !Delta !ByteString 

class HasCaret t whereSource

Methods

caret :: Lens' t CaretSource

Instances

Spans

class HasSpan t whereSource

Methods

span :: Lens' t SpanSource

addSpan :: Delta -> Delta -> Rendering -> RenderingSource

 int main(int argc, char ** argv) { int; }
                                    ^~~

Fixits

Drawing primitives

draw :: [SGR] -> Int -> Int64 -> String -> Lines -> LinesSource