2014-02-19 19 views
0

我想從jqplot的折線圖中的y軸上刪除tickmarks。我已經在jqplot中創建了多個y軸折線圖,其工作正常,但我想隱藏y2axis等行。我已經編寫了代碼,但它只隱藏了行顯示tickmarks。我想隱藏兩者。請參閱下圖。從jqplot的折線圖中隱藏yaxis的tickmarks

enter image description here

我有下面的代碼寫爲y軸隱藏線和刻度線。

grid: { 
    drawBorder: false, 
    borderWidth:0, 
    shadow:false 
} 

回答

2

可以顯示/隱藏單獨網格線軸選項區域內:

axes: { 
    xaxis: { 
     tickOptions: { 
      showGridline: true, 
      showMark: true 
     } 
    }, 
    yaxis: { 
     tickOptions: { 
      showGridline: false, 
      showMark: false 
     } 
    } 
} 

的全部細節參見文檔的this section

+0

你確定它不是showMark選項嗎?這是我以前隱藏的刻度... http://www.jqplot.com/docs/files/jqplot-axisTickRenderer-js.html#$.jqplot.AxisTickRenderer.showMark – Askanison4

+1

@ Askanison4你可能是正確的 - - 更新的答案都有。這個問題有關不清楚的結果 – explunit

+0

好的電話。你得到我的投票! – Askanison4