mirror of
https://github.com/serratus/quaggaJS.git
synced 2026-08-12 21:21:42 +08:00
Allow drawRect to accept and handle style.lineWidth (#315)
Allow drawRect to accept and handle style.lineWidth
This commit is contained in:
@@ -2,7 +2,7 @@ export default {
|
||||
drawRect: function(pos, size, ctx, style){
|
||||
ctx.strokeStyle = style.color;
|
||||
ctx.fillStyle = style.color;
|
||||
ctx.lineWidth = 1;
|
||||
ctx.lineWidth = style.lineWidth || 1;
|
||||
ctx.beginPath();
|
||||
ctx.strokeRect(pos.x, pos.y, size.x, size.y);
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user