JavaScript must be enabled in order for you to use JSXGraph and JSXGraph reference. However, it seems JavaScript is either disabled or not supported by your browser.

Class Index | File Index

Elements
Classes

Class JXG.NoRenderer

JXG.AbstractRenderer
      ↳ JXG.NoRenderer

JXG.NoRenderer

Defined in: no.js.
Extends JXG.AbstractRenderer.

Class Summary
Constructor Attributes Constructor Name and Description
 
This renderer draws nothing.
Fields borrowed from class JXG.AbstractRenderer:
container, dashArray, supportsForeignObject, vOffsetText
Field Summary
Field Attributes Field Name and Description
 
If this property is set to true the visual properties of the elements are updated on every update.
 
This is used to easily determine which renderer we are using
Fields borrowed from class JXG.AbstractRenderer:
container, dashArray, supportsForeignObject, vOffsetText
Method Summary
Method Attributes Method Name and Description
 
appendChildPrim(node, level)
Appends a node to a specific layer level.
 
appendNodesToElement(element, type)
Stores the rendering nodes.
 
Changes the style of a JXG.Point.
 
createPrim(type, id)
Creates a node of a given type with a given id.
 
display(element, value)
Shows or hides an element on the canvas; Only a stub, requires implementation in the derived renderer.
 
displayCopyright(str, fontsize)
Shows a small copyright notice in the top left corner of the board.
 
drawCurve(element)
Draws a JXG.Curve on the JXG.Board.
 
drawEllipse(element)
Draws a JXG.Circle
 
drawImage(element)
Draws an JXG.Image on a board; This is just a template that has to be implemented by special renderers.
 
An internal text is a JXG.Text element which is drawn using only the given renderer but no HTML.
 
drawLine(element)
Draws a line on the JXG.Board.
 
The tiny zoom bar shown on the bottom of a board (if showNavigation on board creation is true).
 
drawPoint(element)
Draws a point on the JXG.Board.
 
drawPolygon(element)
Draws a JXG.Polygon on the JXG.Board.
 
drawText(element)
Displays a JXG.Text on the JXG.Board by putting a HTML div over it.
 
drawTicks(element)
Creates a rendering node for ticks added to a line.
 
Wrapper for getElementById for maybe other renderers which elements are not directly accessible by DOM methods like document.getElementById().
 
hide(element)
Hides an element on the canvas; Only a stub, requires implementation in the derived renderer.
 
highlight(element)
Highlights an object, i.e.
 
makeArrows(element)
Can be used to create the nodes to display arrows.
 
noHighlight(element)
Uses the normal colors of an object, i.e.
 
remove(node)
Removes an element node.
 
removeDraft(element)
Puts an object from draft mode back into normal mode.
 
resize(w, h)
Resizes the rendering element
 
setBuffering(node, type)
Sets the buffering as recommended by SVGWG.
 
setDashStyle(element)
Sets an element's dash style.
 
setDraft(element)
Puts an object into draft mode, i.e.
 
setGradient(element)
Sets up nodes for rendering a gradient fill.
 
setObjectFillColor(element, color, opacity)
Sets an objects fill color.
 
setObjectStrokeColor(element, color, opacity)
Changes an objects stroke color to the given color.
 
setObjectStrokeWidth(element, width)
Sets an element's stroke width.
 
setObjectTransition(element, duration)
Sets the transition duration (in milliseconds) for fill color and stroke color and opacity.
 
setPropertyPrim(node, key, val)
Sets a node's attribute.
 
setShadow(element)
Sets the shadow properties to a geometry element.
 
show(element)
Shows a hidden element on the canvas; Only a stub, requires implementation in the derived renderer.
 
Stop redraw.
 
transformImage(element, transformations)
Applies transformations on images and text elements.
 
Restart redraw.
 
updateCurve(element)
Updates visual appearance of the renderer element assigned to the given JXG.Curve.
 
updateEllipse(element)
Updates visual appearance of a given JXG.Circle on the JXG.Board.
 
