chiark / gitweb /
Render Filling presets as 'WxH', not 'HxW'.
authorJonas Kölker <jonaskoelker@yahoo.com>
Fri, 2 Oct 2015 16:23:44 +0000 (18:23 +0200)
committerSimon Tatham <anakin@pobox.com>
Sat, 3 Oct 2015 16:12:20 +0000 (17:12 +0100)
filling.c

index 31543228931b8f0f9e73cd892c9369a59d7c3708..6986cfff0fe1c35b3bcfdaf38a7a6798e1be91cd 100644 (file)
--- a/filling.c
+++ b/filling.c
@@ -91,7 +91,7 @@ static void printv(char *fmt, ...) {
  *****************************************************************************/
 
 struct game_params {
-    int h, w;
+    int w, h;
 };
 
 struct shared_state {
@@ -106,7 +106,9 @@ struct game_state {
     int completed, cheated;
 };
 
-static const struct game_params filling_defaults[3] = {{7, 9}, {9, 13}, {13, 17}};
+static const struct game_params filling_defaults[3] = {
+    {9, 7}, {13, 9}, {17, 13}
+};
 
 static game_params *default_params(void)
 {
@@ -124,7 +126,7 @@ static int game_fetch_preset(int i, char **name, game_params **params)
     if (i < 0 || i >= lenof(filling_defaults)) return FALSE;
     *params = snew(game_params);
     **params = filling_defaults[i]; /* struct copy */
-    sprintf(buf, "%dx%d", filling_defaults[i].h, filling_defaults[i].w);
+    sprintf(buf, "%dx%d", filling_defaults[i].w, filling_defaults[i].h);
     *name = dupstr(buf);
 
     return TRUE;