Skip to content

Instantly share code, notes, and snippets.

@mbostock

mbostock/index.html Secret

Forked from mbostock/index.html
Last active Feb 9, 2016
Embed
What would you like to do?
Chrome Circle Precision Bug
<!DOCTYPE html>
<meta charset="utf-8">
<body>
<script src="//d3js.org/d3.v3.min.js"></script>
<script>
var canvas = d3.select("body").append("canvas")
.attr("width", 960)
.attr("height", 500);
var context = canvas.node().getContext("2d");
context.strokeStyle = "#000";
context.beginPath();
context.arc(395.8562790527633, 44.691485522888755, 44.691485522888755, 0, 2 * Math.PI);
context.moveTo(842.7711342816508 - 1117.2871380722188, 1117.2871380722188);
context.arc(842.7711342816508, 1117.2871380722188, 1117.2871380722188, -Math.PI, -Math.PI / 2);
context.stroke();
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment