-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | SVG file loader and serializer
--   
--   svg-tree provides types representing a SVG document, and allows to
--   load and save it.
--   
--   The types definition are aimed at rendering, so they are rather
--   comple. For simpler SVG document building, look after `lucid-svg`.
--   
--   To render an svg document you can use the `rasterific-svg` package
@package svg-tree
@version 0.6.2.3


-- | Define the types used to describes CSS elements
module Graphics.Svg.CssTypes

-- | Define complex selector.
data CssSelector

-- | Correspond to the <a>+</a> CSS selector.
Nearby :: CssSelector

-- | Correspond to the <a>&gt;</a> CSS selectro.
DirectChildren :: CssSelector

-- | Grouping construct, all the elements of the list must be matched.
AllOf :: [CssDescriptor] -> CssSelector

-- | A CssSelectorRule is a list of all the elements that must be meet in a
--   depth first search fashion.
type CssSelectorRule = [CssSelector]

-- | Represent a CSS selector and the different declarations to apply to
--   the matched elemens.
data CssRule
CssRule :: ![CssSelectorRule] -> ![CssDeclaration] -> CssRule

-- | At the first level represent a list of elements to be matched. If any
--   match is made, you can apply the declarations. At the second level
[cssRuleSelector] :: CssRule -> ![CssSelectorRule]

-- | Declarations to apply to the matched element.
[cssDeclarations] :: CssRule -> ![CssDeclaration]

-- | Describe an element of a CSS selector. Multiple elements can be
--   combined in a CssSelector type.
data CssDescriptor

-- | .IDENT
OfClass :: Text -> CssDescriptor

-- | IDENT
OfName :: Text -> CssDescriptor

-- | #IDENT
OfId :: Text -> CssDescriptor

-- | `:IDENT` (ignore function syntax)
OfPseudoClass :: Text -> CssDescriptor

-- | <a>*</a>
AnyElem :: CssDescriptor

-- | ``
WithAttrib :: Text -> Text -> CssDescriptor

-- | Represent the content to apply to some CSS matched rules.
data CssDeclaration
CssDeclaration :: Text -> [[CssElement]] -> CssDeclaration

-- | Property name to change (like font-family or color).
[_cssDeclarationProperty] :: CssDeclaration -> Text

-- | List of values
[_cssDecarationlValues] :: CssDeclaration -> [[CssElement]]

-- | Value of a CSS property.
data CssElement
CssIdent :: !Text -> CssElement
CssString :: !Text -> CssElement
CssReference :: !Text -> CssElement
CssNumber :: !Number -> CssElement
CssColor :: !PixelRGBA8 -> CssElement
CssFunction :: !Text -> ![CssElement] -> CssElement
CssOpComa :: CssElement
CssOpSlash :: CssElement

-- | Interface for elements to be matched against some CssRule.
class CssMatcheable a

-- | For an element, tell its optional ID attribute.
cssIdOf :: CssMatcheable a => a -> Maybe Text

-- | For an element, return all of it's class attributes.
cssClassOf :: CssMatcheable a => a -> [Text]

-- | Return the name of the tagname of the element
cssNameOf :: CssMatcheable a => a -> Text

-- | Return a value of a given attribute if present
cssAttribOf :: CssMatcheable a => a -> Text -> Maybe Text

-- | Represent a zipper in depth at the first list level, and the previous
--   nodes at in the second list level.
type CssContext a = [[a]]

-- | Alias describing a "dot per inch" information used for size
--   calculation (see toUserUnit).
type Dpi = Int

-- | Encode complex number possibly dependant to the current render size.
data Number

-- | Simple coordinate in current user coordinate.
Num :: Double -> Number

-- | With suffix "px"
Px :: Double -> Number

-- | Number relative to the current font size.
Em :: Double -> Number

-- | Number relative to the current viewport size.
Percent :: Double -> Number
Pc :: Double -> Number

-- | Number in millimeters, relative to DPI.
Mm :: Double -> Number

-- | Number in centimeters, relative to DPI.
Cm :: Double -> Number

-- | Number in points, relative to DPI.
Point :: Double -> Number

-- | Number in inches, relative to DPI.
Inches :: Double -> Number

-- | Encode the number to string which can be used in a CSS or a svg
--   attributes.
serializeNumber :: Number -> String

-- | Given CSS rules, find all the declaration to apply to the element in a
--   given context.
findMatchingDeclarations :: CssMatcheable a => [CssRule] -> CssContext a -> [CssDeclaration]

-- | This function replace all device dependant units to user units given
--   it's DPI configuration. Preserve percentage and "em" notation.
toUserUnit :: Dpi -> Number -> Number

-- | Helper function to modify inner value of a number
mapNumber :: (Double -> Double) -> Number -> Number

-- | Serialize an element to a text builder.
tserialize :: TextBuildable a => a -> Builder
instance GHC.Show.Show Graphics.Svg.CssTypes.CssRule
instance GHC.Classes.Eq Graphics.Svg.CssTypes.CssRule
instance GHC.Show.Show Graphics.Svg.CssTypes.CssDeclaration
instance GHC.Classes.Eq Graphics.Svg.CssTypes.CssDeclaration
instance GHC.Show.Show Graphics.Svg.CssTypes.CssElement
instance GHC.Classes.Eq Graphics.Svg.CssTypes.CssElement
instance GHC.Show.Show Graphics.Svg.CssTypes.Number
instance GHC.Classes.Eq Graphics.Svg.CssTypes.Number
instance GHC.Show.Show Graphics.Svg.CssTypes.CssSelector
instance GHC.Classes.Eq Graphics.Svg.CssTypes.CssSelector
instance GHC.Show.Show Graphics.Svg.CssTypes.CssDescriptor
instance GHC.Classes.Eq Graphics.Svg.CssTypes.CssDescriptor
instance Graphics.Svg.CssTypes.TextBuildable Graphics.Svg.CssTypes.CssRule
instance Graphics.Svg.CssTypes.TextBuildable Graphics.Svg.CssTypes.CssDeclaration
instance Graphics.Svg.CssTypes.TextBuildable Graphics.Svg.CssTypes.CssElement
instance Graphics.Svg.CssTypes.TextBuildable Graphics.Svg.CssTypes.Number
instance Graphics.Svg.CssTypes.TextBuildable Graphics.Svg.CssTypes.CssSelector
instance Graphics.Svg.CssTypes.TextBuildable Graphics.Svg.CssTypes.CssDescriptor


-- | This module define all the types used in the definition of a svg
--   scene.
--   
--   Most of the types are lensified.
module Graphics.Svg.Types

-- | Basic coordinate type.
type Coord = Double

-- | Tell if a path command is absolute (in the current user coordiante) or
--   relative to the previous poitn.
data Origin

-- | Next point in absolute coordinate
OriginAbsolute :: Origin

-- | Next point relative to the previous
OriginRelative :: Origin

-- | Possibly context dependant point.
type Point = (Number, Number)

-- | Real Point, fully determined and not dependant of the rendering
--   context.
type RPoint = V2 Coord

-- | Path command definition.
data PathCommand

-- | <tt>M</tt> or <tt>m</tt> command
MoveTo :: !Origin -> ![RPoint] -> PathCommand

-- | Line to, <tt>L</tt> or <tt>l</tt> Svg path command.
LineTo :: !Origin -> ![RPoint] -> PathCommand

-- | Equivalent to the <tt>H</tt> or <tt>h</tt> svg path command.
HorizontalTo :: !Origin -> ![Coord] -> PathCommand

-- | Equivalent to the <tt>V</tt> or <tt>v</tt> svg path command.
VerticalTo :: !Origin -> ![Coord] -> PathCommand

-- | Cubic bezier, <tt>C</tt> or <tt>c</tt> command
CurveTo :: !Origin -> ![(RPoint, RPoint, RPoint)] -> PathCommand

-- | Smooth cubic bezier, equivalent to <tt>S</tt> or <tt>s</tt> command
SmoothCurveTo :: !Origin -> ![(RPoint, RPoint)] -> PathCommand

-- | Quadratic bezier, <tt>Q</tt> or <tt>q</tt> command
QuadraticBezier :: !Origin -> ![(RPoint, RPoint)] -> PathCommand

-- | Quadratic bezier, <tt>T</tt> or <tt>t</tt> command
SmoothQuadraticBezierCurveTo :: !Origin -> ![RPoint] -> PathCommand

-- | Eliptical arc, <tt>A</tt> or <tt>a</tt> command.
EllipticalArc :: !Origin -> ![(Coord, Coord, Coord, Bool, Bool, RPoint)] -> PathCommand

-- | Close the path, <tt>Z</tt> or <tt>z</tt> svg path command.
EndPath :: PathCommand

-- | Describe the content of the <tt>transformation</tt> attribute. see
--   <a>_transform</a> and <a>transform</a>.
data Transformation

-- | Directly encode the translation matrix.
TransformMatrix :: !Coord -> !Coord -> !Coord -> !Coord -> !Coord -> !Coord -> Transformation

-- | Translation along a vector
Translate :: !Double -> !Double -> Transformation

-- | Scaling on both axis or on X axis and Y axis.
Scale :: !Double -> !Maybe Double -> Transformation

-- | Rotation around `(0, 0)` or around an optional point.
Rotate :: !Double -> !Maybe (Double, Double) -> Transformation

-- | Skew transformation along the X axis.
SkewX :: !Double -> Transformation

