HPDF-1.4.10: Generation of PDF documents

Copyright(c) 2006-2016, alpheccar.org
LicenseBSD-style
Maintainermisc@NOSPAMalpheccar.org
Stabilityexperimental
Portabilityportable
Safe HaskellNone
LanguageHaskell2010

Graphics.PDF.Text

Contents

Description

PDF Text

Synopsis

Text

Types

data PDFText a Source #

The text monad

Instances

Monad PDFText Source # 

Methods

(>>=) :: PDFText a -> (a -> PDFText b) -> PDFText b #

(>>) :: PDFText a -> PDFText b -> PDFText b #

return :: a -> PDFText a #

fail :: String -> PDFText a #

Functor PDFText Source # 

Methods

fmap :: (a -> b) -> PDFText a -> PDFText b #

(<$) :: a -> PDFText b -> PDFText a #

Applicative PDFText Source # 

Methods

pure :: a -> PDFText a #

(<*>) :: PDFText (a -> b) -> PDFText a -> PDFText b #

(*>) :: PDFText a -> PDFText b -> PDFText b #

(<*) :: PDFText a -> PDFText b -> PDFText a #

MonadWriter Builder PDFText Source # 

Methods

writer :: (a, Builder) -> PDFText a #

tell :: Builder -> PDFText () #

listen :: PDFText a -> PDFText (a, Builder) #

pass :: PDFText (a, Builder -> Builder) -> PDFText a #

type UnscaledUnit = PDFFloat Source #

Unscaled unit (not scaled by the font size)

Functions

drawText :: PDFText a -> Draw a Source #

Draw a text in the draw monad

text :: PDFFont -> PDFFloat -> PDFFloat -> PDFString -> PDFText () Source #

Utility function to quickly display one line of text

toPDFString :: String -> PDFString Source #

Create a PDF string from an Haskell one

startNewLine :: PDFText () Source #

Start a new line (leading value must have been set)

displayText :: PDFString -> PDFText () Source #

Display some text

textStart :: PDFFloat -> PDFFloat -> PDFText () Source #

Set position for the text beginning

setFont :: PDFFont -> PDFText () Source #

Select a font to use

leading :: UnscaledUnit -> PDFText () Source #

Set leading value

charSpace :: UnscaledUnit -> PDFText () Source #

Set the additional char space

wordSpace :: UnscaledUnit -> PDFText () Source #

Set the additional word space

textScale :: PDFFloat -> PDFText () Source #

Set scaling factor for text

renderMode :: TextMode -> PDFText () Source #

Choose the text rendering mode

rise :: UnscaledUnit -> PDFText () Source #

Set the rise value

setTextMatrix :: Matrix -> PDFText () Source #

Set the text transformation matrix

ripText Source #

Arguments

:: PDFFont

Font

-> PDFString

String

-> [(PDFFloat, Char)]

List of chars and char width taking into account kerning