updateEllipsePrim(node, x, y, rx, ry)
Updates an ellipse node primitive.
 
updateGradient(element)
Updates the gradient fill.
 
updateImage(element)
Updates the properties of an JXG.Image element.
 
updateImageURL(element)
If the URL of the image is provided by a function the URL has to be updated during updateImage()
 
Updates visual properties of an already existing JXG.Text element.
<private>  
updateInternalTextStyle(element, strokeColor, strokeOpacity)
Set color and opacity of internal texts.
 
updateLine(element)
Updates visual appearance of the renderer element assigned to the given JXG.Line.
 
updateLinePrim(node, p1x, p1y, p2x, p2y, board)
Refreshes a line node.
 
updatePathPrim(node, pathString, board)
Updates a path element.
 
Builds a path data string from a JXG.Curve element such that the curve looks like hand drawn.
 
updatePathStringPoint(element, size, type)
Builds a path data string to draw a point with a face other than rect and circle.
 
Builds a path data string from a JXG.Curve element.
 
updatePoint(element)
Updates visual appearance of the renderer element assigned to the given JXG.Point.
 
updatePolygon(element)
Updates properties of a JXG.Polygon's rendering node.
 
updatePolygonPrim(node, element)
Update a polygon primitive.
 
updateRectPrim(node, x, y, w, h)
Update a rectangle primitive.
 
updateText(element)
Updates visual properties of an already existing JXG.Text element.
 
updateTextStyle(element, doHighlight)
Updates CSS style properties of a JXG.Text node.
 
updateTicks(element)
Update Ticks on a JXG.Line.
Methods borrowed from class JXG.AbstractRenderer:
_css2js, _getHighlighted, _setArrowWidth, _updateVisual, createTouchpoints, dumpToCanvas, dumpToDataURI, getArrowHeadData, getPositionArrowHead, handleTouchpoints, hideTouchpoint, joinTransforms, removeToInsertLater, screenshot, setARIA, setArrowSize, setCssClass, setLayer, setLineCap, showTouchpoint, updateImageStyle, updateLineWithEndings, updatePath, updatePathWithArrowHeads, updateTouchpoint
Class Detail
JXG.NoRenderer()
This renderer draws nothing. It is intended to be used in environments where none of our rendering engines are available, e.g. WebWorkers. All methods are empty.
See:
JXG.AbstractRenderer
Field Detail
{Boolean} enhancedRendering
If this property is set to true the visual properties of the elements are updated on every update. Visual properties means: All the stuff stored in the JXG.GeometryElement#visProp property won't be set if enhancedRendering is false
Default Value:
true

{String} type
This is used to easily determine which renderer we are using
if (board.renderer.type === 'vml') {
    // do something
}
Method Detail
appendChildPrim(node, level)
Appends a node to a specific layer level. This is just an abstract method and has to be implemented in all renderers that want to use the createPrim model to draw.
Parameters:
{Node} node
A DOM tree node.
{Number} level
The layer the node is attached to. This is the index of the layer in JXG.SVGRenderer#layer or the z-index style property of the node in VMLRenderer.

appendNodesToElement(element, type)
Stores the rendering nodes. This is an abstract method which has to be implemented in all renderers that use the createPrim method.
Parameters:
{JXG.GeometryElement} element
A JSXGraph element.
{String} type
The XML node name. Only used in VMLRenderer.

changePointStyle(element)
Changes the style of a JXG.Point. This is required because the point styles differ in what elements have to be drawn, e.g. if the point is marked by a "x" or a "+" two lines are drawn, if it's marked by spot a circle is drawn. This method removes the old renderer element(s) and creates the new one(s).
Parameters:
{JXG.Point} element
Reference to a JXG.Point object, that's style is changed.
See:
Point
JXG.Point
JXG.AbstractRenderer#updatePoint
JXG.AbstractRenderer#drawPoint