-- | Skew transformation along the Y axis.
SkewY :: !Double -> Transformation

-- | Unkown transformation, like identity.
TransformUnknown :: Transformation

-- | Correspond to the possible values of the the attributes which are
--   either <tt>none</tt> or `url(#elem)`
data ElementRef

-- | Value for <tt>none</tt>
RefNone :: ElementRef

-- | Equivalent to `url()` attribute.
Ref :: String -> ElementRef

-- | Define the possible values of various *units attributes used in the
--   definition of the gradients and masks.
data CoordinateUnits

-- | <tt>userSpaceOnUse</tt> value
CoordUserSpace :: CoordinateUnits

-- | <tt>objectBoundingBox</tt> value
CoordBoundingBox :: CoordinateUnits

-- | Little helper function to build a point.
toPoint :: Number -> Number -> Point

-- | Encode the number to string which can be used in a CSS or a svg
--   attributes.
serializeNumber :: Number -> String

-- | Convert the Transformation to a string which can be directly used in a
--   svg attributes.
serializeTransformation :: Transformation -> String

-- | Transform a list of transformations to a string for svg
--   <a>transform</a> attributes.
serializeTransformations :: [Transformation] -> String

-- | Describe how the line should be terminated when stroking them.
--   Describe the values of the `stroke-linecap` attribute. See
--   <a>_strokeLineCap</a>
data Cap

-- | End with a round (<a>round</a> value)
CapRound :: Cap

-- | Define straight just at the end (<tt>butt</tt> value)
CapButt :: Cap

-- | Straight further of the ends (<tt>square</tt> value)
CapSquare :: Cap

-- | Define the possible values of the `stroke-linejoin` attribute. see
--   <a>_strokeLineJoin</a>
data LineJoin

-- | <tt>miter</tt> value
JoinMiter :: LineJoin

-- | <tt>bevel</tt> value
JoinBevel :: LineJoin

-- | <a>round</a> value
JoinRound :: LineJoin

-- | Main type for the scene description, reorient to specific type
--   describing each tag.
data Tree
None :: Tree
UseTree :: !Use -> !Maybe Tree -> Tree
[useInformation] :: Tree -> !Use
[useSubTree] :: Tree -> !Maybe Tree
GroupTree :: !Group Tree -> Tree
SymbolTree :: !Symbol Tree -> Tree
PathTree :: !Path -> Tree
CircleTree :: !Circle -> Tree
PolyLineTree :: !PolyLine -> Tree
PolygonTree :: !Polygon -> Tree
EllipseTree :: !Ellipse -> Tree
LineTree :: !Line -> Tree
RectangleTree :: !Rectangle -> Tree
TextTree :: !Maybe TextPath -> !Text -> Tree
ImageTree :: !Image -> Tree
MeshGradientTree :: !MeshGradient -> Tree

-- | Encode complex number possibly dependant to the current render size.
data Number

-- | Simple coordinate in current user coordinate.
Num :: Double -> Number

-- | With suffix "px"
Px :: Double -> Number

-- | Number relative to the current font size.
Em :: Double -> Number

-- | Number relative to the current viewport size.
Percent :: Double -> Number
Pc :: Double -> Number

-- | Number in millimeters, relative to DPI.
Mm :: Double -> Number

-- | Number in centimeters, relative to DPI.
Cm :: Double -> Number

-- | Number in points, relative to DPI.
Point :: Double -> Number

-- | Number in inches, relative to DPI.
Inches :: Double -> Number

-- | Define the possible values for the <tt>spreadMethod</tt> values used
--   for the gradient definitions.
data Spread

-- | <tt>reapeat</tt> value
SpreadRepeat :: Spread

-- | <tt>pad</tt> value
SpreadPad :: Spread

-- | `reflect value`
SpreadReflect :: Spread

-- | Describe the different value which can be used in the <tt>fill</tt> or
--   <tt>stroke</tt> attributes.
data Texture

-- | Direct solid color (rgb)
ColorRef :: PixelRGBA8 -> Texture

