關於canvas繪製線性圓角矩形,不是背景色填充類型

  // 封裝一個函數,將用來繪製圓角矩形 function drawRoundRect(cxt, x, y, width, height, radius){ cxt.beginPath(); cxt.arc(x + radius, y + radius, radius, Math.PI, Math.PI * 3 / 2); cxt.lineTo(width - radiu
相關文章
相關標籤/搜索