{Node} createPrim(type, id)
Creates a node of a given type with a given id.
Parameters:
{String} type
The type of the node to create.
{String} id
Set the id attribute to this.
Returns:
{Node} Reference to the created node.

display(element, value)
Shows or hides an element on the canvas; Only a stub, requires implementation in the derived renderer.
Parameters:
{JXG.GeometryElement} element
Reference to the object that has to appear.
{Boolean} value
true to show the element, false to hide the element.

displayCopyright(str, fontsize)
Shows a small copyright notice in the top left corner of the board.
Parameters:
{String} str
The copyright notice itself
{Number} fontsize
Size of the font the copyright notice is written in

drawCurve(element)
Draws a JXG.Curve on the JXG.Board.
Parameters:
{JXG.Curve} element
Reference to a graph object, that has to be plotted.
See:
Curve
JXG.Curve
JXG.AbstractRenderer#updateCurve

drawEllipse(element)
Draws a JXG.Circle
Parameters:
{JXG.Circle} element
Reference to a JXG.Circle object that has to be drawn.
See:
Circle
JXG.Circle
JXG.AbstractRenderer#updateEllipse

drawImage(element)
Draws an JXG.Image on a board; This is just a template that has to be implemented by special renderers.
Parameters:
{JXG.Image} element
Reference to the image object that is to be drawn
See:
Image
JXG.Image
JXG.AbstractRenderer#updateImage

drawInternalText(element)
An internal text is a JXG.Text element which is drawn using only the given renderer but no HTML. This method is only a stub, the drawing is done in the special renderers.
Parameters:
{JXG.Text} element
Reference to a JXG.Text object
See:
Text
JXG.Text
JXG.AbstractRenderer#updateInternalText
JXG.AbstractRenderer#drawText
JXG.AbstractRenderer#updateText
JXG.AbstractRenderer#updateTextStyle

drawLine(element)
Draws a line on the JXG.Board.
Parameters:
{JXG.Line} element
Reference to a line object, that has to be drawn.
See:
Line
JXG.Line
JXG.AbstractRenderer#updateLine

drawNavigationBar(board)
The tiny zoom bar shown on the bottom of a board (if showNavigation on board creation is true).
Parameters:
{JXG.Board} board
Reference to a JSXGraph board.

drawPoint(element)
Draws a point on the JXG.Board.
Parameters:
{JXG.Point} element
Reference to a JXG.Point object that has to be drawn.
See:
Point
JXG.Point
JXG.AbstractRenderer#updatePoint
JXG.AbstractRenderer#changePointStyle

drawPolygon(element)
Draws a JXG.Polygon on the JXG.Board.
Parameters:
{JXG.Polygon} element
Reference to a Polygon object, that is to be drawn.
See:
Polygon
JXG.Polygon
JXG.AbstractRenderer#updatePolygon

drawText(element)
Displays a JXG.Text on the JXG.Board by putting a HTML div over it.
Parameters:
{JXG.Text} element
Reference to an JXG.Text object, that has to be displayed
See:
Text
JXG.Text
JXG.AbstractRenderer#drawInternalText
JXG.AbstractRenderer#updateText
JXG.AbstractRenderer#updateInternalText
JXG.AbstractRenderer#updateTextStyle

drawTicks(element)
Creates a rendering node for ticks added to a line.
Parameters:
{JXG.Line} element
A arbitrary line.
See:
Line
Ticks
JXG.Line
JXG.Ticks
JXG.AbstractRenderer#updateTicks

{Object} getElementById(id)
Wrapper for getElementById for maybe other renderers which elements are not directly accessible by DOM methods like document.getElementById().
Parameters:
{String} id
Unique identifier for element.
Returns:
{Object} Reference to a JavaScript object. In case of SVG/VMLRenderer it's a reference to a SVG/VML node.

hide(element)
Hides an element on the canvas; Only a stub, requires implementation in the derived renderer. Please use JXG.AbstractRenderer#display instead
Parameters:
{JXG.GeometryElement} element
Reference to the geometry element that has to disappear.
See:
JXG.AbstractRenderer#show

