mirror of
git://git.tartarus.org/simon/puzzles.git
synced 2025-04-20 23:51:29 -07:00

The previous code had multiple bugs. We had completely left out the draw_update after drawing each arrow; we omitted the usual precautionary clip() that constrains each arrow draw to the same rectangle we just saved in the blitter; we re-computed the coordinates of the opposite arrow at undraw time, instead of saving the coordinates we _actually_ used after computing them the first time. And we restored from the two blitters in the same order we saved them, instead of reverse order, which was harmless at the time (the drawing happened after both saves), but is generally bad practice, and needed to be fixed when the code was rearranged to fix the rest of these issues. I noticed these issues in passing, while hunting the diagonal-line bug fixed in the previous commit. These fixes by themselves would have prevented any persistent drawing artefact as a result of that bug (the clip() would have constrained the spurious diagonal line to the region saved by the blitter, so it would have been undrawn again afterwards); but it's better to have fixed the root cause as well!
This is the README accompanying the source code to Simon Tatham's puzzle collection. The collection's web site is at <https://www.chiark.greenend.org.uk/~sgtatham/puzzles/>. The puzzle collection is built using CMake <https://cmake.org/>. To compile in the simplest way (on any of Linux, Windows or Mac), run these commands in the source directory: cmake . cmake --build . The manual is provided in Windows Help format for the Windows build; in text format for anyone who needs it; and in HTML for the Mac OS X application and for the web site. It is generated from a Halibut source file (puzzles.but), which is the preferred form for modification. To generate the manual in other formats, rebuild it, or learn about Halibut, visit the Halibut website at <https://www.chiark.greenend.org.uk/~sgtatham/halibut/>.
Description
Languages
C
93.3%
JavaScript
1.4%
Objective-C
1.1%
CMake
1.1%
HTML
0.8%
Other
2.2%