Mac OSX
 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.

 This interface abstracts a rendering engine-native canvas object
 onto which path and glyph geometries can be painted.

 A canvas object is instantiated by the backend for a given
 Mozilla-native rendering object with a call to
 nsISVGRenderer::createCanvas().
[scriptable, uuid(2e64a227-de4b-4a69-ab82-5dda1579e90f)]
interface nsISVGRendererCanvas : nsISupports

Constants

 Set render mode (clipping or normal draw)
const unsigned short SVG_RENDER_MODE_NORMAL = 0

        
const unsigned short SVG_RENDER_MODE_CLIP = 1

Attributes


        
attribute unsigned short renderMode

Methods

 Fill the canvas with the given color.

 @param color Fill color.
void clear(in nscolor color)
 Surface composition.
void compositeSurface(in nsISVGRendererSurface surface, in unsigned long x, in unsigned long y, in float opacity)

        
void compositeSurfaceMatrix(in nsISVGRendererSurface surface, in nsIDOMSVGMatrix canvasTM, in float opacity)
 Ensure that all renderings on the canvas have been flushed to the
 Mozilla-native rendering context.
void flush()

        
nsPresContext getPresContext()
 Lock a portion of the canvas and obtain a rendering context onto
 which Mozilla can paint non-svg content. This is needed for
 (partial) foreignObject support.

 lockRenderingContext() calls are paired with
 unlockRenderingContext() calls.

 @param rect Area to be locked.
 @return Mozilla-native rendering context for the locked area.
[noscript] nsIRenderingContext lockRenderingContext([const] in nsRectRef rect)

        
void popClip()

        
void popSurface()
 Push/Pop clip path.
void pushClip()
 Push/Pop surface as primary drawing surface.
void pushSurface(in nsISVGRendererSurface surface)
 Set rectangular clip region.
void setClipRect(in nsIDOMSVGMatrix canvasTM, in float x, in float y, in float width, in float height)
 Unlock the canvas portion locked with a previous call to
 lockRenderingContext(). 
void unlockRenderingContext()