{JXG.AbstractRenderer} highlight(element)
Highlights an object, i.e. changes the current colors of the object to its highlighting colors
Parameters:
{JXG.GeometryElement} element
Reference of the object that will be highlighted.
Returns:
{JXG.AbstractRenderer} Reference to the renderer

makeArrows(element)
Can be used to create the nodes to display arrows. This is an abstract method which has to be implemented in any descendant renderer.
Parameters:
{JXG.GeometryElement} element
The element the arrows are to be attached to.

{JXG.AbstractRenderer} noHighlight(element)
Uses the normal colors of an object, i.e. the opposite of JXG.AbstractRenderer#highlight.
Parameters:
{JXG.GeometryElement} element
Reference of the object that will get its normal colors.
Returns:
{JXG.AbstractRenderer} Reference to the renderer

remove(node)
Removes an element node. Just a stub.
Parameters:
{Node} node
The node to remove.

removeDraft(element)
Puts an object from draft mode back into normal mode.
Parameters:
{JXG.GeometryElement} element
Reference of the object that no longer is in draft mode.

resize(w, h)
Resizes the rendering element
Parameters:
{Number} w
New width
{Number} h
New height

setBuffering(node, type)
Sets the buffering as recommended by SVGWG. Until now only Opera supports this and will be ignored by other browsers. Although this feature is only supported by SVG we have this method in JXG.AbstractRenderer because it is called from outside the renderer.
Parameters:
{Node} node
The SVG DOM Node which buffering type to update.
{String} type
Either 'auto', 'dynamic', or 'static'. For an explanation see https://www.w3.org/TR/SVGTiny12/painting.html#BufferedRenderingProperty.

setDashStyle(element)
Sets an element's dash style.
Parameters:
{JXG.GeometryElement} element
An JSXGraph element.

setDraft(element)
Puts an object into draft mode, i.e. it's visual appearance will be changed. For GEONExT backwards compatibility.
Parameters:
{JXG.GeometryElement} element
Reference of the object that is in draft mode.

setGradient(element)
Sets up nodes for rendering a gradient fill.
Parameters:
element

setObjectFillColor(element, color, opacity)
Sets an objects fill color.
Parameters:
{JXG.GeometryElement} element
Reference of the object that wants a new fill color.
{String} color
Color in a HTML/CSS compatible format. If you don't want any fill color at all, choose 'none'.
{Number} opacity
Opacity of the fill color. Must be between 0 and 1.

setObjectStrokeColor(element, color, opacity)
Changes an objects stroke color to the given color.
Parameters:
{JXG.GeometryElement} element
Reference of the JXG.GeometryElement that gets a new stroke color.
{String} color
Color value in a HTML compatible format, e.g. #00ff00 or green for green.
{Number} opacity
Opacity of the fill color. Must be between 0 and 1.

setObjectStrokeWidth(element, width)
Sets an element's stroke width.
Parameters:
{JXG.GeometryElement} element
Reference to the geometry element.
{Number} width
The new stroke width to be assigned to the element.

setObjectTransition(element, duration)
Sets the transition duration (in milliseconds) for fill color and stroke color and opacity.
Parameters:
{JXG.GeometryElement} element
Reference of the object that wants a new transition duration.
{Number} duration
(Optional) duration in milliseconds. If not given, element.visProp.transitionDuration is taken. This is the default.

setPropertyPrim(node, key, val)
Sets a node's attribute.
Parameters:
{Node} node
The node that is to be updated.
{String} key
Name of the attribute.
{String} val
New value for the attribute.

setShadow(element)
Sets the shadow properties to a geometry element. This method is only a stub, it is implemented in the actual renderers.
Parameters:
{JXG.GeometryElement} element
Reference to a geometry object, that should get a shadow

