Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

Properties

This section contains the HTML5 Canvas properties reference documentation.

Note  If you are developing on an intranet and have rendering issues for HTML5, you can add a "meta http-equiv-'X-UA-Compatible' content= " meta command, followed by "IE=edge" to the <head> block of a webpage to force Windows Internet Explorer to use the latest standards. For more information about document compatibility, see Defining Document Compatibility.

In this section

TopicDescription

canvas

Gets a back reference to the canvas object that the current context derives from.

data

Gets the CanvasPixelArray object that contains image data for a given CanvasImageData object.

fillStyle

Gets or sets the current style that is used to fill shapes.

font

Gets or sets the current font for the context.

globalAlpha

Gets or sets the current alpha or transparency value that is applied to global composite rendering operations.

globalCompositeOperation

Gets or sets a value that indicates how source images are drawn onto a destination image.

height (canvas)

Gets or sets the height of a canvas element on a document.

height (CanvasImageData)

Gets the number of rows of physical device pixels in the CanvasImageData object.

length

Gets or sets the number of pixel entries in a CanvasPixelArray object.

lineCap

Gets or sets the current line cap style.

lineDashOffset

Sets or gets the phase offset of the current line dash pattern. Can be changed to produce "marching ants" animation like marching ants.

lineJoin

Gets or sets the type of corner that is created when two lines meet.

lineWidth

Gets or sets the current line width, in pixels.

miterLimit

Gets or sets the maximum allowed ratio between half of the lineWidth value and the miter length.

msFillRule

Gets or sets the fill rule used to check if a point is inside a shape when filling.

msImageSmoothingEnabled

Choose bilinear or nearest-neighbor image smoothing when images are resized.

shadowBlur

Gets or sets the current level of blur that is applied to shadows.

shadowColor

Gets or sets the color to use for shadows.

shadowOffsetX

Gets or sets the horizontal distance of a shadow from a shape.

shadowOffsetY

Gets or sets the vertical distance of a shadow from a shape.

strokeStyle

Gets or sets the current style that is used for strokes (lines) on shapes.

textAlign

Gets or sets the current anchor point or alignment settings for text in the current context.

textBaseline

Gets or sets the current settings for the font baseline alignment.

width (canvas)

Gets or sets the width of a canvas element on a document.

width (CanvasImageData)

Gets the number of physical device pixels in a row of the CanvasImageData object.

width (CanvasTextMetrics)

Gets the width, in CSS pixels, of a given box of text.

 

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.