\src\Utils\Graphics2D\DrawingPanes\HtmlMapDrawingPane.inc
\Utils\Graphics2D\DrawingPanes\HtmlMapDrawingPane
This class implements a drawing pane for HTML map output.
- Parent(s)
- \Utils\Graphics2D\DrawingPanes\DomDrawingPane < \Utils\Graphics2D\DrawingPanes\DrawingPane
Properties


string
$classNameEdge= ''rt_edge''
the name of the CSS class for the edge shapes.
Inherited from: \Utils\Graphics2D\DrawingPanes\DomDrawingPane::$classNameEdge'rt_edge'
Details- Type
- string
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DomDrawingPane::$classNameEdge


string
$classNameNode= ''rt_node''
the name of the CSS class for the node shapes.
Inherited from: \Utils\Graphics2D\DrawingPanes\DomDrawingPane::$classNameNode'rt_node'
Details- Type
- string
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DomDrawingPane::$classNameNode


\Utils\Geom\Dimension
$dimension= '0'
the dimension of the document
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::$dimension0
Details- Type
- \Utils\Geom\Dimension
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DrawingPane::$dimension


mixed
$document= 'null'
null
Details- Type
- mixed
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DrawingPane::$document


\Utils\Color\Color
$fillColor= 'null'
the current fill color of the drawing pane
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::$fillColornull
Details- Type
- \Utils\Color\Color
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DrawingPane::$fillColor


\Utils\Color\Color
$fontColor= 'null'
the current font color of the drawing pane
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::$fontColornull
Details- Type
- \Utils\Color\Color
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DrawingPane::$fontColor


string
$fontFamily= 'null'
the current font family of the drawing pane
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::$fontFamilynull
Details- Type
- string
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DrawingPane::$fontFamily


int
$fontSize= 'null'
the current font size in pixels of the drawing pane
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::$fontSizenull
Details- Type
- int
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DrawingPane::$fontSize


\Utils\Graphics2D\DrawingPanes\DOMDocumentFragment
$fragment= 'null'
the DOM document fragment that holds the source code of the export
Inherited from: \Utils\Graphics2D\DrawingPanes\DomDrawingPane::$fragmentnull
Details- Type
- \Utils\Graphics2D\DrawingPanes\DOMDocumentFragment
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DomDrawingPane::$fragment


\Utils\Color\Color
$strokeColor= 'null'
the current stroke color of the drawing pane
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::$strokeColornull
Details- Type
- \Utils\Color\Color
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DrawingPane::$strokeColor


int
$strokeWidth= '1'
the currect stroke width of the drawing pane
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::$strokeWidth1
Details- Type
- int
- Inherited_from
- \Utils\Graphics2D\DrawingPanes\DrawingPane::$strokeWidth
Methods


__construct(
\Utils\Geom\Dimension $dimension
)
:
void
This method acts as the constructor for the class.
Name | Type | Description |
---|---|---|
$dimension | \Utils\Geom\Dimension | the dimension of the document |


appendFragment(
\DOMNode $parentElement
)
:
void
This method appends the fragment to the given parent element.
Inherited from: \Utils\Graphics2D\DrawingPanes\DomDrawingPane::appendFragment()Name | Type | Description |
---|---|---|
$parentElement | \DOMNode | the root element to append the internal document fragment to |