show(element)
Shows a hidden element on the canvas; Only a stub, requires implementation in the derived renderer. Please use JXG.AbstractRenderer#display instead
Parameters:
{JXG.GeometryElement} element
Reference to the object that has to appear.
See:
JXG.AbstractRenderer#hide

suspendRedraw()
Stop redraw. This method is called before every update, so a non-vector-graphics based renderer can use this method to delete the contents of the drawing panel. This is an abstract method every descendant renderer should implement, if appropriate.
See:
JXG.AbstractRenderer#unsuspendRedraw

transformImage(element, transformations)
Applies transformations on images and text elements. This method is just a stub and has to be implemented in all descendant classes where text and image transformations are to be supported.
Parameters:
{JXG.Image|JXG.Text} element
A JXG.Image or JXG.Text object.
{Array} transformations
An array of JXG.Transformation objects. This is usually the transformations property of the given element el.

unsuspendRedraw()
Restart redraw. This method is called after updating all the rendering node attributes.
See:
JXG.AbstractRenderer#suspendRedraw

updateCurve(element)
Updates visual appearance of the renderer element assigned to the given JXG.Curve.
Parameters:
{JXG.Curve} element
Reference to a JXG.Curve object, that has to be updated.
See:
Curve
JXG.Curve
JXG.AbstractRenderer#drawCurve

updateEllipse(element)
Updates visual appearance of a given JXG.Circle on the JXG.Board.
Parameters:
{JXG.Circle} element
Reference to a JXG.Circle object, that has to be updated.
See:
Circle
JXG.Circle
JXG.AbstractRenderer#drawEllipse

updateEllipsePrim(node, x, y, rx, ry)
Updates an ellipse node primitive. This is an abstract method which has to be implemented in all renderers that use the createPrim method.
Parameters:
{Node} node
Reference to the node.
{Number} x
Centre X coordinate
{Number} y
Centre Y coordinate
{Number} rx
The x-axis radius.
{Number} ry
The y-axis radius.

updateGradient(element)
Updates the gradient fill.
Parameters:
{JXG.GeometryElement} element
An JSXGraph element with an area that can be filled.

updateImage(element)
Updates the properties of an JXG.Image element.
Parameters:
{JXG.Image} element
Reference to an JXG.Image object, that has to be updated.
See:
Image
JXG.Image
JXG.AbstractRenderer#drawImage

updateImageURL(element)
If the URL of the image is provided by a function the URL has to be updated during updateImage()
Parameters:
{JXG.Image} element
Reference to an image object.
See:
JXG.AbstractRenderer#updateImage

updateInternalText(element)
Updates visual properties of an already existing JXG.Text element.
Parameters:
{JXG.Text} element
Reference to an JXG.Text object, that has to be updated.
See:
Text
JXG.Text
JXG.AbstractRenderer#drawInternalText
JXG.AbstractRenderer#drawText
JXG.AbstractRenderer#updateText
JXG.AbstractRenderer#updateTextStyle

<private> updateInternalTextStyle(element, strokeColor, strokeOpacity)
Set color and opacity of internal texts. SVG needs its own version.
Parameters:
element
strokeColor
strokeOpacity
See:
JXG.AbstractRenderer#updateTextStyle
JXG.AbstractRenderer#updateInternalTextStyle

updateLine(element)
Updates visual appearance of the renderer element assigned to the given JXG.Line.
Parameters:
{JXG.Line} element
Reference to the JXG.Line object that has to be updated.
See:
Line
JXG.Line
JXG.AbstractRenderer#drawLine

updateLinePrim(node, p1x, p1y, p2x, p2y, board)
Refreshes a line node. This is an abstract method which has to be implemented in all renderers that use the createPrim method.
Parameters:
{Node} node
The node to be refreshed.
{Number} p1x
The first point's x coordinate.
{Number} p1y
The first point's y coordinate.
{Number} p2x
The second point's x coordinate.
{Number} p2y
The second point's y coordinate.
{JXG.Board} board

