nsISVGRendererPathGeometry
IID: | 1e4a2bc7-96e6-4c4d-80a6-e284cec9e3aa |
Inherits From: | nsISupports |
\addtogroup renderer_interfaces Rendering Engine Interfaces One of a number of interfaces (all starting with nsISVGRenderer*) to be implemented by an SVG rendering engine. See nsISVGRenderer for more details.
The SVG rendering backend uses this interface to communicate to the rendering engine-native path objects.
A path geometry object is instantiated by the rendering backend for a given nsISVGPathGeometrySource object with a call to nsISVGRenderer::createPathGeometry(). The path geometry object is assumed to store a reference to its associated source object and provide rendering, hit-testing and metrics for the path described by the nsISVGPathGeometrySource members.
Properties
readonly nsIDOMSVGRect boundingBox
Bounding box (does not include stroke width)
Methods
PRBool containsPoint ( float x , float y )
nsISVGRendererRegion getCoveredRegion ( )
void render ( nsISVGRendererCanvas canvas )
nsISVGRendererRegion update ( PRUint32 updatemask )
PRBool containsPoint ( float x , float y )
Hit-testing method. Does this path geometry (with all relevant transformations applied) contain the point x,y? Mode of operation (e.g. whether to test fill or stroke) is determined by nsISVGPathGeometrySource::hittestMask.
- Arguments:
- x: X-coordinate of test point. @param y Y-coordinate of test point.
- y
- Returns:
- PR_TRUE if the path geometry contains the point, PR_FALSE otherwise.
nsISVGRendererRegion getCoveredRegion ( )
Get a region object describing the area covered with paint by this path geometry.
- Returns:
- Covered region.
void render ( nsISVGRendererCanvas canvas )
Paint this object.
- Arguments:
- canvas: The canvas to render to.
nsISVGRendererRegion update ( PRUint32 updatemask )
Called by this object's corresponding nsISVGPathGeometrySource as a notification that some of the source's data (identified by paramter 'updatemask') has changed.
- Arguments:
- updatemask: An OR-ed combination of the UPDATEMASK_* constants defined in nsISVGPathGeometrySource.
- Returns:
- Region that needs to be redrawn.
References
This interface is returned from the following methods:
nsISVGRenderer.createPathGeometry
Reference documentation is generated from Mozilla's source.