clearDocument(
)
:
void
This method assures that the document is empty before saving it. Otherwise, multiple calls to violate the DOMDocument structure (e.g. multiple
Inherited from: \Utils\Graphics2D\DrawingPanes\DomDrawingPane::clearDocument()

drawEllipse(
\Utils\Geom\Point $center, \Utils\Geom\Dimension $dimension
)
:
\Utils\Graphics2D\DrawingPanes\IDrawingPane
This method draws an ellipse on the document.
Name | Type | Description |
---|---|---|
$center | \Utils\Geom\Point | the center of the ellipse |
$dimension | \Utils\Geom\Dimension | the dimension of the ellipse |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\IDrawingPane | $this |


drawLine(
\Utils\Geom\Point $source, \Utils\Geom\Point $target
)
:
\Utils\Graphics2D\DrawingPanes\IDrawingPane
This method draws a line on the document.
Name | Type | Description |
---|---|---|
$source | \Utils\Geom\Point | the source point of the line |
$target | \Utils\Geom\Point | the target point of the line |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\IDrawingPane | $this |


drawPolyLine(
\Traversable $points
)
:
\Utils\Graphics2D\DrawingPanes\IDrawingPane
This method draws a poly line onto the the document.
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::drawPolyLine()It expects an traversable of points, where each point is represented by a object of the class Point.
Name | Type | Description |
---|---|---|
$points | \Traversable | the coordinates of the points of the line |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\IDrawingPane | $this |


drawPolygon(
\Traversable $points
)
:
\Utils\Graphics2D\DrawingPanes\IDrawingPane
This method draws a polygon on the document.
Name | Type | Description |
---|---|---|
$points | \Traversable | the points defining the polygon |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\IDrawingPane | $this |


drawRectangle(
\Utils\Geom\Point $topLeftCorner, \Utils\Geom\Dimension $dimension
)
:
\Utils\Graphics2D\DrawingPanes\IDrawingPane
This method draws a rectangle on the document.
Name | Type | Description |
---|---|---|
$topLeftCorner | \Utils\Geom\Point | the top left corner of the rectangle |
$dimension | \Utils\Geom\Dimension | the dimension of the rectangle |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\IDrawingPane | $this |


drawText(
\Utils\Geom\Point $topLeftCorner, \Utils\Graphics2D\DrawingPanes\type $text
)
:
\Utils\Graphics2D\DrawingPanes\IDrawingPane
This method draws text at the given position.
Name | Type | Description |
---|---|---|
$topLeftCorner | \Utils\Geom\Point | the top left corner of the text to draw |
$text | \Utils\Graphics2D\DrawingPanes\type | the text to draw |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\IDrawingPane | $this |
- InheritDoc
- This method does not do anything, as drawing text on a HTML map does not make sense.


getClassNameEdge(
)
:
string
This method acts as getter for the CSS class name of the edge shapes.
Inherited from: \Utils\Graphics2D\DrawingPanes\DomDrawingPane::getClassNameEdge()Type | Description |
---|---|
string |


getClassNameNode(
)
:
string
This method acts as getter for the CSS class name of the node shapes.
Inherited from: \Utils\Graphics2D\DrawingPanes\DomDrawingPane::getClassNameNode()Type | Description |
---|---|
string |


setClassNameEdge(
string $classNameEdge
)
:
void
This method acts as setter for the CSS class name of the edge shapes.
Inherited from: \Utils\Graphics2D\DrawingPanes\DomDrawingPane::setClassNameEdge()Name | Type | Description |
---|---|---|
$classNameEdge | string | the new name of the CSS class for edge shapes return void |


setClassNameNode(
string $classNameNode
)
:
void
This method acts as setter for the CSS class name of the node shapes.
Inherited from: \Utils\Graphics2D\DrawingPanes\DomDrawingPane::setClassNameNode()Name | Type | Description |
---|---|---|
$classNameNode | string | the new name of the CSS class for node shapes return void |


setFillColor(
\Utils\Color\Color $fillColor
)
:
\Utils\Graphics2D\DrawingPanes\DrawingPane
This method sets the fill color.
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::setFillColor()Name | Type | Description |
---|---|---|
$fillColor | \Utils\Color\Color | the new fill color |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\DrawingPane | $this |


setFontColor(
\Utils\Color\Color $fontColor
)
:
\Utils\Graphics2D\DrawingPanes\DrawingPane
This method sets the font color.
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::setFontColor()Name | Type | Description |
---|---|---|
$fontColor | \Utils\Color\Color | the new font color |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\DrawingPane | $this |


setFontFamily(
string $fontFamily
)
:
\Utils\Graphics2D\DrawingPanes\DrawingPane
This method sets the font familiy.
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::setFontFamily()Name | Type | Description |
---|---|---|
$fontFamily | string | the name of the new font family |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\DrawingPane | $this |


setFontSize(
int $fontSize
)
:
\Utils\Graphics2D\DrawingPanes\DrawingPane
This method sets the font size.
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::setFontSize()Name | Type | Description |
---|---|---|
$fontSize | int | the new font size in pixel |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\DrawingPane | $this |


setStrokeColor(
\Utils\Color\Color $strokeColor
)
:
\Utils\Graphics2D\DrawingPanes\DrawingPane
This method sets the stroke color.
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::setStrokeColor()Name | Type | Description |
---|---|---|
$strokeColor | \Utils\Color\Color | the new stroke color |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\DrawingPane | $this |


setStrokeWidth(
int $strokeWidth
)
:
\Utils\Graphics2D\DrawingPanes\DrawingPane
This method sets the stroke width.
Inherited from: \Utils\Graphics2D\DrawingPanes\DrawingPane::setStrokeWidth()Name | Type | Description |
---|---|---|
$strokeWidth | int | the new stroke width |
Type | Description |
---|---|
\Utils\Graphics2D\DrawingPanes\DrawingPane | $this |


toDOMColor(
\Utils\Graphics2D\DrawingPanes\RGBColor $color
)
:
string
This method converts a RGBColor to the DOM representation of the color.
Inherited from: \Utils\Graphics2D\DrawingPanes\DomDrawingPane::toDOMColor()Name | Type | Description |
---|---|---|
$color | \Utils\Graphics2D\DrawingPanes\RGBColor | the color to convert |
Type | Description |
---|---|
string | the DOM representation of the color |