From 41410d53ab7ff56dada27d9b39f598b8e0e1787b Mon Sep 17 00:00:00 2001 From: Nils Schneider Date: Sat, 16 Jun 2012 04:06:32 +0200 Subject: [PATCH] pacman icon --- html/force.js | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/html/force.js b/html/force.js index a8a975b..d36a2c4 100644 --- a/html/force.js +++ b/html/force.js @@ -62,8 +62,18 @@ var style_btn = cp.append("button") cp.append("button") .attr("class", "btn") .attr("value", "reload") - .text("Click me!") .on("click", pacman) + .append("svg") + .attr("width", 12) + .attr("height", 12) + .append("path") + .attr("d", d3.svg.arc().innerRadius(0) + .outerRadius(5) + .endAngle(-Math.PI/4 + Math.PI/2 + 2*Math.PI) + .startAngle(Math.PI/4 + Math.PI/2)) + .attr("fill", "#888") + .attr("transform", "translate(6,7)") + var btns = cp.append("div") .attr("class", "btn-group")