HPDF-1.5.0: Generation of PDF documents

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

Graphics.PDF.Coordinates

Contents

Description

Coordinates for a PDF document

Synopsis

Documentation

Geometry

Types

data Angle Source #

Angle

Constructors

Degree !PDFFloat

Angle in degrees

Radian !PDFFloat

Angle in radians

data Matrix Source #

A transformation matrix. An affine transformation a b c d e f

a b 0
c d 0
e f 1
Instances
Eq Matrix Source # 
Instance details

Defined in Graphics.PDF.Coordinates

Methods

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

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

Num Matrix Source # 
Instance details

Defined in Graphics.PDF.Coordinates

Show Matrix Source # 
Instance details

Defined in Graphics.PDF.Coordinates

Transformations

dot :: RealFloat t => Complex t -> Complex t -> t Source #

Dot product of two points 'dot (x :+ y) (a :+ b) == x * a + y * b' 'dot z w == magnitude z * magnitude w * cos (phase z - phase w)'

scalePt :: RealFloat t => t -> Complex t -> Complex t Source #

project :: RealFloat t => Complex t -> Complex t -> Complex t Source #

projects the first point onto the second

projectX :: RealFloat t => Complex t -> Complex t Source #

projects a point onto the x-axis

projectY :: RealFloat t => Complex t -> Complex t Source #

projects a point onto the y-axis

pointMatrix Source #

Arguments

:: Point

X component

-> Point

Y component

-> Point

translation component

-> Matrix 

Specifies a matrix as three points

transform :: Matrix -> Point -> Point Source #

Applies a matrix to a point

identity :: Matrix Source #

Identity matrix

rotate Source #

Arguments

:: Angle

Rotation angle

-> Matrix 

Rotation matrix

translate :: Point -> Matrix Source #

Translation matrix 'transform (translate z) w == z + w'

scale Source #

Arguments

:: PDFFloat

Horizontal scaling

-> PDFFloat

Vertical scaling

-> Matrix 

Scaling matrix