Comparing version 0.7.1 to 0.7.2
0.7.2 / 2011-08-30 | ||
================== | ||
* Changed: prefix some private methods with _ | ||
0.7.1 / 2011-08-25 | ||
@@ -3,0 +8,0 @@ ================== |
@@ -31,3 +31,3 @@ | ||
exports.version = '0.7.1'; | ||
exports.version = '0.7.2'; | ||
@@ -34,0 +34,0 @@ /** |
@@ -155,5 +155,5 @@ | ||
this.lastFillStyle = val; | ||
this.setFillPattern(val); | ||
this._setFillPattern(val); | ||
} else if ('string' == typeof val) { | ||
this.setFillColor(val); | ||
this._setFillColor(val); | ||
} | ||
@@ -182,5 +182,5 @@ }); | ||
this.lastStrokeStyle = val; | ||
this.setStrokePattern(val); | ||
this._setStrokePattern(val); | ||
} else if ('string' == typeof val) { | ||
this.setStrokeColor(val); | ||
this._setStrokeColor(val); | ||
} | ||
@@ -213,3 +213,3 @@ }); | ||
this.lastFontString = val; | ||
this.setFont( | ||
this._setFont( | ||
font.weight | ||
@@ -244,3 +244,3 @@ , font.style | ||
this.lastBaseline = val; | ||
this.setTextBaseline(n); | ||
this._setTextBaseline(n); | ||
} | ||
@@ -268,3 +268,3 @@ }); | ||
case 'center': | ||
this.setTextAlignment(0); | ||
this._setTextAlignment(0); | ||
this.lastTextAlignment = val; | ||
@@ -274,3 +274,3 @@ break; | ||
case 'start': | ||
this.setTextAlignment(-1); | ||
this._setTextAlignment(-1); | ||
this.lastTextAlignment = val; | ||
@@ -280,3 +280,3 @@ break; | ||
case 'end': | ||
this.setTextAlignment(1); | ||
this._setTextAlignment(1); | ||
this.lastTextAlignment = val; | ||
@@ -283,0 +283,0 @@ break; |
{ "name": "canvas" | ||
, "description": "Canvas graphics API backed by Cairo" | ||
, "version": "0.7.1" | ||
, "version": "0.7.2" | ||
, "author": "TJ Holowaychuk <tj@learnboost.com>" | ||
@@ -5,0 +5,0 @@ , "keywords": ["canvas", "graphic", "graphics", "pixman", "cairo"] |
@@ -12,13 +12,18 @@ | ||
var img = new Image; | ||
ctx.font = '20px Helvetica'; | ||
ctx.fillText('Testing', 100, 100); | ||
img.onload = function(){ | ||
ctx.fillRect(100,100,80,90); | ||
ctx.drawImage(img, 0, 0); | ||
var out = fs.createWriteStream(__dirname + '/../test.png'); | ||
canvas.createPNGStream().on('data', function(chunk){ | ||
out.write(chunk); | ||
});; | ||
}; | ||
fs.writeFile('test.png', canvas.toBuffer()); | ||
img.src = __dirname + '/textures/black-marble.png'; | ||
// var img = new Image; | ||
// | ||
// img.onload = function(){ | ||
// ctx.fillRect(100,100,80,90); | ||
// ctx.drawImage(img, 0, 0); | ||
// var out = fs.createWriteStream(__dirname + '/../test.png'); | ||
// canvas.createPNGStream().on('data', function(chunk){ | ||
// out.write(chunk); | ||
// });; | ||
// }; | ||
// | ||
// img.src = __dirname + '/textures/black-marble.png'; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3709
2899666