g.append('g').call(x_axis).attr('transform','translate('+0+','+g_height+')').append("text").text("時間").attr("text-anchor","end").attr("dx","1em")?調(diào)整位置可以用三種方式,你嘗試一下:- .attr("x", "1em")指定x 軸方向的位置- .attr("dx", "1em")指定x 軸方向的偏移-?.attr("text-anchor","end"),end 也可以替換為 start然而沒用,該怎么改?
x軸我想讓它顯示“時間, 這段代碼卻 在x軸最左側(cè)?我想讓它在最右側(cè)?怎么改?。靠戳藰窍吕蠋熃o的方法,沒用啊
Nemonameless
2015-07-30 21:05:19