chiark / gitweb /
Various patches from Ben H: a fix for an outdated comment, a couple
authorSimon Tatham <anakin@pobox.com>
Mon, 5 Sep 2005 17:21:05 +0000 (17:21 +0000)
committerSimon Tatham <anakin@pobox.com>
Mon, 5 Sep 2005 17:21:05 +0000 (17:21 +0000)
of spurious ps_printf() arguments removed, and an error check in the
`make install' target.

[originally from svn r6275]

Recipe
map.c
ps.c

diff --git a/Recipe b/Recipe
index e028c142032ff9bf17ab7933421f92d59b2cc393..5907519642ef60957bcac53a1182b6d387f87f07 100644 (file)
--- a/Recipe
+++ b/Recipe
@@ -190,6 +190,7 @@ install:
                 pattern rect solo mines samegame flip guess \
                 pegs dominosa untangle blackbox slant lightup \
                 map loopy inertia; do \
-               $(INSTALL_PROGRAM) -m 755 $$i $(DESTDIR)$(gamesdir)/$$i; \
+               $(INSTALL_PROGRAM) -m 755 $$i $(DESTDIR)$(gamesdir)/$$i \
+               || exit 1; \
        done
 !end
diff --git a/map.c b/map.c
index ef17efbbaffed76089c17512888a54536c9b1bc8..b06e6646e554feeeb009d6fe656817fac26686ae 100644 (file)
--- a/map.c
+++ b/map.c
@@ -2240,7 +2240,15 @@ static char *game_text_format(game_state *state)
 }
 
 struct game_ui {
-    int drag_colour;                   /* -1 means no drag active */
+    /*
+     * drag_colour:
+     * 
+     *  - -2 means no drag currently active.
+     *  - >=0 means we're dragging a solid colour.
+     *         - -1 means we're dragging a blank space, and drag_pencil
+     *           might or might not add some pencil-mark stipples to that.
+     */
+    int drag_colour;
     int drag_pencil;
     int dragx, dragy;
     int show_numbers;
diff --git a/ps.c b/ps.c
index a2fd6190b308c42a450d835159546dcb2444093b..9dc03e802dceb0c5553cdc0fbbed827223d39142 100644 (file)
--- a/ps.c
+++ b/ps.c
@@ -112,7 +112,7 @@ static void ps_draw_text(void *handle, int x, int y, int fonttype,
     ps_setcolour(ps, colour);
     ps_printf(ps, "/%s findfont %d scalefont setfont\n",
              fonttype == FONT_FIXED ? "Courier" : "Helvetica",
-             fontsize, x, y);
+             fontsize);
     if (align & ALIGN_VCENTRE) {
        ps_printf(ps, "newpath 0 0 moveto (X) true charpath flattenpath"
                  " pathbbox\n"