updatePathPrim(node, pathString, board)
Updates a path element. This is an abstract method which has to be implemented in all renderers that use the createPrim method.
Parameters:
{Node} node
The path node.
{String} pathString
A string formatted like e.g. 'M 1,2 L 3,1 L5,5'. The format of the string depends on the rendering engine.
{JXG.Board} board
Reference to the element's board.

updatePathStringBezierPrim(element)
Builds a path data string from a JXG.Curve element such that the curve looks like hand drawn. Since the path data strings heavily depend on the underlying rendering technique this method is just a stub. Although such a path string is of no use for the CanvasRenderer, this method is used there to draw a path directly.
Parameters:
element

updatePathStringPoint(element, size, type)
Builds a path data string to draw a point with a face other than rect and circle. Since the format of such a string usually depends on the renderer this method is only an abstract method. Therefore, it has to be implemented in the descendant renderer itself unless the renderer does not use the createPrim interface but the draw* interfaces to paint.
Parameters:
{JXG.Point} element
The point element
{Number} size
A positive number describing the size. Usually the half of the width and height of the drawn point.
{String} type
A string describing the point's face. This method only accepts the shortcut version of each possible face: x, +, |, -, [], <>, <<>>, ^, v, >, <

updatePathStringPrim(element)
Builds a path data string from a JXG.Curve element. Since the path data strings heavily depend on the underlying rendering technique this method is just a stub. Although such a path string is of no use for the CanvasRenderer, this method is used there to draw a path directly.
Parameters:
element

updatePoint(element)
Updates visual appearance of the renderer element assigned to the given JXG.Point.
Parameters:
{JXG.Point} element
Reference to a JXG.Point object, that has to be updated.
See:
Point
JXG.Point
JXG.AbstractRenderer#drawPoint
JXG.AbstractRenderer#changePointStyle

updatePolygon(element)
Updates properties of a JXG.Polygon's rendering node.
Parameters:
{JXG.Polygon} element
Reference to a JXG.Polygon object, that has to be updated.
See:
Polygon
JXG.Polygon
JXG.AbstractRenderer#drawPolygon

updatePolygonPrim(node, element)
Update a polygon primitive.
Parameters:
{Node} node
{JXG.Polygon} element
A JSXGraph element of type JXG.Polygon

updateRectPrim(node, x, y, w, h)
Update a rectangle primitive. This is used only for points with face of type 'rect'.
Parameters:
{Node} node
The node yearning to be updated.
{Number} x
x coordinate of the top left vertex.
{Number} y
y coordinate of the top left vertex.
{Number} w
Width of the rectangle.
{Number} h
The rectangle's height.

updateText(element)
Updates visual properties of an already existing JXG.Text element.
Parameters:
{JXG.Text} element
Reference to an JXG.Text object, that has to be updated.
See:
Text
JXG.Text
JXG.AbstractRenderer#drawText
JXG.AbstractRenderer#drawInternalText
JXG.AbstractRenderer#updateInternalText
JXG.AbstractRenderer#updateTextStyle

updateTextStyle(element, doHighlight)
Updates CSS style properties of a JXG.Text node.
Parameters:
{JXG.Text} element
Reference to the JXG.Text object, that has to be updated.
{Boolean} doHighlight
See:
Text
JXG.Text
JXG.AbstractRenderer#drawText
JXG.AbstractRenderer#drawInternalText
JXG.AbstractRenderer#updateText
JXG.AbstractRenderer#updateInternalText

updateTicks(element)
Update Ticks on a JXG.Line. This method is only a stub and has to be implemented in any descendant renderer class.
Parameters:
{JXG.Line} element
Reference of an line object, thats ticks have to be updated.
See:
Line
Ticks
JXG.Line
JXG.Ticks
JXG.AbstractRenderer#drawTicks

Documentation generated by JsDoc Toolkit 2.4.0 on Fri Nov 08 2024 12:13:06 GMT+0100 (Mitteleuropäische Normalzeit)