chiark / gitweb /
Fix vertically misaligned text in Javascript puzzles.
authorSimon Tatham <anakin@pobox.com>
Sat, 21 Jun 2014 17:40:29 +0000 (17:40 +0000)
committerSimon Tatham <anakin@pobox.com>
Sat, 21 Jun 2014 17:40:29 +0000 (17:40 +0000)
commitff8a9fbc541b714e64fc089f75ec712a04cbd90f
tree5737d5de67df85038926e744ce667bf09100def3
parenta7ddd6337517864d8ae44a20b8225046b6d6fdf3
Fix vertically misaligned text in Javascript puzzles.

When I constructed my test canvas to measure the vertical extent of a
text string for ALIGN_VCENTRE, I forgot to ensure that the 'width'
variable was an integer, as a result of which the loop over canvas
pixels kept trying to use fractional array indices and returning
undefined :-)

[originally from svn r10196]
emcclib.js