-- | Link to a complex texture (url(#name))
TextureRef :: String -> Texture

-- | Equivalent to the <tt>none</tt> value.
FillNone :: Texture

-- | Sum types helping keeping track of all the namable elemens in a SVG
--   document.
data Element
ElementLinearGradient :: LinearGradient -> Element
ElementRadialGradient :: RadialGradient -> Element
ElementMeshGradient :: MeshGradient -> Element
ElementGeometry :: Tree -> Element
ElementPattern :: Pattern -> Element
ElementMarker :: Marker -> Element
ElementMask :: Mask -> Element
ElementClipPath :: ClipPath -> Element

-- | Describe the possile filling algorithms. Map the values of the
--   `fill-rule` attributes.
data FillRule

-- | Correspond to the <tt>evenodd</tt> value.
FillEvenOdd :: FillRule

-- | Correspond to the <tt>nonzero</tt> value.
FillNonZero :: FillRule

-- | Classify the font style, used to search a matching font in the
--   FontCache.
data FontStyle
FontStyleNormal :: FontStyle
FontStyleItalic :: FontStyle
FontStyleOblique :: FontStyle

-- | Alias describing a "dot per inch" information used for size
--   calculation (see toUserUnit).
type Dpi = Int

-- | Define an empty 'default' element for the SVG tree. It is used as base
--   when parsing the element from XML.
class WithDefaultSvg a

-- | The default element.
defaultSvg :: WithDefaultSvg a => a

-- | Represent a full svg document with style, geometry and named elements.
data Document
Document :: Maybe (Double, Double, Double, Double) -> Maybe Number -> Maybe Number -> [Tree] -> Map String Element -> String -> [CssRule] -> FilePath -> Document
[_viewBox] :: Document -> Maybe (Double, Double, Double, Double)
[_width] :: Document -> Maybe Number
[_height] :: Document -> Maybe Number
[_elements] :: Document -> [Tree]
[_definitions] :: Document -> Map String Element
[_description] :: Document -> String
[_styleRules] :: Document -> [CssRule]
[_documentLocation] :: Document -> FilePath

-- | Lenses associated to a SVG document.
class HasDocument c_aqpq
document :: HasDocument c_aqpq => Lens' c_aqpq Document
definitions :: HasDocument c_aqpq => Lens' c_aqpq (Map String Element)
description :: HasDocument c_aqpq => Lens' c_aqpq String
documentLocation :: HasDocument c_aqpq => Lens' c_aqpq FilePath
elements :: HasDocument c_aqpq => Lens' c_aqpq [Tree]
height :: HasDocument c_aqpq => Lens' c_aqpq (Maybe Number)
styleRules :: HasDocument c_aqpq => Lens' c_aqpq [CssRule]
viewBox :: HasDocument c_aqpq => Lens' c_aqpq (Maybe (Double, Double, Double, Double))
width :: HasDocument c_aqpq => Lens' c_aqpq (Maybe Number)

-- | Calculate the document size in function of the different available
--   attributes in the document.
documentSize :: Dpi -> Document -> (Int, Int)

-- | This type define how to draw any primitives, which color to use, how
--   to stroke the primitives and the potential transformations to use.
--   
--   All these attributes are propagated to the children.
data DrawAttributes
DrawAttributes :: !Last Number -> !Last Texture -> !Maybe Float -> !Last Cap -> !Last LineJoin -> !Last Double -> !Last Texture -> !Maybe Float -> !Maybe Float -> !Maybe [Transformation] -> !Last FillRule -> !Last ElementRef -> !Last ElementRef -> !Last FillRule -> ![Text] -> !Maybe String -> !Last Number -> !Last [Number] -> !Last Number -> !Last [String] -> !Last FontStyle -> !Last TextAnchor -> !Last ElementRef -> !Last ElementRef -> !Last ElementRef -> DrawAttributes

-- | Attribute corresponding to the `stroke-width` SVG attribute.
[_strokeWidth] :: DrawAttributes -> !Last Number

-- | Correspond to the <tt>stroke</tt> attribute.
[_strokeColor] :: DrawAttributes -> !Last Texture

-- | Define the `stroke-opacity` attribute, the transparency for the
--   "border".
[_strokeOpacity] :: DrawAttributes -> !Maybe Float

-- | Correspond to the `stroke-linecap` SVG attribute
[_strokeLineCap] :: DrawAttributes -> !Last Cap

-- | Correspond to the `stroke-linejoin` SVG attribute
[_strokeLineJoin] :: DrawAttributes -> !Last LineJoin

-- | Define the distance of the miter join, correspond to the
--   `stroke-miterlimit` attritbue.
[_strokeMiterLimit] :: DrawAttributes -> !Last Double

-- | Define the filling color of the elements. Corresponding to the
--   <tt>fill</tt> attribute.
[_fillColor] :: DrawAttributes -> !Last Texture

-- | Define the `fill-opacity` attribute, the transparency for the
--   "content".
[_fillOpacity] :: DrawAttributes -> !Maybe Float

-- | Define the global or group opacity attribute.
[_groupOpacity] :: DrawAttributes -> !Maybe Float

-- | Content of the <a>transform</a> attribute
[_transform] :: DrawAttributes -> !Maybe [Transformation]

-- | Define the `fill-rule` used during the rendering.
[_fillRule] :: DrawAttributes -> !Last FillRule

-- | Define the <a>mask</a> attribute.
[_maskRef] :: DrawAttributes -> !Last ElementRef

-- | Define the `clip-path` attribute.
[_clipPathRef] :: DrawAttributes -> !Last ElementRef

-- | Define the `clip-rule` attribute.
[_clipRule] :: DrawAttributes -> !Last FillRule

-- | Map to the `class` attribute. Used for the CSS rewriting.
[_attrClass] :: DrawAttributes -> ![Text]

-- | Map to the <a>id</a> attribute. Used for the CSS rewriting.
[_attrId] :: DrawAttributes -> !Maybe String

-- | Define the start distance of the dashing pattern. Correspond to the
--   `stroke-dashoffset` attribute.
[_strokeOffset] :: DrawAttributes -> !Last Number

-- | Define the dashing pattern for the lines. Correspond to the
--   `stroke-dasharray` attribute.
[_strokeDashArray] :: DrawAttributes -> !Last [Number]

-- | Current size of the text, correspond to the `font-size` SVG attribute.
[_fontSize] :: DrawAttributes -> !Last Number

-- | Define the possible fonts to be used for text rendering. Map to the
--   `font-family` attribute.
[_fontFamily] :: DrawAttributes -> !Last [String]

-- | Map to the `font-style` attribute.
[_fontStyle] :: DrawAttributes -> !Last FontStyle

-- | Define how to interpret the text position, correspond to the
--   `text-anchor` attribute.
[_textAnchor] :: DrawAttributes -> !Last TextAnchor

-- | Define the marker used for the start of the line. Correspond to the
--   `marker-start` attribute.
[_markerStart] :: DrawAttributes -> !Last ElementRef

-- | Define the marker used for every point of the polyline/path Correspond
--   to the `marker-mid` attribute.
[_markerMid] :: DrawAttributes -> !Last ElementRef

-- | Define the marker used for the end of the line. Correspond to the
--   `marker-end` attribute.
[_markerEnd] :: DrawAttributes -> !Last ElementRef

-- | Lenses for the DrawAttributes type.
class HasDrawAttributes a
drawAttributes :: HasDrawAttributes a => Lens' a DrawAttributes
attrClass :: HasDrawAttributes a => Lens' a [Text]
attrId :: HasDrawAttributes a => Lens' a (Maybe String)
clipPathRef :: HasDrawAttributes a => Lens' a (Last ElementRef)
clipRule :: HasDrawAttributes a => Lens' a (Last FillRule)
fillColor :: HasDrawAttributes a => Lens' a (Last Texture)
fillOpacity :: HasDrawAttributes a => Lens' a (Maybe Float)
fillRule :: HasDrawAttributes a => Lens' a (Last FillRule)
fontFamily :: HasDrawAttributes a => Lens' a (Last [String])
fontSize :: HasDrawAttributes a => Lens' a (Last Number)
fontStyle :: HasDrawAttributes a => Lens' a (Last FontStyle)
groupOpacity :: HasDrawAttributes a => Lens' a (Maybe Float)
markerEnd :: HasDrawAttributes a => Lens' a (Last ElementRef)
markerMid :: HasDrawAttributes a => Lens' a (Last ElementRef)
markerStart :: HasDrawAttributes a => Lens' a (Last ElementRef)
maskRef :: HasDrawAttributes a => Lens' a (Last ElementRef)
strokeColor :: HasDrawAttributes a => Lens' a (Last Texture)
strokeDashArray :: HasDrawAttributes a => Lens' a (Last [Number])
strokeLineCap :: HasDrawAttributes a => Lens' a (Last Cap)
strokeLineJoin :: HasDrawAttributes a => Lens' a (Last LineJoin)
strokeMiterLimit :: HasDrawAttributes a => Lens' a (Last Double)
strokeOffset :: HasDrawAttributes a => Lens' a (Last Number)
strokeOpacity :: HasDrawAttributes a => Lens' a (Maybe Float)
strokeWidth :: HasDrawAttributes a => Lens' a (Last Number)
textAnchor :: HasDrawAttributes a => Lens' a (Last TextAnchor)
transform :: HasDrawAttributes a => Lens' a (Maybe [Transformation])

-- | Class helping find the drawing attributes for all the SVG attributes.
class WithDrawAttributes a

-- | Lens which can be used to read/write primitives.
drawAttr :: WithDrawAttributes a => Lens' a DrawAttributes

-- | Define a rectangle. Correspond to `&lt;rectangle&gt;` svg tag.
data Rectangle
Rectangle :: !DrawAttributes -> !Point -> !Number -> !Number -> !(Number, Number) -> Rectangle

-- | Rectangle drawing attributes.
[_rectDrawAttributes] :: Rectangle -> !DrawAttributes

-- | Upper left corner of the rectangle, correspond to the attributes
--   <tt>x</tt> and <tt>y</tt>.
[_rectUpperLeftCorner] :: Rectangle -> !Point

-- | Rectangle width, correspond, strangely, to the <a>width</a> attribute.
[_rectWidth] :: Rectangle -> !Number

-- | Rectangle height, correspond, amazingly, to the <a>height</a>
--   attribute.
[_rectHeight] :: Rectangle -> !Number

-- | Define the rounded corner radius radius of the rectangle. Correspond
--   to the <tt>rx</tt> and <tt>ry</tt> attributes.
[_rectCornerRadius] :: Rectangle -> !(Number, Number)

-- | Lenses for the Rectangle type.
class HasRectangle a
rectangle :: HasRectangle a => Lens' a Rectangle
rectCornerRadius :: HasRectangle a => Lens' a (Number, Number)
rectDrawAttributes :: HasRectangle a => Lens' a DrawAttributes
rectHeight :: HasRectangle a => Lens' a Number
rectUpperLeftCorner :: HasRectangle a => Lens' a Point
rectWidth :: HasRectangle a => Lens' a Number

-- | Define a simple line. Correspond to the `&lt;line&gt;` tag.
data Line
Line :: !DrawAttributes -> !Point -> !Point -> Line

-- | Drawing attributes of line.
[_lineDrawAttributes] :: Line -> !DrawAttributes

-- | First point of the the line, correspond to the <tt>x1</tt> and
--   <tt>y1</tt> attributes.
[_linePoint1] :: Line -> !Point

-- | Second point of the the line, correspond to the <tt>x2</tt> and
--   <tt>y2</tt> attributes.
[_linePoint2] :: Line -> !Point

-- | Lenses for the Line type.
class HasLine a
line :: HasLine a => Lens' a Line
lineDrawAttributes :: HasLine a => Lens' a DrawAttributes
linePoint1 :: HasLine a => Lens' a Point
linePoint2 :: HasLine a => Lens' a Point

-- | Primitive decriving polygon composed of segements. Correspond to the
--   `&lt;polygon&gt;` tag
data Polygon
Polygon :: !DrawAttributes -> ![RPoint] -> Polygon

-- | Drawing attributes for the polygon.
[_polygonDrawAttributes] :: Polygon -> !DrawAttributes

-- | Points of the polygon. Correspond to the <tt>points</tt> attributes.
[_polygonPoints] :: Polygon -> ![RPoint]

-- | Lenses for the Polygon type
class HasPolygon a
polygon :: HasPolygon a => Lens' a Polygon
polygonDrawAttributes :: HasPolygon a => Lens' a DrawAttributes
polygonPoints :: HasPolygon a => Lens' a [RPoint]

-- | This primitive describe an unclosed suite of segments. Correspond to
--   the `&lt;polyline&gt;` tag.
data PolyLine
PolyLine :: !DrawAttributes -> ![RPoint] -> PolyLine

-- | drawing attributes of the polyline.
[_polyLineDrawAttributes] :: PolyLine -> !DrawAttributes

-- | Geometry definition of the polyline. correspond to the <tt>points</tt>
--   attribute
[_polyLinePoints] :: PolyLine -> ![RPoint]

-- | Lenses for the PolyLine type.
class HasPolyLine a
polyLine :: HasPolyLine a => Lens' a PolyLine
polyLineDrawAttributes :: HasPolyLine a => Lens' a DrawAttributes
polyLinePoints :: HasPolyLine a => Lens' a [RPoint]

-- | Type mapping the `&lt;path&gt;` svg tag.
data Path
Path :: !DrawAttributes -> ![PathCommand] -> Path

-- | Drawing attributes of the path.
[_pathDrawAttributes] :: Path -> !DrawAttributes

-- | Definition of the path, correspond to the <tt>d</tt> attributes.
[_pathDefinition] :: Path -> ![PathCommand]

-- | Lenses for the Path type
class HasPath c_alhy
path :: HasPath c_alhy => Lens' c_alhy Path
pathDefinition :: HasPath c_alhy => Lens' c_alhy [PathCommand]
pathDrawAttributes :: HasPath c_alhy => Lens' c_alhy DrawAttributes

-- | Define a `&lt;circle&gt;`.
data Circle
Circle :: !DrawAttributes -> !Point -> !Number -> Circle

-- | Drawing attributes of the circle.
[_circleDrawAttributes] :: Circle -> !DrawAttributes

-- | Define the center of the circle, describe the <tt>cx</tt> and
--   <tt>cy</tt> attributes.
[_circleCenter] :: Circle -> !Point

-- | Radius of the circle, equivalent to the <tt>r</tt> attribute.
[_circleRadius] :: Circle -> !Number

-- | Lenses for the Circle type.
class HasCircle a
circle :: HasCircle a => Lens' a Circle
circleCenter :: HasCircle a => Lens' a Point
circleDrawAttributes :: HasCircle a => Lens' a DrawAttributes
circleRadius :: HasCircle a => Lens' a Number

-- | Define an `&lt;ellipse&gt;`
data Ellipse
Ellipse :: !DrawAttributes -> !Point -> !Number -> !Number -> Ellipse

-- | Drawing attributes of the ellipse.
[_ellipseDrawAttributes] :: Ellipse -> !DrawAttributes

-- | Center of the ellipse, map to the <tt>cx</tt> and <tt>cy</tt>
--   attributes.
[_ellipseCenter] :: Ellipse -> !Point

-- | Radius along the X axis, map the <tt>rx</tt> attribute.
[_ellipseXRadius] :: Ellipse -> !Number

-- | Radius along the Y axis, map the <tt>ry</tt> attribute.
[_ellipseYRadius] :: Ellipse -> !Number

-- | Lenses for the ellipse type.
class HasEllipse c_amWt
ellipse :: HasEllipse c_amWt => Lens' c_amWt Ellipse
ellipseCenter :: HasEllipse c_amWt => Lens' c_amWt Point
ellipseDrawAttributes :: HasEllipse c_amWt => Lens' c_amWt DrawAttributes
ellipseXRadius :: HasEllipse c_amWt => Lens' c_amWt Number
ellipseYRadius :: HasEllipse c_amWt => Lens' c_amWt Number

-- | Description of path used in meshgradient tag
data GradientPathCommand

-- | Line to, <tt>L</tt> or <tt>l</tt> Svg path command.
GLine :: !Origin -> !Maybe RPoint -> GradientPathCommand

-- | Cubic bezier, <tt>C</tt> or <tt>c</tt> command
GCurve :: !Origin -> !RPoint -> !RPoint -> !Maybe RPoint -> GradientPathCommand

-- | <tt>Z</tt> command
GClose :: GradientPathCommand
data MeshGradientType
GradientBilinear :: MeshGradientType
GradientBicubic :: MeshGradientType

-- | Define a `&lt;meshgradient&gt;` tag.
data MeshGradient
MeshGradient :: !DrawAttributes -> !Number -> !Number -> !MeshGradientType -> !CoordinateUnits -> ![Transformation] -> ![MeshGradientRow] -> MeshGradient
[_meshGradientDrawAttributes] :: MeshGradient -> !DrawAttributes

-- | Original x coordinate of the mesh gradient
[_meshGradientX] :: MeshGradient -> !Number

-- | Original y coordinate of the mesh gradient
[_meshGradientY] :: MeshGradient -> !Number

-- | Type of color interpolation to use
[_meshGradientType] :: MeshGradient -> !MeshGradientType

-- | Coordiante system to use
[_meshGradientUnits] :: MeshGradient -> !CoordinateUnits

-- | Optional transform
[_meshGradientTransform] :: MeshGradient -> ![Transformation]

-- | List of patch rows in the the mesh.
[_meshGradientRows] :: MeshGradient -> ![MeshGradientRow]
class HasMeshGradient c_anxG
meshGradient :: HasMeshGradient c_anxG => Lens' c_anxG MeshGradient
meshGradientDrawAttributes :: HasMeshGradient c_anxG => Lens' c_anxG DrawAttributes
meshGradientRows :: HasMeshGradient c_anxG => Lens' c_anxG [MeshGradientRow]
meshGradientTransform :: HasMeshGradient c_anxG => Lens' c_anxG [Transformation]
meshGradientType :: HasMeshGradient c_anxG => Lens' c_anxG MeshGradientType
meshGradientUnits :: HasMeshGradient c_anxG => Lens' c_anxG CoordinateUnits
meshGradientX :: HasMeshGradient c_anxG => Lens' c_anxG Number
meshGradientY :: HasMeshGradient c_anxG => Lens' c_anxG Number

-- | Define a `&lt;meshrow&gt;` tag.
data MeshGradientRow
MeshGradientRow :: ![MeshGradientPatch] -> MeshGradientRow

-- | List of patch in a row
[_meshGradientRowPatches] :: MeshGradientRow -> ![MeshGradientPatch]
class HasMeshGradientRow c_antr
meshGradientRow :: HasMeshGradientRow c_antr => Lens' c_antr MeshGradientRow
meshGradientRowPatches :: HasMeshGradientRow c_antr => Lens' c_antr [MeshGradientPatch]

-- | Define `&lt;meshpatch&gt;` SVG tag
data MeshGradientPatch
MeshGradientPatch :: ![GradientStop] -> MeshGradientPatch

-- | List of stop, from 2 to 4 in a patch
[_meshGradientPatchStops] :: MeshGradientPatch -> ![GradientStop]
class HasMeshGradientPatch c_annx
meshGradientPatch :: HasMeshGradientPatch c_annx => Lens' c_annx MeshGradientPatch
meshGradientPatchStops :: HasMeshGradientPatch c_annx => Lens' c_annx [GradientStop]

-- | Define an `&lt;image&gt;` tag.
data Image
Image :: !DrawAttributes -> !Point -> !Number -> !Number -> !String -> !PreserveAspectRatio -> Image

-- | Drawing attributes of the image
[_imageDrawAttributes] :: Image -> !DrawAttributes

-- | Position of the image referenced by its upper left corner.
[_imageCornerUpperLeft] :: Image -> !Point

-- | Image width
[_imageWidth] :: Image -> !Number

-- | Image Height
[_imageHeight] :: Image -> !Number

-- | Image href, pointing to the real image.
[_imageHref] :: Image -> !String

-- | preserveAspectRatio attribute
[_imageAspectRatio] :: Image -> !PreserveAspectRatio

-- | Lenses for the Image type.
class HasImage c_anI7
image :: HasImage c_anI7 => Lens' c_anI7 Image
imageAspectRatio :: HasImage c_anI7 => Lens' c_anI7 PreserveAspectRatio
imageCornerUpperLeft :: HasImage c_anI7 => Lens' c_anI7 Point
imageDrawAttributes :: HasImage c_anI7 => Lens' c_anI7 DrawAttributes
imageHeight :: HasImage c_anI7 => Lens' c_anI7 Number
imageHref :: HasImage c_anI7 => Lens' c_anI7 String
imageWidth :: HasImage c_anI7 => Lens' c_anI7 Number

-- | Define an `&lt;use&gt;` for a named content. Every named content can
--   be reused in the document using this element.
data Use
Use :: Point -> String -> Maybe Number -> Maybe Number -> DrawAttributes -> Use

-- | Position where to draw the "used" element. Correspond to the
--   <tt>x</tt> and <tt>y</tt> attributes.
[_useBase] :: Use -> Point

-- | Referenced name, correspond to `xlink:href` attribute.
[_useName] :: Use -> String

-- | Define the width of the region where to place the element. Map to the
--   <a>width</a> attribute.
[_useWidth] :: Use -> Maybe Number

-- | Define the height of the region where to place the element. Map to the
--   <a>height</a> attribute.
[_useHeight] :: Use -> Maybe Number

-- | Use draw attributes.
[_useDrawAttributes] :: Use -> DrawAttributes

-- | Lenses for the Use type.
class HasUse c_anR3
use :: HasUse c_anR3 => Lens' c_anR3 Use
useBase :: HasUse c_anR3 => Lens' c_anR3 Point
useDrawAttributes :: HasUse c_anR3 => Lens' c_anR3 DrawAttributes
useHeight :: HasUse c_anR3 => Lens' c_anR3 (Maybe Number)
useName :: HasUse c_anR3 => Lens' c_anR3 String
useWidth :: HasUse c_anR3 => Lens' c_anR3 (Maybe Number)

-- | Define a SVG group, corresponding `&lt;g&gt;` tag.
data Group a
Group :: !DrawAttributes -> ![a] -> !Maybe (Double, Double, Double, Double) -> !PreserveAspectRatio -> Group a

-- | Group drawing attributes, propagated to all of its children.
[_groupDrawAttributes] :: Group a -> !DrawAttributes

-- | Content of the group, corresponding to all the tags inside the
--   `&lt;g&gt;` tag.
[_groupChildren] :: Group a -> ![a]

-- | Mapped to the attribute <a>viewBox</a>
[_groupViewBox] :: Group a -> !Maybe (Double, Double, Double, Double)

-- | used for symbols only
[_groupAspectRatio] :: Group a -> !PreserveAspectRatio

-- | Lenses associated to the Group type.
class HasGroup g a | g -> a
group :: HasGroup g a => Lens' g (Group a)
groupAspectRatio :: HasGroup g a => Lens' g PreserveAspectRatio
groupChildren :: HasGroup g a => Lens' g [a]
groupDrawAttributes :: HasGroup g a => Lens' g DrawAttributes
groupViewBox :: HasGroup g a => Lens' g (Maybe (Double, Double, Double, Double))

-- | Define the `&lt;symbol&gt;` tag, equivalent to a named group.
newtype Symbol a
Symbol :: Group a -> Symbol a
[_groupOfSymbol] :: Symbol a -> Group a

-- | Lenses associated with the Symbol type.
groupOfSymbol :: Lens (Symbol s) (Symbol t) (Group s) (Group t)

-- | Define the global `&lt;tag&gt;` SVG tag.
data Text
Text :: !TextAdjust -> !TextSpan -> Text

-- | Define the <tt>lengthAdjust</tt> attribute.
[_textAdjust] :: Text -> !TextAdjust

-- | Root of the text content.
[_textRoot] :: Text -> !TextSpan

-- | Lenses for the Text type.
class HasText c_aorD
text :: HasText c_aorD => Lens' c_aorD Text
textAdjust :: HasText c_aorD => Lens' c_aorD TextAdjust
textRoot :: HasText c_aorD => Lens' c_aorD TextSpan

-- | Tell where to anchor the text, where the position given is realative
--   to the text.
data TextAnchor

-- | The text with left aligned, or start at the postion If the point is
--   the <a>*</a> then the text will be printed this way:
--   
--   <pre>
--   *THE_TEXT_TO_PRINT
--   </pre>
--   
--   Equivalent to the <tt>start</tt> value.
TextAnchorStart :: TextAnchor

-- | The text is middle aligned, so the text will be at the left and right
--   of the position:
--   
--   <pre>
--   THE_TEXT*TO_PRINT
--   </pre>
--   
--   Equivalent to the <tt>middle</tt> value.
TextAnchorMiddle :: TextAnchor

-- | The text is right aligned.
--   
--   <pre>
--   THE_TEXT_TO_PRINT*
--   </pre>
--   
--   Equivalent to the <tt>end</tt> value.
TextAnchorEnd :: TextAnchor

-- | Little helper to create a SVG text at a given baseline position.
textAt :: Point -> Text -> Text

-- | Describe the `&lt;textpath&gt;` SVG tag.
data TextPath
TextPath :: !Number -> !String -> !TextPathMethod -> !TextPathSpacing -> ![PathCommand] -> TextPath

-- | Define the beginning offset on the path, the <tt>startOffset</tt>
--   attribute.
[_textPathStartOffset] :: TextPath -> !Number

-- | Define the `xlink:href` attribute.
[_textPathName] :: TextPath -> !String

-- | Correspond to the <tt>method</tt> attribute.
[_textPathMethod] :: TextPath -> !TextPathMethod

-- | Correspond to the <tt>spacing</tt> attribute.
[_textPathSpacing] :: TextPath -> !TextPathSpacing

-- | Real content of the path.
[_textPathData] :: TextPath -> ![PathCommand]

-- | Lenses for the TextPath type.
class HasTextPath c_aojU
textPath :: HasTextPath c_aojU => Lens' c_aojU TextPath
textPathData :: HasTextPath c_aojU => Lens' c_aojU [PathCommand]
textPathMethod :: HasTextPath c_aojU => Lens' c_aojU TextPathMethod
textPathName :: HasTextPath c_aojU => Lens' c_aojU String
textPathSpacing :: HasTextPath c_aojU => Lens' c_aojU TextPathSpacing
textPathStartOffset :: HasTextPath c_aojU => Lens' c_aojU Number

-- | Describe the content of the <tt>spacing</tt> text path attribute.
data TextPathSpacing

-- | Map to the <tt>exact</tt> value.
TextPathSpacingExact :: TextPathSpacing

-- | Map to the <tt>auto</tt> value.
TextPathSpacingAuto :: TextPathSpacing

-- | Describe the content of the <tt>method</tt> attribute on text path.
data TextPathMethod

-- | Map to the <tt>align</tt> value.
TextPathAlign :: TextPathMethod

-- | Map to the <tt>stretch</tt> value.
TextPathStretch :: TextPathMethod

-- | Define the content of a `&lt;tspan&gt;` tag.
data TextSpanContent

-- | Raw text
SpanText :: !Text -> TextSpanContent

-- | Equivalent to a `&lt;tref&gt;`
SpanTextRef :: !String -> TextSpanContent

-- | Define a `&lt;tspan&gt;`
SpanSub :: !TextSpan -> TextSpanContent

-- | Define a `&lt;tspan&gt;` tag.
data TextSpan
TextSpan :: !TextInfo -> !DrawAttributes -> ![TextSpanContent] -> TextSpan

-- | Placing information for the text.
[_spanInfo] :: TextSpan -> !TextInfo

-- | Drawing attributes for the text span.
[_spanDrawAttributes] :: TextSpan -> !DrawAttributes

-- | Content of the span.
[_spanContent] :: TextSpan -> ![TextSpanContent]

-- | Lenses for the TextSpan type.
class HasTextSpan c_aobD
textSpan :: HasTextSpan c_aobD => Lens' c_aobD TextSpan
spanContent :: HasTextSpan c_aobD => Lens' c_aobD [TextSpanContent]
spanDrawAttributes :: HasTextSpan c_aobD => Lens' c_aobD DrawAttributes
spanInfo :: HasTextSpan c_aobD => Lens' c_aobD TextInfo

-- | Define position information associated to `&lt;text&gt;` or
--   `&lt;tspan&gt;` svg tag.
data TextInfo
TextInfo :: ![Number] -> ![Number] -> ![Number] -> ![Number] -> ![Double] -> !Maybe Number -> TextInfo

-- | <tt>x</tt> attribute.
[_textInfoX] :: TextInfo -> ![Number]

-- | <tt>y</tt> attribute.
[_textInfoY] :: TextInfo -> ![Number]

-- | <tt>dx</tt> attribute.
[_textInfoDX] :: TextInfo -> ![Number]

-- | <tt>dy</tt> attribute.
[_textInfoDY] :: TextInfo -> ![Number]

-- | <a>rotate</a> attribute.
[_textInfoRotate] :: TextInfo -> ![Double]

-- | <tt>textLength</tt> attribute.
[_textInfoLength] :: TextInfo -> !Maybe Number

-- | Lenses for the TextInfo type.
class HasTextInfo c_ao0m
textInfo :: HasTextInfo c_ao0m => Lens' c_ao0m TextInfo
textInfoDX :: HasTextInfo c_ao0m => Lens' c_ao0m [Number]
textInfoDY :: HasTextInfo c_ao0m => Lens' c_ao0m [Number]
textInfoLength :: HasTextInfo c_ao0m => Lens' c_ao0m (Maybe Number)
textInfoRotate :: HasTextInfo c_ao0m => Lens' c_ao0m [Double]
textInfoX :: HasTextInfo c_ao0m => Lens' c_ao0m [Number]
textInfoY :: HasTextInfo c_ao0m => Lens' c_ao0m [Number]

-- | Define the possible values of the <tt>lengthAdjust</tt> attribute.
data TextAdjust

-- | Value <tt>spacing</tt>
TextAdjustSpacing :: TextAdjust

-- | Value <tt>spacingAndGlyphs</tt>
TextAdjustSpacingAndGlyphs :: TextAdjust

-- | Define the `&lt;marker&gt;` tag.
data Marker
Marker :: DrawAttributes -> !(Number, Number) -> !Maybe Number -> !Maybe Number -> !Maybe MarkerOrientation -> !Maybe MarkerUnit -> !Maybe (Double, Double, Double, Double) -> !Maybe Overflow -> !PreserveAspectRatio -> [Tree] -> Marker

-- | Draw attributes of the marker.
[_markerDrawAttributes] :: Marker -> DrawAttributes

-- | Define the reference point of the marker. correspond to the
--   <tt>refX</tt> and <tt>refY</tt> attributes.
[_markerRefPoint] :: Marker -> !(Number, Number)

-- | Define the width of the marker. Correspond to the <a>markerWidth</a>
--   attribute.
[_markerWidth] :: Marker -> !Maybe Number

-- | Define the height of the marker. Correspond to the <a>markerHeight</a>
--   attribute.
[_markerHeight] :: Marker -> !Maybe Number

-- | Correspond to the <tt>orient</tt> attribute.
[_markerOrient] :: Marker -> !Maybe MarkerOrientation

-- | Map the <a>markerUnits</a> attribute.
[_markerUnits] :: Marker -> !Maybe MarkerUnit

-- | Optional viewbox
[_markerViewBox] :: Marker -> !Maybe (Double, Double, Double, Double)

-- | Elements defining the marker.
[_markerOverflow] :: Marker -> !Maybe Overflow

-- | preserveAspectRatio attribute
[_markerAspectRatio] :: Marker -> !PreserveAspectRatio

-- | Elements defining the marker.
[_markerElements] :: Marker -> [Tree]

-- | Define the content of the <a>markerUnits</a> attribute on the Marker.
data Overflow

-- | Value <tt>visible</tt>
OverflowVisible :: Overflow

-- | Value <tt>hidden</tt>
OverflowHidden :: Overflow

-- | Define the orientation, associated to the <tt>orient</tt> attribute on
--   the Marker
data MarkerOrientation

-- | Auto value
OrientationAuto :: MarkerOrientation

-- | Specific angle.
OrientationAngle :: Coord -> MarkerOrientation

-- | Define the content of the <a>markerUnits</a> attribute on the Marker.
data MarkerUnit

-- | Value <a>strokeWidth</a>
MarkerUnitStrokeWidth :: MarkerUnit

-- | Value <tt>userSpaceOnUse</tt>
MarkerUnitUserSpaceOnUse :: MarkerUnit

-- | Lenses for the Marker type.
class HasMarker c_aoKc
marker :: HasMarker c_aoKc => Lens' c_aoKc Marker
markerAspectRatio :: HasMarker c_aoKc => Lens' c_aoKc PreserveAspectRatio
markerDrawAttributes :: HasMarker c_aoKc => Lens' c_aoKc DrawAttributes
markerElements :: HasMarker c_aoKc => Lens' c_aoKc [Tree]
markerHeight :: HasMarker c_aoKc => Lens' c_aoKc (Maybe Number)
markerOrient :: HasMarker c_aoKc => Lens' c_aoKc (Maybe MarkerOrientation)
markerOverflow :: HasMarker c_aoKc => Lens' c_aoKc (Maybe Overflow)
markerRefPoint :: HasMarker c_aoKc => Lens' c_aoKc (Number, Number)
markerUnits :: HasMarker c_aoKc => Lens' c_aoKc (Maybe MarkerUnit)
markerViewBox :: HasMarker c_aoKc => Lens' c_aoKc (Maybe (Double, Double, Double, Double))
markerWidth :: HasMarker c_aoKc => Lens' c_aoKc (Maybe Number)

-- | Define a color stop for the gradients. Represent the `&lt;stop&gt;`
--   SVG tag.
data GradientStop
GradientStop :: !Float -> !PixelRGBA8 -> !Maybe GradientPathCommand -> !Maybe Float -> GradientStop

-- | Gradient offset between 0 and 1, correspond to the <tt>offset</tt>
--   attribute.
[_gradientOffset] :: GradientStop -> !Float

-- | Color of the gradient stop. Correspond to the `stop-color` attribute.
[_gradientColor] :: GradientStop -> !PixelRGBA8

-- | Path command used in mesh patch
[_gradientPath] :: GradientStop -> !Maybe GradientPathCommand

-- | Stop color opacity
[_gradientOpacity] :: GradientStop -> !Maybe Float

-- | Lenses for the GradientStop type.
class HasGradientStop c_anhM
gradientStop :: HasGradientStop c_anhM => Lens' c_anhM GradientStop
gradientColor :: HasGradientStop c_anhM => Lens' c_anhM PixelRGBA8
gradientOffset :: HasGradientStop c_anhM => Lens' c_anhM Float
gradientOpacity :: HasGradientStop c_anhM => Lens' c_anhM (Maybe Float)
gradientPath :: HasGradientStop c_anhM => Lens' c_anhM (Maybe GradientPathCommand)

-- | Define a `&lt;linearGradient&gt;` tag.
data LinearGradient
LinearGradient :: CoordinateUnits -> Point -> Point -> Spread -> [Transformation] -> [GradientStop] -> LinearGradient

-- | Define coordinate system of the gradient, associated to the
--   <tt>gradientUnits</tt> attribute.
[_linearGradientUnits] :: LinearGradient -> CoordinateUnits

-- | Point defining the beginning of the line gradient. Associated to the
--   <tt>x1</tt> and <tt>y1</tt> attribute.
[_linearGradientStart] :: LinearGradient -> Point

-- | Point defining the end of the line gradient. Associated to the
--   <tt>x2</tt> and <tt>y2</tt> attribute.
[_linearGradientStop] :: LinearGradient -> Point

-- | Define how to handle the values outside the gradient start and stop.
--   Associated to the <tt>spreadMethod</tt> attribute.
[_linearGradientSpread] :: LinearGradient -> Spread

-- | Define the transformation to apply to the gradient points. Associated
--   to the <tt>gradientTransform</tt> attribute.
[_linearGradientTransform] :: LinearGradient -> [Transformation]

-- | List of color stops of the linear gradient.
[_linearGradientStops] :: LinearGradient -> [GradientStop]

-- | Lenses for the LinearGradient type.
class HasLinearGradient c_apmJ
linearGradient :: HasLinearGradient c_apmJ => Lens' c_apmJ LinearGradient
linearGradientSpread :: HasLinearGradient c_apmJ => Lens' c_apmJ Spread
linearGradientStart :: HasLinearGradient c_apmJ => Lens' c_apmJ Point
linearGradientStop :: HasLinearGradient c_apmJ => Lens' c_apmJ Point
linearGradientStops :: HasLinearGradient c_apmJ => Lens' c_apmJ [GradientStop]
linearGradientTransform :: HasLinearGradient c_apmJ => Lens' c_apmJ [Transformation]
linearGradientUnits :: HasLinearGradient c_apmJ => Lens' c_apmJ CoordinateUnits

-- | Define a `&lt;radialGradient&gt;` tag.
data RadialGradient
RadialGradient :: CoordinateUnits -> Point -> Number -> Maybe Number -> Maybe Number -> Spread -> [Transformation] -> [GradientStop] -> RadialGradient

-- | Define coordinate system of the gradient, associated to the
--   <tt>gradientUnits</tt> attribute.
[_radialGradientUnits] :: RadialGradient -> CoordinateUnits

-- | Center of the radial gradient. Associated to the <tt>cx</tt> and
--   <tt>cy</tt> attributes.
[_radialGradientCenter] :: RadialGradient -> Point

-- | Radius of the radial gradient. Associated to the <tt>r</tt> attribute.
[_radialGradientRadius] :: RadialGradient -> Number

-- | X coordinate of the focus point of the radial gradient. Associated to
--   the <tt>fx</tt> attribute.
[_radialGradientFocusX] :: RadialGradient -> Maybe Number

-- | Y coordinate of the focus point of the radial gradient. Associated to
--   the <tt>fy</tt> attribute.
[_radialGradientFocusY] :: RadialGradient -> Maybe Number

-- | Define how to handle the values outside the gradient start and stop.
--   Associated to the <tt>spreadMethod</tt> attribute.
[_radialGradientSpread] :: RadialGradient -> Spread

-- | Define the transformation to apply to the gradient points. Associated
--   to the <tt>gradientTransform</tt> attribute.
[_radialGradientTransform] :: RadialGradient -> [Transformation]

-- | List of color stops of the radial gradient.
[_radialGradientStops] :: RadialGradient -> [GradientStop]

-- | Lenses for the RadialGradient type.
class HasRadialGradient c_apwt
radialGradient :: HasRadialGradient c_apwt => Lens' c_apwt RadialGradient
radialGradientCenter :: HasRadialGradient c_apwt => Lens' c_apwt Point
radialGradientFocusX :: HasRadialGradient c_apwt => Lens' c_apwt (Maybe Number)
radialGradientFocusY :: HasRadialGradient c_apwt => Lens' c_apwt (Maybe Number)
radialGradientRadius :: HasRadialGradient c_apwt => Lens' c_apwt Number
radialGradientSpread :: HasRadialGradient c_apwt => Lens' c_apwt Spread
radialGradientStops :: HasRadialGradient c_apwt => Lens' c_apwt [GradientStop]
radialGradientTransform :: HasRadialGradient c_apwt => Lens' c_apwt [Transformation]
radialGradientUnits :: HasRadialGradient c_apwt => Lens' c_apwt CoordinateUnits

-- | Define a `&lt;pattern&gt;` tag.
data Pattern
Pattern :: !DrawAttributes -> !Maybe (Double, Double, Double, Double) -> !Number -> !Number -> !Point -> !String -> ![Tree] -> !CoordinateUnits -> !PreserveAspectRatio -> !Maybe [Transformation] -> Pattern

-- | Pattern drawing attributes.
[_patternDrawAttributes] :: Pattern -> !DrawAttributes

-- | Possible <a>viewBox</a>.
[_patternViewBox] :: Pattern -> !Maybe (Double, Double, Double, Double)

-- | Width of the pattern tile, mapped to the <a>width</a> attribute
[_patternWidth] :: Pattern -> !Number

-- | Height of the pattern tile, mapped to the <a>height</a> attribute
[_patternHeight] :: Pattern -> !Number

-- | Pattern tile base, mapped to the <tt>x</tt> and <tt>y</tt> attributes.
[_patternPos] :: Pattern -> !Point

-- | Patterns can be chained, so this is a potential reference to another
--   pattern
[_patternHref] :: Pattern -> !String

-- | Elements used in the pattern.
[_patternElements] :: Pattern -> ![Tree]

-- | Define the cordinate system to use for the pattern. Mapped to the
--   <tt>patternUnits</tt> attribute.
[_patternUnit] :: Pattern -> !CoordinateUnits

-- | Value of the "preserveAspectRatio" attribute
[_patternAspectRatio] :: Pattern -> !PreserveAspectRatio

-- | Value of "patternTransform" attribute
[_patternTransform] :: Pattern -> !Maybe [Transformation]

-- | Lenses for the Patter type.
class HasPattern c_aq6G
pattern :: HasPattern c_aq6G => Lens' c_aq6G Pattern
patternAspectRatio :: HasPattern c_aq6G => Lens' c_aq6G PreserveAspectRatio
patternDrawAttributes :: HasPattern c_aq6G => Lens' c_aq6G DrawAttributes
patternElements :: HasPattern c_aq6G => Lens' c_aq6G [Tree]
patternHeight :: HasPattern c_aq6G => Lens' c_aq6G Number
patternHref :: HasPattern c_aq6G => Lens' c_aq6G String
patternPos :: HasPattern c_aq6G => Lens' c_aq6G Point
patternTransform :: HasPattern c_aq6G => Lens' c_aq6G (Maybe [Transformation])
patternUnit :: HasPattern c_aq6G => Lens' c_aq6G CoordinateUnits
patternViewBox :: HasPattern c_aq6G => Lens' c_aq6G (Maybe (Double, Double, Double, Double))
patternWidth :: HasPattern c_aq6G => Lens' c_aq6G Number

-- | Define a SVG `&lt;mask&gt;` tag.
data Mask
Mask :: DrawAttributes -> CoordinateUnits -> CoordinateUnits -> Point -> Number -> Number -> [Tree] -> Mask

-- | Drawing attributes of the Mask
[_maskDrawAttributes] :: Mask -> DrawAttributes

-- | Correspond to the <a>maskContentUnits</a> attributes.
[_maskContentUnits] :: Mask -> CoordinateUnits

-- | Mapping to the <a>maskUnits</a> attribute.
[_maskUnits] :: Mask -> CoordinateUnits

-- | Map to the <tt>x</tt> and <tt>y</tt> attributes.
[_maskPosition] :: Mask -> Point

-- | Map to the <a>width</a> attribute
[_maskWidth] :: Mask -> Number

-- | Map to the <a>height</a> attribute.
[_maskHeight] :: Mask -> Number

-- | Children of the `&lt;mask&gt;` tag.
[_maskContent] :: Mask -> [Tree]

-- | Lenses for the Mask type.
class HasMask c_apHI
mask :: HasMask c_apHI => Lens' c_apHI Mask
maskContent :: HasMask c_apHI => Lens' c_apHI [Tree]
maskContentUnits :: HasMask c_apHI => Lens' c_apHI CoordinateUnits
maskDrawAttributes :: HasMask c_apHI => Lens' c_apHI DrawAttributes
maskHeight :: HasMask c_apHI => Lens' c_apHI Number
maskPosition :: HasMask c_apHI => Lens' c_apHI Point
maskUnits :: HasMask c_apHI => Lens' c_apHI CoordinateUnits
maskWidth :: HasMask c_apHI => Lens' c_apHI Number

-- | Define a `&lt;clipPath&gt;` tag.
data ClipPath
ClipPath :: DrawAttributes -> CoordinateUnits -> [Tree] -> ClipPath
[_clipPathDrawAttributes] :: ClipPath -> DrawAttributes

-- | Maps to the <a>clipPathUnits</a> attribute
[_clipPathUnits] :: ClipPath -> CoordinateUnits

-- | Maps to the content of the tree
[_clipPathContent] :: ClipPath -> [Tree]

-- | Lenses for the ClipPath type.
class HasClipPath c_apZq
clipPath :: HasClipPath c_apZq => Lens' c_apZq ClipPath
clipPathContent :: HasClipPath c_apZq => Lens' c_apZq [Tree]
clipPathDrawAttributes :: HasClipPath c_apZq => Lens' c_apZq DrawAttributes
clipPathUnits :: HasClipPath c_apZq => Lens' c_apZq CoordinateUnits

-- | Describe the content of the preserveAspectRatio attribute.
data PreserveAspectRatio
PreserveAspectRatio :: !Bool -> !Alignment -> !Maybe MeetSlice -> PreserveAspectRatio
[_aspectRatioDefer] :: PreserveAspectRatio -> !Bool
[_aspectRatioAlign] :: PreserveAspectRatio -> !Alignment
[_aspectRatioMeetSlice] :: PreserveAspectRatio -> !Maybe MeetSlice

-- | This type represent the align information of the preserveAspectRatio
--   SVGattribute
data Alignment

-- | "none" value
AlignNone :: Alignment
AlignxMinYMin :: Alignment

-- | "xMidYMin" value
AlignxMidYMin :: Alignment

-- | "xMaxYMin" value
AlignxMaxYMin :: Alignment

-- | "xMinYMid" value
AlignxMinYMid :: Alignment

-- | "xMidYMid" value
AlignxMidYMid :: Alignment

-- | "xMaxYMid" value
AlignxMaxYMid :: Alignment

-- | "xMinYMax" value
AlignxMinYMax :: Alignment

-- | "xMidYMax" value
AlignxMidYMax :: Alignment

-- | "xMaxYMax" value
AlignxMaxYMax :: Alignment

-- | This type represent the "meet or slice" information of the
--   preserveAspectRatio SVGattribute
data MeetSlice
Meet :: MeetSlice
Slice :: MeetSlice

-- | Lenses for the PreserveAspectRatio type
class HasPreserveAspectRatio a
preserveAspectRatio :: HasPreserveAspectRatio a => Lens' a PreserveAspectRatio
aspectRatioAlign :: HasPreserveAspectRatio a => Lens' a Alignment
aspectRatioDefer :: HasPreserveAspectRatio a => Lens' a Bool
aspectRatioMeetSlice :: HasPreserveAspectRatio a => Lens' a (Maybe MeetSlice)

-- | Tell if the path command is an EllipticalArc.
isPathArc :: PathCommand -> Bool

-- | Tell if a full path contain an EllipticalArc.
isPathWithArc :: Foldable f => f PathCommand -> Bool

-- | For every element of a svg tree, associate it's SVG tag name.
nameOfTree :: Tree -> Text

-- | Map a tree while propagating context information. The function passed
--   in parameter receive a list representing the the path used to go
--   arrive to the current node.
zipTree :: ([[Tree]] -> Tree) -> Tree -> Tree

-- | Helper function mapping every tree element.
mapTree :: (Tree -> Tree) -> Tree -> Tree

-- | Fold all nodes of a SVG tree.
foldTree :: (a -> Tree -> a) -> a -> Tree -> a

-- | This function replace all device dependant units to user units given
--   it's DPI configuration. Preserve percentage and "em" notation.
toUserUnit :: Dpi -> Number -> Number

-- | Helper function to modify inner value of a number
mapNumber :: (Double -> Double) -> Number -> Number
instance GHC.Show.Show Graphics.Svg.Types.Document
instance GHC.Show.Show Graphics.Svg.Types.Element
instance GHC.Show.Show Graphics.Svg.Types.Pattern
instance GHC.Show.Show Graphics.Svg.Types.ClipPath
instance GHC.Classes.Eq Graphics.Svg.Types.ClipPath
instance GHC.Show.Show Graphics.Svg.Types.Mask
instance GHC.Classes.Eq Graphics.Svg.Types.Mask
instance GHC.Show.Show Graphics.Svg.Types.RadialGradient
instance GHC.Classes.Eq Graphics.Svg.Types.RadialGradient
instance GHC.Show.Show Graphics.Svg.Types.LinearGradient
instance GHC.Classes.Eq Graphics.Svg.Types.LinearGradient
instance GHC.Show.Show Graphics.Svg.Types.Spread
instance GHC.Classes.Eq Graphics.Svg.Types.Spread
instance GHC.Show.Show Graphics.Svg.Types.Marker
instance GHC.Classes.Eq Graphics.Svg.Types.Marker
instance GHC.Show.Show Graphics.Svg.Types.Overflow
instance GHC.Classes.Eq Graphics.Svg.Types.Overflow
instance GHC.Show.Show Graphics.Svg.Types.MarkerUnit
instance GHC.Classes.Eq Graphics.Svg.Types.MarkerUnit
instance GHC.Show.Show Graphics.Svg.Types.MarkerOrientation
instance GHC.Classes.Eq Graphics.Svg.Types.MarkerOrientation
instance GHC.Show.Show Graphics.Svg.Types.Tree
instance GHC.Classes.Eq Graphics.Svg.Types.Tree
instance GHC.Show.Show Graphics.Svg.Types.Text
instance GHC.Classes.Eq Graphics.Svg.Types.Text
instance GHC.Show.Show Graphics.Svg.Types.TextAdjust
instance GHC.Classes.Eq Graphics.Svg.Types.TextAdjust
instance GHC.Show.Show Graphics.Svg.Types.TextPath
instance GHC.Classes.Eq Graphics.Svg.Types.TextPath
instance GHC.Show.Show Graphics.Svg.Types.TextPathSpacing
instance GHC.Classes.Eq Graphics.Svg.Types.TextPathSpacing
instance GHC.Show.Show Graphics.Svg.Types.TextPathMethod
instance GHC.Classes.Eq Graphics.Svg.Types.TextPathMethod
instance GHC.Show.Show Graphics.Svg.Types.TextSpanContent
instance GHC.Classes.Eq Graphics.Svg.Types.TextSpanContent
instance GHC.Show.Show Graphics.Svg.Types.TextSpan
instance GHC.Classes.Eq Graphics.Svg.Types.TextSpan
instance GHC.Show.Show Graphics.Svg.Types.TextInfo
instance GHC.Classes.Eq Graphics.Svg.Types.TextInfo
instance GHC.Show.Show Graphics.Svg.Types.Use
instance GHC.Classes.Eq Graphics.Svg.Types.Use
instance GHC.Show.Show Graphics.Svg.Types.Image
instance GHC.Classes.Eq Graphics.Svg.Types.Image
instance GHC.Show.Show Graphics.Svg.Types.MeshGradient
instance GHC.Classes.Eq Graphics.Svg.Types.MeshGradient
instance GHC.Show.Show Graphics.Svg.Types.MeshGradientRow
instance GHC.Classes.Eq Graphics.Svg.Types.MeshGradientRow
instance GHC.Show.Show Graphics.Svg.Types.MeshGradientPatch
instance GHC.Classes.Eq Graphics.Svg.Types.MeshGradientPatch
instance GHC.Show.Show Graphics.Svg.Types.GradientStop
instance GHC.Classes.Eq Graphics.Svg.Types.GradientStop
instance GHC.Show.Show Graphics.Svg.Types.Ellipse
instance GHC.Classes.Eq Graphics.Svg.Types.Ellipse
instance GHC.Show.Show Graphics.Svg.Types.Circle
instance GHC.Classes.Eq Graphics.Svg.Types.Circle
instance GHC.Show.Show a => GHC.Show.Show (Graphics.Svg.Types.Symbol a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (Graphics.Svg.Types.Symbol a)
instance GHC.Show.Show a => GHC.Show.Show (Graphics.Svg.Types.Group a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (Graphics.Svg.Types.Group a)
instance GHC.Show.Show Graphics.Svg.Types.Path
instance GHC.Classes.Eq Graphics.Svg.Types.Path
instance GHC.Show.Show Graphics.Svg.Types.Rectangle
instance GHC.Classes.Eq Graphics.Svg.Types.Rectangle
instance GHC.Show.Show Graphics.Svg.Types.Line
instance GHC.Classes.Eq Graphics.Svg.Types.Line
instance GHC.Show.Show Graphics.Svg.Types.Polygon
instance GHC.Classes.Eq Graphics.Svg.Types.Polygon
instance GHC.Show.Show Graphics.Svg.Types.PolyLine
instance GHC.Classes.Eq Graphics.Svg.Types.PolyLine
instance GHC.Show.Show Graphics.Svg.Types.DrawAttributes
instance GHC.Classes.Eq Graphics.Svg.Types.DrawAttributes
instance GHC.Show.Show Graphics.Svg.Types.ElementRef
instance GHC.Classes.Eq Graphics.Svg.Types.ElementRef
instance GHC.Show.Show Graphics.Svg.Types.TextAnchor
instance GHC.Classes.Eq Graphics.Svg.Types.TextAnchor
instance GHC.Show.Show Graphics.Svg.Types.FontStyle
instance GHC.Classes.Eq Graphics.Svg.Types.FontStyle
instance GHC.Show.Show Graphics.Svg.Types.Transformation
instance GHC.Classes.Eq Graphics.Svg.Types.Transformation
instance GHC.Show.Show Graphics.Svg.Types.FillRule
instance GHC.Classes.Eq Graphics.Svg.Types.FillRule
instance GHC.Show.Show Graphics.Svg.Types.Texture
instance GHC.Classes.Eq Graphics.Svg.Types.Texture
instance GHC.Show.Show Graphics.Svg.Types.LineJoin
instance GHC.Classes.Eq Graphics.Svg.Types.LineJoin
instance GHC.Show.Show Graphics.Svg.Types.Cap
instance GHC.Classes.Eq Graphics.Svg.Types.Cap
instance GHC.Show.Show Graphics.Svg.Types.PreserveAspectRatio
instance GHC.Classes.Eq Graphics.Svg.Types.PreserveAspectRatio
instance GHC.Show.Show Graphics.Svg.Types.MeetSlice
instance GHC.Classes.Eq Graphics.Svg.Types.MeetSlice
instance GHC.Show.Show Graphics.Svg.Types.Alignment
instance GHC.Classes.Eq Graphics.Svg.Types.Alignment
instance GHC.Show.Show Graphics.Svg.Types.CoordinateUnits
instance GHC.Classes.Eq Graphics.Svg.Types.CoordinateUnits
instance GHC.Show.Show Graphics.Svg.Types.GradientPathCommand
instance GHC.Classes.Eq Graphics.Svg.Types.GradientPathCommand
instance GHC.Show.Show Graphics.Svg.Types.PathCommand
instance GHC.Classes.Eq Graphics.Svg.Types.PathCommand
instance GHC.Show.Show Graphics.Svg.Types.MeshGradientType
instance GHC.Classes.Eq Graphics.Svg.Types.MeshGradientType
instance GHC.Show.Show Graphics.Svg.Types.Origin
instance GHC.Classes.Eq Graphics.Svg.Types.Origin
instance Graphics.Svg.CssTypes.CssMatcheable Graphics.Svg.Types.Tree
instance Graphics.Svg.Types.HasDrawAttributes Graphics.Svg.Types.DrawAttributes
instance Graphics.Svg.Types.HasPreserveAspectRatio Graphics.Svg.Types.PreserveAspectRatio
instance Graphics.Svg.Types.HasDocument Graphics.Svg.Types.Document
instance Graphics.Svg.Types.HasPattern Graphics.Svg.Types.Pattern
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Pattern
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Pattern
instance Graphics.Svg.Types.HasClipPath Graphics.Svg.Types.ClipPath
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.ClipPath
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.ClipPath
instance Graphics.Svg.Types.HasMask Graphics.Svg.Types.Mask
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Mask
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Mask
instance Graphics.Svg.Types.HasRadialGradient Graphics.Svg.Types.RadialGradient
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.RadialGradient
instance Graphics.Svg.Types.HasLinearGradient Graphics.Svg.Types.LinearGradient
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.LinearGradient
instance Graphics.Svg.Types.HasMarker Graphics.Svg.Types.Marker
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Marker
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Marker
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Tree
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Tree
instance Graphics.Svg.Types.HasText Graphics.Svg.Types.Text
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Text
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Text
instance Graphics.Svg.Types.HasTextPath Graphics.Svg.Types.TextPath
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.TextPath
instance Graphics.Svg.Types.HasTextSpan Graphics.Svg.Types.TextSpan
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.TextSpan
instance Graphics.Svg.Types.HasTextInfo Graphics.Svg.Types.TextInfo
instance GHC.Base.Semigroup Graphics.Svg.Types.TextInfo
instance GHC.Base.Monoid Graphics.Svg.Types.TextInfo
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.TextInfo
instance Graphics.Svg.Types.HasUse Graphics.Svg.Types.Use
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Use
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Use
instance Graphics.Svg.Types.HasImage Graphics.Svg.Types.Image
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Image
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Image
instance Graphics.Svg.Types.HasMeshGradient Graphics.Svg.Types.MeshGradient
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.MeshGradient
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.MeshGradient
instance Graphics.Svg.Types.HasMeshGradientRow Graphics.Svg.Types.MeshGradientRow
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.MeshGradientRow
instance Graphics.Svg.Types.HasMeshGradientPatch Graphics.Svg.Types.MeshGradientPatch
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.MeshGradientPatch
instance Graphics.Svg.Types.HasGradientStop Graphics.Svg.Types.GradientStop
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.GradientStop
instance Graphics.Svg.Types.HasEllipse Graphics.Svg.Types.Ellipse
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Ellipse
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Ellipse
instance Graphics.Svg.Types.HasCircle Graphics.Svg.Types.Circle
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Circle
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Circle
instance Graphics.Svg.Types.WithDrawAttributes (Graphics.Svg.Types.Symbol a)
instance Graphics.Svg.Types.WithDefaultSvg (Graphics.Svg.Types.Symbol a)
instance Graphics.Svg.Types.HasGroup (Graphics.Svg.Types.Group a) a
instance Graphics.Svg.Types.WithDrawAttributes (Graphics.Svg.Types.Group a)
instance Graphics.Svg.Types.WithDefaultSvg (Graphics.Svg.Types.Group a)
instance Graphics.Svg.Types.HasPath Graphics.Svg.Types.Path
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Path
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Path
instance Graphics.Svg.Types.HasRectangle Graphics.Svg.Types.Rectangle
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Rectangle
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Rectangle
instance Graphics.Svg.Types.HasLine Graphics.Svg.Types.Line
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Line
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Line
instance Graphics.Svg.Types.HasPolygon Graphics.Svg.Types.Polygon
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.Polygon
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.Polygon
instance Graphics.Svg.Types.HasPolyLine Graphics.Svg.Types.PolyLine
instance Graphics.Svg.Types.WithDrawAttributes Graphics.Svg.Types.PolyLine
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.PolyLine
instance GHC.Base.Semigroup Graphics.Svg.Types.DrawAttributes
instance GHC.Base.Monoid Graphics.Svg.Types.DrawAttributes
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.DrawAttributes
instance Graphics.Svg.Types.WithDefaultSvg Graphics.Svg.Types.PreserveAspectRatio

module Graphics.Svg.PathParser
transformParser :: Parser Transformation
command :: Parser PathCommand
pathParser :: Parser [PathCommand]
viewBoxParser :: Parser (Double, Double, Double, Double)
pointData :: Parser [RPoint]
gradientCommand :: Parser GradientPathCommand
serializePoints :: [RPoint] -> String
serializeCommand :: PathCommand -> String
serializeGradientCommand :: GradientPathCommand -> String
serializeCommands :: [PathCommand] -> String
serializeViewBox :: (Double, Double, Double, Double) -> String


-- | Module providing basic input/output for the SVG document, for document
--   building, please refer to Graphics.Svg.Types.
module Graphics.Svg

-- | Try to load an svg file on disc and parse it as a SVG Document.
loadSvgFile :: FilePath -> IO (Maybe Document)

-- | Parse an in-memory SVG file
parseSvgFile :: FilePath -> ByteString -> Maybe Document

-- | Transform a SVG document to a XML node.
xmlOfDocument :: Document -> Element

-- | Save a svg Document on a file on disk.
saveXmlFile :: FilePath -> Document -> IO ()

-- | Rewrite a SVG Tree using some CSS rules.
--   
--   This action will propagate the definition of the css directly in each
--   matched element.
cssApply :: [CssRule] -> Tree -> Tree

-- | Parse CSS text into rules.
cssRulesOfText :: Text -> [CssRule]

-- | Rewrite the document by applying the CSS rules embedded inside it.
applyCSSRules :: Document -> Document

-- | For every <a>HasUse</a> tag, try to resolve the geometry associated
--   with it and place it in the scene Tree. It is important to resolve the
--   <a>HasUse</a> tag before applying the CSS rules, as some rules may
--   apply some elements matching the children of "use".
resolveUses :: Document -> Document
