【发布时间】:2012-07-19 13:46:59
【问题描述】:
我在 HTML5 画布中旋转了一个文本。它在除谷歌浏览器之外的所有浏览器上看起来都很好。它在 Windows 上的 chrome 上看起来失真。此外,它在 MAC 上看起来不错。为什么会这样? 我正在使用 Chrome beta 20。是一些 HTML 5 问题还是一些 Google Chrome 或 Windows 错误?我该如何解决这个失真问题?
<!DOCTYPE HTML>
<html>
<head>
<style>
body {
margin: 0px;
padding: 0px;
}
#myCanvas {
border: 1px solid #9C9898;
}
</style>
<script>
window.onload = function() {
var canvas = document.getElementById("myCanvas");
var context = canvas.getContext("2d");
context.font = "12pt Calibri";
context.rotate(Math.PI/2.5);
context.fillText("Competitive Landcaping!", 450, 100);
};
</script>
</head>
<body>
<canvas id="myCanvas" width="878" height="2000"></canvas>
</body>
</html>
【问题讨论】:
标签: windows html google-chrome html5-canvas kineticjs