Last active
August 29, 2015 14:16
-
-
Save mbroadst/af5588d030868bb9631e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var label_group = d3.select(selector + ' .label_group'); | |
label_group.selectAll("text").remove(); | |
label_group.selectAll("text") | |
.data(pie(Object.keys(data.status))) | |
.enter().append("svg:text") | |
.attr("dy", "1em") | |
.attr("dx", "0.5em") | |
.style("fill", "white") | |
.style("font", "bold 1.10em Arial") | |
.style("kerning", "1") | |
.style("letter-spacing", "2"); | |
var label_text = label_group.append("textPath") | |
.attr("xlink:href", function(d, i) { return "#path" + i; }); | |
label_text.append("svg:tspan") | |
.text(function(d) { return d.data; }); | |
label_text.append("svg:tspan") | |
.text(function(d) { return "testing"; }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment