fixed bug with mis-using image config option '.tile_size' for screen output
authorHolger Schemel <info@artsoft.org>
Wed, 12 Aug 2015 15:05:11 +0000 (17:05 +0200)
committerHolger Schemel <info@artsoft.org>
Wed, 12 Aug 2015 15:05:11 +0000 (17:05 +0200)
src/conf_gfx.c
src/editor.c
src/main.h

index 28d85cf..f2ddadf 100644 (file)
@@ -5239,7 +5239,6 @@ struct ConfigInfo image_config[] =
   { "editor.element_border_input.xpos",                "10"                    },
   { "editor.element_border_input.ypos",                "7"                     },
   { "editor.element_border_input.border_size", "4"                     },
-  { "editor.element_border_input.tile_size",   "16"                    },
 
   { "editor.counter.down",                     "RocksDoor.png"         },
   { "editor.counter.down.x",                   "302"                   },
@@ -7631,6 +7630,8 @@ struct ConfigInfo image_config[] =
   { "editor.palette.element_right.y",          "258"                   },
   { "editor.palette.element_right.tile_size",  "16"                    },
 
+  { "editor.drawingarea.tile_size",            "16"                    },
+
   { "editor.settings.headline.x",              "272"                   },
   { "editor.settings.headline.y",              "16"                    },
   { "editor.settings.headline.align",          "center"                },
index dc7fdc8..828ebd7 100644 (file)
@@ -79,7 +79,7 @@
 #define IMG_BORDER_2                   IMG_EDITOR_ELEMENT_BORDER_INPUT
 #define ED_ELEMENT_BORDER              (graphic_info[IMG_BORDER_1].border_size)
 #define ED_DRAWINGAREA_BORDER_SIZE     (graphic_info[IMG_BORDER_2].border_size)
-#define ED_DRAWINGAREA_TILE_SIZE       (graphic_info[IMG_BORDER_2].tile_size)
+#define ED_DRAWINGAREA_TILE_SIZE       (editor.drawingarea.tile_size)
 
 /* values for checkbutton gadgets */
 #define ED_CHECKBUTTON_XSIZE        (graphic_info[IMG_EDITOR_CHECKBOX].width)
index 63eacc0..61bc328 100644 (file)
@@ -2327,6 +2327,11 @@ struct EditorPaletteInfo
   struct EditorPaletteElementInfo element_right;
 };
 
+struct EditorDrawingAreaInfo
+{
+  int tile_size;
+};
+
 struct EditorInfo
 {
   struct EditorSettingsInfo settings;
@@ -2334,6 +2339,7 @@ struct EditorInfo
   struct EditorButtonInfo button;
   struct EditorInputInfo input;
   struct EditorPaletteInfo palette;
+  struct EditorDrawingAreaInfo drawingarea;
 };
 
 struct ViewportInfo