Comparing version 2.8.4 to 2.8.5
/** | ||
* oCanvas v2.8.4 | ||
* oCanvas v2.8.5 | ||
* http://ocanvas.org/ | ||
@@ -4,0 +4,0 @@ * |
{ | ||
"name": "ocanvas", | ||
"version": "2.8.4", | ||
"version": "2.8.5", | ||
"author": "Johannes Koggdal <johannes@koggdal.com>", | ||
@@ -5,0 +5,0 @@ "description": "Library for HTML5 Canvas, based on objects instead of pixels.", |
@@ -7,3 +7,3 @@ (function(window, document, undefined){ | ||
// Version number of this oCanvas release. | ||
version: "2.8.4", | ||
version: "2.8.5", | ||
@@ -10,0 +10,0 @@ // Array containing all canvases created by oCanvas on the current page |
@@ -101,2 +101,22 @@ (function(oCanvas, window, document, undefined){ | ||
// Reset canvas properties to their default values | ||
canvas.strokeStyle = "#000"; | ||
canvas.fillStyle = "#000"; | ||
canvas.globalAlpha = 1; | ||
canvas.lineWidth = 1; | ||
canvas.lineCap = "butt"; | ||
canvas.lineJoin = "miter"; | ||
canvas.miterLimit = 10; | ||
canvas.lineDashOffset = 0; | ||
canvas.shadowOffsetX = 0; | ||
canvas.shadowOffsetY = 0; | ||
canvas.shadowBlur = 0; | ||
canvas.shadowColor = 'rgba(0, 0, 0, 0)'; | ||
canvas.globalCompositeOperation = 'source-over'; | ||
canvas.font = '10px sans-serif'; | ||
canvas.textAlign = 'start'; | ||
canvas.textBaseline = 'alphabetic'; | ||
canvas.direction = 'inherit'; | ||
canvas.imageSmoothingEnabled = true; | ||
// Update the object's properties if an update method is available | ||
@@ -169,7 +189,2 @@ if (typeof obj.update === "function") { | ||
// Reset stroke properties | ||
canvas.lineCap = "butt"; | ||
canvas.lineJoin = "miter"; | ||
canvas.miterLimit = 10; | ||
// Loop children recursively to draw everything in the correct order | ||
@@ -176,0 +191,0 @@ if (obj.children.length > 0) { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
2349681
50
48537