-
Notifications
You must be signed in to change notification settings - Fork 8
Image
Christopher Nikkel edited this page Dec 22, 2018
·
7 revisions
type Image =
{
UpperLeft: Point
Size: Area
Source: string
}
Image
is used to create a SVG image.
Function | Signature | Description |
---|---|---|
Image.create |
Point -> Area -> string -> Image |
create an image at a Point for the upper left corner with a Area and a string for the source |
Image.toString |
Image -> string |
convert an image to a string |
let upperLeft = Point.ofInts (55, 45)
let area = Area.ofInts (100, 50)
Image.create upperLeft area "image.png"
|> Element.create
|> printf "%O"
<image x="55" y="45" height="50" width="100" xlink:href="image.png"/>