mirror of
git://git.tartarus.org/simon/puzzles.git
synced 2025-04-21 16:05:44 -07:00
Oops. I consistently misspelled my desired lineCap and lineJoin values
as "1" rather than "round". Must have had my Postscript brain in, and/or been confused by lineWidth = "1" just beforehand. This fixes a display glitch in Towers, where there's a tiny spike at the top left corner of each tower due to a very sharp mitred line join. [originally from svn r9791]
This commit is contained in:
12
emcclib.js
12
emcclib.js
@ -313,8 +313,8 @@ mergeInto(LibraryManager.library, {
|
|||||||
ctx.moveTo(x1 + 0.5, y1 + 0.5);
|
ctx.moveTo(x1 + 0.5, y1 + 0.5);
|
||||||
ctx.lineTo(x2 + 0.5, y2 + 0.5);
|
ctx.lineTo(x2 + 0.5, y2 + 0.5);
|
||||||
ctx.lineWidth = width;
|
ctx.lineWidth = width;
|
||||||
ctx.lineCap = '1';
|
ctx.lineCap = 'round';
|
||||||
ctx.lineJoin = '1';
|
ctx.lineJoin = 'round';
|
||||||
ctx.strokeStyle = colour;
|
ctx.strokeStyle = colour;
|
||||||
ctx.stroke();
|
ctx.stroke();
|
||||||
ctx.fillStyle = colour;
|
ctx.fillStyle = colour;
|
||||||
@ -342,8 +342,8 @@ mergeInto(LibraryManager.library, {
|
|||||||
ctx.fill();
|
ctx.fill();
|
||||||
}
|
}
|
||||||
ctx.lineWidth = '1';
|
ctx.lineWidth = '1';
|
||||||
ctx.lineCap = '1';
|
ctx.lineCap = 'round';
|
||||||
ctx.lineJoin = '1';
|
ctx.lineJoin = 'round';
|
||||||
ctx.strokeStyle = Pointer_stringify(outline);
|
ctx.strokeStyle = Pointer_stringify(outline);
|
||||||
ctx.stroke();
|
ctx.stroke();
|
||||||
},
|
},
|
||||||
@ -363,8 +363,8 @@ mergeInto(LibraryManager.library, {
|
|||||||
ctx.fill();
|
ctx.fill();
|
||||||
}
|
}
|
||||||
ctx.lineWidth = '1';
|
ctx.lineWidth = '1';
|
||||||
ctx.lineCap = '1';
|
ctx.lineCap = 'round';
|
||||||
ctx.lineJoin = '1';
|
ctx.lineJoin = 'round';
|
||||||
ctx.strokeStyle = Pointer_stringify(outline);
|
ctx.strokeStyle = Pointer_stringify(outline);
|
||||||
ctx.stroke();
|
ctx.stroke();
|
||||||
},
|
},
|
||||||
|
Reference in New Issue
Block a user