rnd-20070414-1-src
authorHolger Schemel <info@artsoft.org>
Sat, 14 Apr 2007 18:16:57 +0000 (20:16 +0200)
committerHolger Schemel <info@artsoft.org>
Sat, 30 Aug 2014 08:55:36 +0000 (10:55 +0200)
* added additional configuration directives for setup screen draw offset
  menu.draw_xoffset.SETUP[XXX] and menu.draw_yoffset.SETUP[XXX] with XXX
  in GAME, EDITOR, GRAPHICS, SOUND, ARTWORK, INPUT, SHORTCUTS_1,
  SHORTCUTS_2, CHOOSE_ARTWORK, CHOOSE_OTHER (where "CHOOSE_ARTWORK" is
  used to define draw offset on custom artwork selection screens and
  "CHOOSE_OTHER" is used on all other list style selection screens, like
  choosing game speed or screen mode for fullscreen mode)

ChangeLog
src/conf_fnt.c
src/conf_gfx.c
src/conf_gfx.h
src/conf_var.c
src/conftime.h
src/files.c
src/main.h
src/screens.c

index b5f7dc49d1a0bba94c5ca5ab3d0c84c7de9d543b..c4343c1756e5127124452a0dd184cd45949d3dd6 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2007-04-14
+       * added additional configuration directives for setup screen draw offset
+         menu.draw_xoffset.SETUP[XXX] and menu.draw_yoffset.SETUP[XXX] with XXX
+         in GAME, EDITOR, GRAPHICS, SOUND, ARTWORK, INPUT, SHORTCUTS_1,
+         SHORTCUTS_2, CHOOSE_ARTWORK, CHOOSE_OTHER (where "CHOOSE_ARTWORK" is
+         used to define draw offset on custom artwork selection screens and
+         "CHOOSE_OTHER" is used on all other list style selection screens, like
+         choosing game speed or screen mode for fullscreen mode)
+
 2007-04-08
        * added support for accessing native Diamond Caves II level packages
        * fixed displaying of game panel values for Emerald Mine game engine
index a0f6dcffc997a14085ea47d5eb2c72abfea72db1..d46a18a4fbacb24eeb7ee4656389f5201b0c1f52 100644 (file)
@@ -79,6 +79,10 @@ font_to_graphic[] =
     FONT_TEXT_1,                               GFX_SPECIAL_ARG_LEVELS,
     IMG_FONT_TEXT_1_LEVELS
   },
+  {
+    FONT_TEXT_1,                               GFX_SPECIAL_ARG_SETUP,
+    IMG_FONT_TEXT_1_SETUP
+  },
   {
     FONT_TEXT_1,                               GFX_SPECIAL_ARG_PREVIEW,
     IMG_FONT_TEXT_1_PREVIEW
@@ -111,6 +115,10 @@ font_to_graphic[] =
     FONT_TEXT_2,                               GFX_SPECIAL_ARG_LEVELS,
     IMG_FONT_TEXT_2_LEVELS
   },
+  {
+    FONT_TEXT_2,                               GFX_SPECIAL_ARG_SETUP,
+    IMG_FONT_TEXT_2_SETUP
+  },
   {
     FONT_TEXT_2,                               GFX_SPECIAL_ARG_PREVIEW,
     IMG_FONT_TEXT_2_PREVIEW
@@ -131,6 +139,10 @@ font_to_graphic[] =
     FONT_TEXT_3,                               GFX_SPECIAL_ARG_LEVELS,
     IMG_FONT_TEXT_3_LEVELS
   },
+  {
+    FONT_TEXT_3,                               GFX_SPECIAL_ARG_SETUP,
+    IMG_FONT_TEXT_3_SETUP
+  },
   {
     FONT_TEXT_3,                               GFX_SPECIAL_ARG_PREVIEW,
     IMG_FONT_TEXT_3_PREVIEW
@@ -155,6 +167,10 @@ font_to_graphic[] =
     FONT_TEXT_4,                               GFX_SPECIAL_ARG_LEVELS,
     IMG_FONT_TEXT_4_LEVELS
   },
+  {
+    FONT_TEXT_4,                               GFX_SPECIAL_ARG_SETUP,
+    IMG_FONT_TEXT_4_SETUP
+  },
   {
     FONT_TEXT_4,                               GFX_SPECIAL_ARG_SCORES,
     IMG_FONT_TEXT_4_SCORES
index 640cb4e0d6321b21b3f9ec5d7a786008cb9fdbd3..1b1d0954528ccd111e23ccfdc0ea3fd9d1786136 100644 (file)
@@ -4675,6 +4675,8 @@ struct ConfigInfo image_config[] =
   { "font.text_1.LEVELS.y",                    "0"                     },
   { "font.text_1.LEVELS.width",                        "16"                    },
   { "font.text_1.LEVELS.height",               "32"                    },
+  { "font.text_1.SETUP",                       UNDEFINED_FILENAME      },
+  { "font.text_1.SETUP.clone_from",            "font.text_1.LEVELS"    },
   { "font.text_1.PREVIEW",                     "RocksFontEM.pcx"       },
   { "font.text_1.PREVIEW.x",                   "0"                     },
   { "font.text_1.PREVIEW.y",                   "160"                   },
@@ -4706,6 +4708,8 @@ struct ConfigInfo image_config[] =
   { "font.text_2.LEVELS.y",                    "160"                   },
   { "font.text_2.LEVELS.width",                        "16"                    },
   { "font.text_2.LEVELS.height",               "32"                    },
+  { "font.text_2.SETUP",                       UNDEFINED_FILENAME      },
+  { "font.text_2.SETUP.clone_from",            "font.text_2.LEVELS"    },
   { "font.text_2.PREVIEW",                     "RocksFontEM.pcx"       },
   { "font.text_2.PREVIEW.x",                   "0"                     },
   { "font.text_2.PREVIEW.y",                   "160"                   },
@@ -4731,6 +4735,8 @@ struct ConfigInfo image_config[] =
   { "font.text_3.LEVELS.y",                    "320"                   },
   { "font.text_3.LEVELS.width",                        "16"                    },
   { "font.text_3.LEVELS.height",               "32"                    },
+  { "font.text_3.SETUP",                       UNDEFINED_FILENAME      },
+  { "font.text_3.SETUP.clone_from",            "font.text_3.LEVELS"    },
   { "font.text_3.PREVIEW",                     "RocksFontEM.pcx"       },
   { "font.text_3.PREVIEW.x",                   "0"                     },
   { "font.text_3.PREVIEW.y",                   "160"                   },
@@ -4758,6 +4764,8 @@ struct ConfigInfo image_config[] =
   { "font.text_4.LEVELS.y",                    "480"                   },
   { "font.text_4.LEVELS.width",                        "16"                    },
   { "font.text_4.LEVELS.height",               "32"                    },
+  { "font.text_4.SETUP",                       UNDEFINED_FILENAME      },
+  { "font.text_4.SETUP.clone_from",            "font.text_4.LEVELS"    },
   { "font.text_4.SCORES",                      "RocksFontMedium.pcx"   },
   { "font.text_4.SCORES.x",                    "0"                     },
   { "font.text_4.SCORES.y",                    "480"                   },
@@ -5285,6 +5293,26 @@ struct ConfigInfo image_config[] =
   { "menu.draw_yoffset.INFO[LEVELSET]",                "0"                     },
   { "menu.draw_xoffset.SETUP",                 "0"                     },
   { "menu.draw_yoffset.SETUP",                 "0"                     },
+  { "menu.draw_xoffset.SETUP[GAME]",           "0"                     },
+  { "menu.draw_yoffset.SETUP[GAME]",           "0"                     },
+  { "menu.draw_xoffset.SETUP[EDITOR]",         "0"                     },
+  { "menu.draw_yoffset.SETUP[EDITOR]",         "0"                     },
+  { "menu.draw_xoffset.SETUP[GRAPHICS]",       "0"                     },
+  { "menu.draw_yoffset.SETUP[GRAPHICS]",       "0"                     },
+  { "menu.draw_xoffset.SETUP[SOUND]",          "0"                     },
+  { "menu.draw_yoffset.SETUP[SOUND]",          "0"                     },
+  { "menu.draw_xoffset.SETUP[ARTWORK]",                "0"                     },
+  { "menu.draw_yoffset.SETUP[ARTWORK]",                "0"                     },
+  { "menu.draw_xoffset.SETUP[INPUT]",          "0"                     },
+  { "menu.draw_yoffset.SETUP[INPUT]",          "0"                     },
+  { "menu.draw_xoffset.SETUP[SHORTCUTS_1]",    "0"                     },
+  { "menu.draw_yoffset.SETUP[SHORTCUTS_1]",    "0"                     },
+  { "menu.draw_xoffset.SETUP[SHORTCUTS_2]",    "0"                     },
+  { "menu.draw_yoffset.SETUP[SHORTCUTS_2]",    "0"                     },
+  { "menu.draw_xoffset.SETUP[CHOOSE_ARTWORK]", "0"                     },
+  { "menu.draw_yoffset.SETUP[CHOOSE_ARTWORK]", "0"                     },
+  { "menu.draw_xoffset.SETUP[CHOOSE_OTHER]",   "0"                     },
+  { "menu.draw_yoffset.SETUP[CHOOSE_OTHER]",   "0"                     },
 
   { "menu.scrollbar_xoffset",                  "0"                     },
 
@@ -5292,6 +5320,7 @@ struct ConfigInfo image_config[] =
   { "menu.list_size.LEVELS",                   "-1"                    },
   { "menu.list_size.SCORES",                   "-1"                    },
   { "menu.list_size.INFO",                     "-1"                    },
+  { "menu.list_size.SETUP",                    "-1"                    },
 
   { "main.button.name.x",                      "0"                     },
   { "main.button.name.y",                      "64"                    },
index e827cfbafa73c5ec68a3b7cb0beaad115d57ec01..33bfdf4e8ec8498acaedf93202ae233196b6dc28 100644 (file)
 #define IMG_FONT_TEXT_1                                        1660
 #define IMG_FONT_TEXT_1_MAIN                           1661
 #define IMG_FONT_TEXT_1_LEVELS                         1662
-#define IMG_FONT_TEXT_1_PREVIEW                                1663
-#define IMG_FONT_TEXT_1_SCORES                         1664
-#define IMG_FONT_TEXT_1_ACTIVE_SCORES                  1665
-#define IMG_FONT_TEXT_1_PANEL                          1666
-#define IMG_FONT_TEXT_1_DOOR                           1667
-#define IMG_FONT_TEXT_2                                        1668
-#define IMG_FONT_TEXT_2_MAIN                           1669
-#define IMG_FONT_TEXT_2_LEVELS                         1670
-#define IMG_FONT_TEXT_2_PREVIEW                                1671
-#define IMG_FONT_TEXT_2_SCORES                         1672
-#define IMG_FONT_TEXT_2_ACTIVE_SCORES                  1673
-#define IMG_FONT_TEXT_3                                        1674
-#define IMG_FONT_TEXT_3_LEVELS                         1675
-#define IMG_FONT_TEXT_3_PREVIEW                                1676
-#define IMG_FONT_TEXT_3_SCORES                         1677
-#define IMG_FONT_TEXT_3_ACTIVE_SCORES                  1678
-#define IMG_FONT_TEXT_4                                        1679
-#define IMG_FONT_TEXT_4_MAIN                           1680
-#define IMG_FONT_TEXT_4_LEVELS                         1681
-#define IMG_FONT_TEXT_4_SCORES                         1682
-#define IMG_FONT_TEXT_4_ACTIVE_SCORES                  1683
-#define IMG_FONT_ENVELOPE_1                            1684
-#define IMG_FONT_ENVELOPE_2                            1685
-#define IMG_FONT_ENVELOPE_3                            1686
-#define IMG_FONT_ENVELOPE_4                            1687
-#define IMG_FONT_INPUT_1                               1688
-#define IMG_FONT_INPUT_1_MAIN                          1689
-#define IMG_FONT_INPUT_1_ACTIVE                                1690
-#define IMG_FONT_INPUT_1_ACTIVE_MAIN                   1691
-#define IMG_FONT_INPUT_1_ACTIVE_SETUP                  1692
-#define IMG_FONT_INPUT_2                               1693
-#define IMG_FONT_INPUT_2_ACTIVE                                1694
-#define IMG_FONT_OPTION_OFF                            1695
-#define IMG_FONT_OPTION_ON                             1696
-#define IMG_FONT_VALUE_1                               1697
-#define IMG_FONT_VALUE_2                               1698
-#define IMG_FONT_VALUE_OLD                             1699
-#define IMG_FONT_LEVEL_NUMBER                          1700
-#define IMG_FONT_LEVEL_NUMBER_ACTIVE                   1701
-#define IMG_FONT_TAPE_RECORDER                         1702
-#define IMG_FONT_GAME_INFO                             1703
-#define IMG_FONT_INFO_ELEMENTS                         1704
-#define IMG_FONT_INFO_LEVELSET                         1705
-#define IMG_GLOBAL_BORDER                              1706
-#define IMG_GLOBAL_DOOR                                        1707
-#define IMG_EDITOR_ELEMENT_BORDER                      1708
-#define IMG_EDITOR_ELEMENT_BORDER_INPUT                        1709
-#define IMG_EDITOR_CASCADE_LIST                                1710
-#define IMG_EDITOR_CASCADE_LIST_ACTIVE                 1711
-#define IMG_BACKGROUND                                 1712
-#define IMG_BACKGROUND_TITLE_INITIAL                   1713
-#define IMG_BACKGROUND_TITLE                           1714
-#define IMG_BACKGROUND_MAIN                            1715
-#define IMG_BACKGROUND_LEVELS                          1716
-#define IMG_BACKGROUND_SCORES                          1717
-#define IMG_BACKGROUND_EDITOR                          1718
-#define IMG_BACKGROUND_INFO                            1719
-#define IMG_BACKGROUND_INFO_ELEMENTS                   1720
-#define IMG_BACKGROUND_INFO_MUSIC                      1721
-#define IMG_BACKGROUND_INFO_CREDITS                    1722
-#define IMG_BACKGROUND_INFO_PROGRAM                    1723
-#define IMG_BACKGROUND_INFO_VERSION                    1724
-#define IMG_BACKGROUND_INFO_LEVELSET                   1725
-#define IMG_BACKGROUND_SETUP                           1726
-#define IMG_BACKGROUND_DOOR                            1727
-#define IMG_BACKGROUND_TITLESCREEN_INITIAL_1           1728
-#define IMG_BACKGROUND_TITLESCREEN_INITIAL_2           1729
-#define IMG_BACKGROUND_TITLESCREEN_INITIAL_3           1730
-#define IMG_BACKGROUND_TITLESCREEN_INITIAL_4           1731
-#define IMG_BACKGROUND_TITLESCREEN_INITIAL_5           1732
-#define IMG_BACKGROUND_TITLESCREEN_1                   1733
-#define IMG_BACKGROUND_TITLESCREEN_2                   1734
-#define IMG_BACKGROUND_TITLESCREEN_3                   1735
-#define IMG_BACKGROUND_TITLESCREEN_4                   1736
-#define IMG_BACKGROUND_TITLESCREEN_5                   1737
-#define IMG_BACKGROUND_TITLEMESSAGE_INITIAL_1          1738
-#define IMG_BACKGROUND_TITLEMESSAGE_INITIAL_2          1739
-#define IMG_BACKGROUND_TITLEMESSAGE_INITIAL_3          1740
-#define IMG_BACKGROUND_TITLEMESSAGE_INITIAL_4          1741
-#define IMG_BACKGROUND_TITLEMESSAGE_INITIAL_5          1742
-#define IMG_BACKGROUND_TITLEMESSAGE_1                  1743
-#define IMG_BACKGROUND_TITLEMESSAGE_2                  1744
-#define IMG_BACKGROUND_TITLEMESSAGE_3                  1745
-#define IMG_BACKGROUND_TITLEMESSAGE_4                  1746
-#define IMG_BACKGROUND_TITLEMESSAGE_5                  1747
-#define IMG_BACKGROUND_ENVELOPE_1                      1748
-#define IMG_BACKGROUND_ENVELOPE_2                      1749
-#define IMG_BACKGROUND_ENVELOPE_3                      1750
-#define IMG_BACKGROUND_ENVELOPE_4                      1751
-#define IMG_TITLESCREEN_INITIAL_1                      1752
-#define IMG_TITLESCREEN_INITIAL_2                      1753
-#define IMG_TITLESCREEN_INITIAL_3                      1754
-#define IMG_TITLESCREEN_INITIAL_4                      1755
-#define IMG_TITLESCREEN_INITIAL_5                      1756
-#define IMG_TITLESCREEN_1                              1757
-#define IMG_TITLESCREEN_2                              1758
-#define IMG_TITLESCREEN_3                              1759
-#define IMG_TITLESCREEN_4                              1760
-#define IMG_TITLESCREEN_5                              1761
+#define IMG_FONT_TEXT_1_SETUP                          1663
+#define IMG_FONT_TEXT_1_PREVIEW                                1664
+#define IMG_FONT_TEXT_1_SCORES                         1665
+#define IMG_FONT_TEXT_1_ACTIVE_SCORES                  1666
+#define IMG_FONT_TEXT_1_PANEL                          1667
+#define IMG_FONT_TEXT_1_DOOR                           1668
+#define IMG_FONT_TEXT_2                                        1669
+#define IMG_FONT_TEXT_2_MAIN                           1670
+#define IMG_FONT_TEXT_2_LEVELS                         1671
+#define IMG_FONT_TEXT_2_SETUP                          1672
+#define IMG_FONT_TEXT_2_PREVIEW                                1673
+#define IMG_FONT_TEXT_2_SCORES                         1674
+#define IMG_FONT_TEXT_2_ACTIVE_SCORES                  1675
+#define IMG_FONT_TEXT_3                                        1676
+#define IMG_FONT_TEXT_3_LEVELS                         1677
+#define IMG_FONT_TEXT_3_SETUP                          1678
+#define IMG_FONT_TEXT_3_PREVIEW                                1679
+#define IMG_FONT_TEXT_3_SCORES                         1680
+#define IMG_FONT_TEXT_3_ACTIVE_SCORES                  1681
+#define IMG_FONT_TEXT_4                                        1682
+#define IMG_FONT_TEXT_4_MAIN                           1683
+#define IMG_FONT_TEXT_4_LEVELS                         1684
+#define IMG_FONT_TEXT_4_SETUP                          1685
+#define IMG_FONT_TEXT_4_SCORES                         1686
+#define IMG_FONT_TEXT_4_ACTIVE_SCORES                  1687
+#define IMG_FONT_ENVELOPE_1                            1688
+#define IMG_FONT_ENVELOPE_2                            1689
+#define IMG_FONT_ENVELOPE_3                            1690
+#define IMG_FONT_ENVELOPE_4                            1691
+#define IMG_FONT_INPUT_1                               1692
+#define IMG_FONT_INPUT_1_MAIN                          1693
+#define IMG_FONT_INPUT_1_ACTIVE                                1694
+#define IMG_FONT_INPUT_1_ACTIVE_MAIN                   1695
+#define IMG_FONT_INPUT_1_ACTIVE_SETUP                  1696
+#define IMG_FONT_INPUT_2                               1697
+#define IMG_FONT_INPUT_2_ACTIVE                                1698
+#define IMG_FONT_OPTION_OFF                            1699
+#define IMG_FONT_OPTION_ON                             1700
+#define IMG_FONT_VALUE_1                               1701
+#define IMG_FONT_VALUE_2                               1702
+#define IMG_FONT_VALUE_OLD                             1703
+#define IMG_FONT_LEVEL_NUMBER                          1704
+#define IMG_FONT_LEVEL_NUMBER_ACTIVE                   1705
+#define IMG_FONT_TAPE_RECORDER                         1706
+#define IMG_FONT_GAME_INFO                             1707
+#define IMG_FONT_INFO_ELEMENTS                         1708
+#define IMG_FONT_INFO_LEVELSET                         1709
+#define IMG_GLOBAL_BORDER                              1710
+#define IMG_GLOBAL_DOOR                                        1711
+#define IMG_EDITOR_ELEMENT_BORDER                      1712
+#define IMG_EDITOR_ELEMENT_BORDER_INPUT                        1713
+#define IMG_EDITOR_CASCADE_LIST                                1714
+#define IMG_EDITOR_CASCADE_LIST_ACTIVE                 1715
+#define IMG_BACKGROUND                                 1716
+#define IMG_BACKGROUND_TITLE_INITIAL                   1717
+#define IMG_BACKGROUND_TITLE                           1718
+#define IMG_BACKGROUND_MAIN                            1719
+#define IMG_BACKGROUND_LEVELS                          1720
+#define IMG_BACKGROUND_SCORES                          1721
+#define IMG_BACKGROUND_EDITOR                          1722
+#define IMG_BACKGROUND_INFO                            1723
+#define IMG_BACKGROUND_INFO_ELEMENTS                   1724
+#define IMG_BACKGROUND_INFO_MUSIC                      1725
+#define IMG_BACKGROUND_INFO_CREDITS                    1726
+#define IMG_BACKGROUND_INFO_PROGRAM                    1727
+#define IMG_BACKGROUND_INFO_VERSION                    1728
+#define IMG_BACKGROUND_INFO_LEVELSET                   1729
+#define IMG_BACKGROUND_SETUP                           1730
+#define IMG_BACKGROUND_DOOR                            1731
+#define IMG_BACKGROUND_TITLESCREEN_INITIAL_1           1732
+#define IMG_BACKGROUND_TITLESCREEN_INITIAL_2           1733
+#define IMG_BACKGROUND_TITLESCREEN_INITIAL_3           1734
+#define IMG_BACKGROUND_TITLESCREEN_INITIAL_4           1735
+#define IMG_BACKGROUND_TITLESCREEN_INITIAL_5           1736
+#define IMG_BACKGROUND_TITLESCREEN_1                   1737
+#define IMG_BACKGROUND_TITLESCREEN_2                   1738
+#define IMG_BACKGROUND_TITLESCREEN_3                   1739
+#define IMG_BACKGROUND_TITLESCREEN_4                   1740
+#define IMG_BACKGROUND_TITLESCREEN_5                   1741
+#define IMG_BACKGROUND_TITLEMESSAGE_INITIAL_1          1742
+#define IMG_BACKGROUND_TITLEMESSAGE_INITIAL_2          1743
+#define IMG_BACKGROUND_TITLEMESSAGE_INITIAL_3          1744
+#define IMG_BACKGROUND_TITLEMESSAGE_INITIAL_4          1745
+#define IMG_BACKGROUND_TITLEMESSAGE_INITIAL_5          1746
+#define IMG_BACKGROUND_TITLEMESSAGE_1                  1747
+#define IMG_BACKGROUND_TITLEMESSAGE_2                  1748
+#define IMG_BACKGROUND_TITLEMESSAGE_3                  1749
+#define IMG_BACKGROUND_TITLEMESSAGE_4                  1750
+#define IMG_BACKGROUND_TITLEMESSAGE_5                  1751
+#define IMG_BACKGROUND_ENVELOPE_1                      1752
+#define IMG_BACKGROUND_ENVELOPE_2                      1753
+#define IMG_BACKGROUND_ENVELOPE_3                      1754
+#define IMG_BACKGROUND_ENVELOPE_4                      1755
+#define IMG_TITLESCREEN_INITIAL_1                      1756
+#define IMG_TITLESCREEN_INITIAL_2                      1757
+#define IMG_TITLESCREEN_INITIAL_3                      1758
+#define IMG_TITLESCREEN_INITIAL_4                      1759
+#define IMG_TITLESCREEN_INITIAL_5                      1760
+#define IMG_TITLESCREEN_1                              1761
+#define IMG_TITLESCREEN_2                              1762
+#define IMG_TITLESCREEN_3                              1763
+#define IMG_TITLESCREEN_4                              1764
+#define IMG_TITLESCREEN_5                              1765
 
-#define NUM_IMAGE_FILES                                        1762
+#define NUM_IMAGE_FILES                                        1766
 
 #endif /* CONF_GFX_H */
index 3cf2fae60b1cd9602aa5d4938155814415aa47ea..fbca9addd1600c9f8a7978c4e28bbeb40928bacb 100644 (file)
@@ -1208,6 +1208,86 @@ struct TokenIntPtrInfo image_config_vars[] =
     "menu.draw_yoffset.SETUP",
     &menu.draw_yoffset[GFX_SPECIAL_ARG_SETUP]
   },
+  {
+    "menu.draw_xoffset.SETUP[GAME]",
+    &menu.draw_xoffset_setup[GFX_SPECIAL_ARG_SETUP_GAME]
+  },
+  {
+    "menu.draw_yoffset.SETUP[GAME]",
+    &menu.draw_yoffset_setup[GFX_SPECIAL_ARG_SETUP_GAME]
+  },
+  {
+    "menu.draw_xoffset.SETUP[EDITOR]",
+    &menu.draw_xoffset_setup[GFX_SPECIAL_ARG_SETUP_EDITOR]
+  },
+  {
+    "menu.draw_yoffset.SETUP[EDITOR]",
+    &menu.draw_yoffset_setup[GFX_SPECIAL_ARG_SETUP_EDITOR]
+  },
+  {
+    "menu.draw_xoffset.SETUP[GRAPHICS]",
+    &menu.draw_xoffset_setup[GFX_SPECIAL_ARG_SETUP_GRAPHICS]
+  },
+  {
+    "menu.draw_yoffset.SETUP[GRAPHICS]",
+    &menu.draw_yoffset_setup[GFX_SPECIAL_ARG_SETUP_GRAPHICS]
+  },
+  {
+    "menu.draw_xoffset.SETUP[SOUND]",
+    &menu.draw_xoffset_setup[GFX_SPECIAL_ARG_SETUP_SOUND]
+  },
+  {
+    "menu.draw_yoffset.SETUP[SOUND]",
+    &menu.draw_yoffset_setup[GFX_SPECIAL_ARG_SETUP_SOUND]
+  },
+  {
+    "menu.draw_xoffset.SETUP[ARTWORK]",
+    &menu.draw_xoffset_setup[GFX_SPECIAL_ARG_SETUP_ARTWORK]
+  },
+  {
+    "menu.draw_yoffset.SETUP[ARTWORK]",
+    &menu.draw_yoffset_setup[GFX_SPECIAL_ARG_SETUP_ARTWORK]
+  },
+  {
+    "menu.draw_xoffset.SETUP[INPUT]",
+    &menu.draw_xoffset_setup[GFX_SPECIAL_ARG_SETUP_INPUT]
+  },
+  {
+    "menu.draw_yoffset.SETUP[INPUT]",
+    &menu.draw_yoffset_setup[GFX_SPECIAL_ARG_SETUP_INPUT]
+  },
+  {
+    "menu.draw_xoffset.SETUP[SHORTCUTS_1]",
+    &menu.draw_xoffset_setup[GFX_SPECIAL_ARG_SETUP_SHORTCUTS_1]
+  },
+  {
+    "menu.draw_yoffset.SETUP[SHORTCUTS_1]",
+    &menu.draw_yoffset_setup[GFX_SPECIAL_ARG_SETUP_SHORTCUTS_1]
+  },
+  {
+    "menu.draw_xoffset.SETUP[SHORTCUTS_2]",
+    &menu.draw_xoffset_setup[GFX_SPECIAL_ARG_SETUP_SHORTCUTS_2]
+  },
+  {
+    "menu.draw_yoffset.SETUP[SHORTCUTS_2]",
+    &menu.draw_yoffset_setup[GFX_SPECIAL_ARG_SETUP_SHORTCUTS_2]
+  },
+  {
+    "menu.draw_xoffset.SETUP[CHOOSE_ARTWORK]",
+    &menu.draw_xoffset_setup[GFX_SPECIAL_ARG_SETUP_CHOOSE_ARTWORK]
+  },
+  {
+    "menu.draw_yoffset.SETUP[CHOOSE_ARTWORK]",
+    &menu.draw_yoffset_setup[GFX_SPECIAL_ARG_SETUP_CHOOSE_ARTWORK]
+  },
+  {
+    "menu.draw_xoffset.SETUP[CHOOSE_OTHER]",
+    &menu.draw_xoffset_setup[GFX_SPECIAL_ARG_SETUP_CHOOSE_OTHER]
+  },
+  {
+    "menu.draw_yoffset.SETUP[CHOOSE_OTHER]",
+    &menu.draw_yoffset_setup[GFX_SPECIAL_ARG_SETUP_CHOOSE_OTHER]
+  },
   {
     "menu.scrollbar_xoffset",
     &menu.scrollbar_xoffset
@@ -1228,6 +1308,10 @@ struct TokenIntPtrInfo image_config_vars[] =
     "menu.list_size.INFO",
     &menu.list_size[GFX_SPECIAL_ARG_INFO]
   },
+  {
+    "menu.list_size.SETUP",
+    &menu.list_size[GFX_SPECIAL_ARG_SETUP]
+  },
   {
     "main.button.name.x",
     &menu.main.button.name.x
index a633a1bd13fbfc9c3e928df3d1e24c12ccac84c1..15d0413d731f34b4a4f918220e4f7588e5b5ce5b 100644 (file)
@@ -1 +1 @@
-#define COMPILE_DATE_STRING "2007-04-13 22:02"
+#define COMPILE_DATE_STRING "2007-04-14 20:11"
index 01548e646f2af752fda3f7b9ac4f2ca895f07648..57368d34ceb73de23b0a82aa4ae49de96e23764b 100644 (file)
@@ -8764,7 +8764,7 @@ static void LoadSpecialMenuDesignSettingsFromFilename(char *filename)
   }
 
   /* special case: initialize with default values that may be overwritten */
-  /* (eg, init "menu.draw_xoffset.INFO[MUSIC]" from "menu.draw_xoffset.INFO") */
+  /* (eg, init "menu.draw_xoffset.INFO[XXX]" from "menu.draw_xoffset.INFO") */
   for (i = 0; i < NUM_SPECIAL_GFX_INFO_ARGS; i++)
   {
     char *value_1 = getHashEntry(setup_file_hash, "menu.draw_xoffset.INFO");
@@ -8776,6 +8776,19 @@ static void LoadSpecialMenuDesignSettingsFromFilename(char *filename)
       menu.draw_yoffset_info[i] = get_integer_from_string(value_2);
   }
 
+  /* special case: initialize with default values that may be overwritten */
+  /* (eg, init "menu.draw_xoffset.SETUP[XXX]" from "menu.draw_xoffset.SETUP") */
+  for (i = 0; i < NUM_SPECIAL_GFX_SETUP_ARGS; i++)
+  {
+    char *value_1 = getHashEntry(setup_file_hash, "menu.draw_xoffset.SETUP");
+    char *value_2 = getHashEntry(setup_file_hash, "menu.draw_yoffset.SETUP");
+
+    if (value_1 != NULL)
+      menu.draw_xoffset_setup[i] = get_integer_from_string(value_1);
+    if (value_2 != NULL)
+      menu.draw_yoffset_setup[i] = get_integer_from_string(value_2);
+  }
+
   /* special case: initialize with default values that may be overwritten */
   /* (eg, init "menu.enter_screen.SCORES.xyz" from "menu.enter_screen.xyz") */
   for (i = 0; i < NUM_SPECIAL_GFX_ARGS; i++)
@@ -8859,18 +8872,9 @@ static void LoadSpecialMenuDesignSettingsFromFilename(char *filename)
   freeSetupFileHash(setup_file_hash);
 }
 
-void LoadSpecialMenuDesignSettings()
+static void LoadSpecialMenuDesignSettings_SpecialPreProcessing()
 {
-  char *filename_base = UNDEFINED_FILENAME, *filename_local;
-  int i, j;
-
-  /* always start with reliable default values from static default config */
-  for (i = 0; image_config_vars[i].token != NULL; i++)
-    for (j = 0; image_config[j].token != NULL; j++)
-      if (strEqual(image_config_vars[i].token, image_config[j].token))
-       *image_config_vars[i].value =
-         get_token_parameter_value(image_config_vars[i].token,
-                                   image_config[j].value);
+  int i;
 
   /* the following initializes hierarchical values from static configuration */
 
@@ -8900,6 +8904,29 @@ void LoadSpecialMenuDesignSettings()
     menu.enter_screen[i] = menu.enter_screen[GFX_SPECIAL_ARG_DEFAULT];
     menu.leave_screen[i] = menu.leave_screen[GFX_SPECIAL_ARG_DEFAULT];
   }
+}
+
+static void LoadSpecialMenuDesignSettings_SpecialPostProcessing()
+{
+  /* special case: initialize later added SETUP list size from LEVELS value */
+  if (menu.list_size[GAME_MODE_SETUP] == -1)
+    menu.list_size[GAME_MODE_SETUP] = menu.list_size[GAME_MODE_LEVELS];
+}
+
+void LoadSpecialMenuDesignSettings()
+{
+  char *filename_base = UNDEFINED_FILENAME, *filename_local;
+  int i, j;
+
+  /* always start with reliable default values from static default config */
+  for (i = 0; image_config_vars[i].token != NULL; i++)
+    for (j = 0; image_config[j].token != NULL; j++)
+      if (strEqual(image_config_vars[i].token, image_config[j].token))
+       *image_config_vars[i].value =
+         get_token_parameter_value(image_config_vars[i].token,
+                                   image_config[j].value);
+
+  LoadSpecialMenuDesignSettings_SpecialPreProcessing();
 
   if (!SETUP_OVERRIDE_ARTWORK(setup, ARTWORK_TYPE_GRAPHICS))
   {
@@ -8914,6 +8941,8 @@ void LoadSpecialMenuDesignSettings()
 
   if (filename_local != NULL && !strEqual(filename_base, filename_local))
     LoadSpecialMenuDesignSettingsFromFilename(filename_local);
+
+  LoadSpecialMenuDesignSettings_SpecialPostProcessing();
 }
 
 void LoadUserDefinedEditorElementList(int **elements, int *num_elements)
index 2f323f279a3f05d55b2581c18a276339dfb4c0c9..f2ce9d601fc88f91647af319ff89c0fa2b5dd61d 100644 (file)
 
 #define NUM_SPECIAL_GFX_INFO_ARGS      8
 
+/* these additional definitions are currently only used for draw offsets */
+#define GFX_SPECIAL_ARG_SETUP_MAIN             0
+#define GFX_SPECIAL_ARG_SETUP_GAME             1
+#define GFX_SPECIAL_ARG_SETUP_EDITOR           2
+#define GFX_SPECIAL_ARG_SETUP_GRAPHICS         3
+#define GFX_SPECIAL_ARG_SETUP_SOUND            4
+#define GFX_SPECIAL_ARG_SETUP_ARTWORK          5
+#define GFX_SPECIAL_ARG_SETUP_INPUT            6
+#define GFX_SPECIAL_ARG_SETUP_SHORTCUTS_1      7
+#define GFX_SPECIAL_ARG_SETUP_SHORTCUTS_2      8
+#define GFX_SPECIAL_ARG_SETUP_CHOOSE_ARTWORK   9
+#define GFX_SPECIAL_ARG_SETUP_CHOOSE_OTHER     10
+
+#define NUM_SPECIAL_GFX_SETUP_ARGS             11
+
 
 /* values for image configuration suffixes */
 #define GFX_ARG_X                      0
@@ -2104,6 +2119,8 @@ struct MenuInfo
   int draw_yoffset[NUM_SPECIAL_GFX_ARGS];
   int draw_xoffset_info[NUM_SPECIAL_GFX_INFO_ARGS];
   int draw_yoffset_info[NUM_SPECIAL_GFX_INFO_ARGS];
+  int draw_xoffset_setup[NUM_SPECIAL_GFX_SETUP_ARGS];
+  int draw_yoffset_setup[NUM_SPECIAL_GFX_SETUP_ARGS];
 
   int scrollbar_xoffset;
 
index 97b32f42ef5891a96c93fb4c63a2e049e7cbfcae..d16509e62bb5a26f62e82cdaca823e00c4e5620b 100644 (file)
 #include "init.h"
 #include "config.h"
 
-/* screens in the setup menu */
-#define SETUP_MODE_MAIN                        0
-#define SETUP_MODE_GAME                        1
-#define SETUP_MODE_CHOOSE_GAME_SPEED   2
-#define SETUP_MODE_EDITOR              3
-#define SETUP_MODE_INPUT               4
-#define SETUP_MODE_SHORTCUT_1          5
-#define SETUP_MODE_SHORTCUT_2          6
-#define SETUP_MODE_GRAPHICS            7
-#define SETUP_MODE_CHOOSE_SCREEN_MODE  8
-#define SETUP_MODE_CHOOSE_SCROLL_DELAY 9
-#define SETUP_MODE_SOUND               10
-#define SETUP_MODE_ARTWORK             11
-#define SETUP_MODE_CHOOSE_GRAPHICS     12
-#define SETUP_MODE_CHOOSE_SOUNDS       13
-#define SETUP_MODE_CHOOSE_MUSIC                14
-
-#define MAX_SETUP_MODES                        15
-
-/* for input setup functions */
-#define SETUPINPUT_SCREEN_POS_START    0
-#define SETUPINPUT_SCREEN_POS_END      (SCR_FIELDY - 4)
-#define SETUPINPUT_SCREEN_POS_EMPTY1   (SETUPINPUT_SCREEN_POS_START + 3)
-#define SETUPINPUT_SCREEN_POS_EMPTY2   (SETUPINPUT_SCREEN_POS_END - 1)
-
 /* screens on the info screen */
 #define INFO_MODE_MAIN                 0
 #define INFO_MODE_TITLE                        1
 
 #define MAX_INFO_MODES                 8
 
+/* screens on the setup screen */
+#define SETUP_MODE_MAIN                        0
+#define SETUP_MODE_GAME                        1
+#define SETUP_MODE_EDITOR              2
+#define SETUP_MODE_GRAPHICS            3
+#define SETUP_MODE_SOUND               4
+#define SETUP_MODE_ARTWORK             5
+#define SETUP_MODE_INPUT               6
+#define SETUP_MODE_SHORTCUTS_1         7
+#define SETUP_MODE_SHORTCUTS_2         8
+
+/* sub-screens on the setup screen (generic) */
+#define SETUP_MODE_CHOOSE_ARTWORK      9
+#define SETUP_MODE_CHOOSE_OTHER                10
+
+/* sub-screens on the setup screen (specific) */
+#define SETUP_MODE_CHOOSE_GAME_SPEED   11
+#define SETUP_MODE_CHOOSE_SCREEN_MODE  12
+#define SETUP_MODE_CHOOSE_SCROLL_DELAY 13
+#define SETUP_MODE_CHOOSE_GRAPHICS     14
+#define SETUP_MODE_CHOOSE_SOUNDS       15
+#define SETUP_MODE_CHOOSE_MUSIC                16
+
+#define MAX_SETUP_MODES                        17
+
+/* for input setup functions */
+#define SETUPINPUT_SCREEN_POS_START    0
+#define SETUPINPUT_SCREEN_POS_END      (SCR_FIELDY - 4)
+#define SETUPINPUT_SCREEN_POS_EMPTY1   (SETUPINPUT_SCREEN_POS_START + 3)
+#define SETUPINPUT_SCREEN_POS_EMPTY2   (SETUPINPUT_SCREEN_POS_END - 1)
+
 /* for various menu stuff  */
 #define MENU_SCREEN_START_XPOS         1
 #define MENU_SCREEN_START_YPOS         2
@@ -165,8 +171,8 @@ static void MapScreenTreeGadgets(TreeInfo *);
 
 static struct GadgetInfo *screen_gadget[NUM_SCREEN_GADGETS];
 
-static int setup_mode = SETUP_MODE_MAIN;
 static int info_mode = INFO_MODE_MAIN;
+static int setup_mode = SETUP_MODE_MAIN;
 
 static TreeInfo *screen_modes = NULL;
 static TreeInfo *screen_mode_current = NULL;
@@ -232,10 +238,18 @@ static struct
                                 (s) == GAME_MODE_PSEUDO_TYPENAME ?     \
                                 GAME_MODE_MAIN : GAME_MODE_DEFAULT)
 
+/* (there are no draw offset definitions needed for INFO_MODE_TITLE) */
 #define DRAW_MODE_INFO(i)      ((i) >= INFO_MODE_ELEMENTS &&           \
                                 (i) <= INFO_MODE_LEVELSET ? (i) :      \
                                 INFO_MODE_MAIN)
 
+#define DRAW_MODE_SETUP(i)     ((i) >= SETUP_MODE_MAIN &&              \
+                                (i) <= SETUP_MODE_SHORTCUTS_2 ? (i) :  \
+                                (i) >= SETUP_MODE_CHOOSE_GRAPHICS &&   \
+                                (i) <= SETUP_MODE_CHOOSE_MUSIC ?       \
+                                SETUP_MODE_CHOOSE_ARTWORK :            \
+                                SETUP_MODE_CHOOSE_OTHER)
+
 #define DRAW_XOFFSET_INFO(i)   (DRAW_MODE_INFO(i) == INFO_MODE_MAIN ?  \
                                 menu.draw_xoffset[GAME_MODE_INFO] :    \
                                 menu.draw_xoffset_info[DRAW_MODE_INFO(i)])
@@ -243,11 +257,22 @@ static struct
                                 menu.draw_yoffset[GAME_MODE_INFO] :    \
                                 menu.draw_yoffset_info[DRAW_MODE_INFO(i)])
 
+#define DRAW_XOFFSET_SETUP(i)  (DRAW_MODE_SETUP(i) == SETUP_MODE_MAIN ? \
+                                menu.draw_xoffset[GAME_MODE_SETUP] :   \
+                                menu.draw_xoffset_setup[DRAW_MODE_SETUP(i)])
+#define DRAW_YOFFSET_SETUP(i)  (DRAW_MODE_SETUP(i) == SETUP_MODE_MAIN ? \
+                                menu.draw_yoffset[GAME_MODE_SETUP] :   \
+                                menu.draw_yoffset_setup[DRAW_MODE_SETUP(i)])
+
 #define DRAW_XOFFSET(s)                ((s) == GAME_MODE_INFO ?                \
                                 DRAW_XOFFSET_INFO(info_mode) :         \
+                                (s) == GAME_MODE_SETUP ?               \
+                                DRAW_XOFFSET_SETUP(setup_mode) :       \
                                 menu.draw_xoffset[DRAW_MODE(s)])
 #define DRAW_YOFFSET(s)                ((s) == GAME_MODE_INFO ?                \
                                 DRAW_YOFFSET_INFO(info_mode) :         \
+                                (s) == GAME_MODE_SETUP ?               \
+                                DRAW_YOFFSET_SETUP(setup_mode) :       \
                                 menu.draw_yoffset[DRAW_MODE(s)])
 
 #define mSX                    (SX + DRAW_XOFFSET(game_status))
@@ -1031,8 +1056,10 @@ static void drawChooseTreeCursor(int ypos, boolean active)
 {
   int last_game_status = game_status;  /* save current game status */
 
+#if 0
   /* force LEVELS draw offset on artwork setup screen */
   game_status = GAME_MODE_LEVELS;
+#endif
 
   drawCursorExt(0, ypos, active, -1);
 
@@ -2129,6 +2156,7 @@ void HandleMainMenu(int mx, int my, int dx, int dy, int button)
        if (leveldir_first)
        {
          game_status = GAME_MODE_LEVELS;
+
          SaveLevelSetup_LastSeries();
          SaveLevelSetup_SeriesInfo();
 
@@ -3796,8 +3824,10 @@ static void drawChooseTreeList(int first_entry, int num_page_entries,
 
   DrawTextSCentered(mSY - SY + yoffset, FONT_TITLE_1, title_string);
 
+#if 0
   /* force LEVELS font on artwork setup screen */
   game_status = GAME_MODE_LEVELS;
+#endif
 
 #if 1
   /* clear tree list area, but not title or scrollbar */
@@ -3891,8 +3921,10 @@ static void HandleChooseTree(int mx, int my, int dx, int dy, int button,
   int last_game_status = game_status;  /* save current game status */
   boolean position_set_by_scrollbar = (dx == 999);
 
+#if 0
   /* force LEVELS draw offset on choose level and artwork setup screen */
   game_status = GAME_MODE_LEVELS;
+#endif
 
   if (num_entries <= NUM_MENU_ENTRIES_ON_SCREEN)
     num_page_entries = num_entries;
@@ -3971,8 +4003,10 @@ static void HandleChooseTree(int mx, int my, int dx, int dy, int button,
   {
     int last_game_status = game_status;        /* save current game status */
 
+#if 0
     /* force LEVELS draw offset on artwork setup screen */
     game_status = GAME_MODE_LEVELS;
+#endif
 
     x = (mx - mSX) / 32;
     y = (my - mSY) / 32 - MENU_SCREEN_START_YPOS;
@@ -4623,23 +4657,23 @@ static void execSetupInput()
   DrawSetupScreen();
 }
 
-static void execSetupShortcut1()
+static void execSetupShortcuts1()
 {
 #if 0
   FadeSetEnterMenu();
 #endif
 
-  setup_mode = SETUP_MODE_SHORTCUT_1;
+  setup_mode = SETUP_MODE_SHORTCUTS_1;
   DrawSetupScreen();
 }
 
-static void execSetupShortcut2()
+static void execSetupShortcuts2()
 {
 #if 0
   FadeSetEnterMenu();
 #endif
 
-  setup_mode = SETUP_MODE_SHORTCUT_2;
+  setup_mode = SETUP_MODE_SHORTCUTS_2;
   DrawSetupScreen();
 }
 
@@ -4671,8 +4705,8 @@ static struct TokenInfo setup_info_main[] =
   { TYPE_ENTER_MENU,   execSetupSound,         "Sound & Music"         },
   { TYPE_ENTER_MENU,   execSetupArtwork,       "Custom Artwork"        },
   { TYPE_ENTER_MENU,   execSetupInput,         "Input Devices"         },
-  { TYPE_ENTER_MENU,   execSetupShortcut1,     "Key Shortcuts 1"       },
-  { TYPE_ENTER_MENU,   execSetupShortcut2,     "Key Shortcuts 2"       },
+  { TYPE_ENTER_MENU,   execSetupShortcuts1,    "Key Shortcuts 1"       },
+  { TYPE_ENTER_MENU,   execSetupShortcuts2,    "Key Shortcuts 2"       },
   { TYPE_EMPTY,                NULL,                   ""                      },
   { TYPE_LEAVE_MENU,   execExitSetup,          "Exit"                  },
   { TYPE_LEAVE_MENU,   execSaveAndExitSetup,   "Save and Exit"         },
@@ -4811,7 +4845,7 @@ static struct TokenInfo setup_info_input[] =
   { 0,                 NULL,                   NULL                    }
 };
 
-static struct TokenInfo setup_info_shortcut_1[] =
+static struct TokenInfo setup_info_shortcuts_1[] =
 {
   { TYPE_KEYTEXT,      NULL,           "Quick Save Game to Tape:",     },
   { TYPE_KEY,          &setup.shortcut.save_game, ""                   },
@@ -4828,7 +4862,7 @@ static struct TokenInfo setup_info_shortcut_1[] =
   { 0,                 NULL,                   NULL                    }
 };
 
-static struct TokenInfo setup_info_shortcut_2[] =
+static struct TokenInfo setup_info_shortcuts_2[] =
 {
   { TYPE_KEYTEXT,      NULL,           "Set Focus to Player 1:",       },
   { TYPE_KEY,          &setup.shortcut.focus_player[0], ""             },
@@ -5089,14 +5123,14 @@ static void DrawSetupScreen_Generic()
     setup_info = setup_info_artwork;
     title_string = "Custom Artwork";
   }
-  else if (setup_mode == SETUP_MODE_SHORTCUT_1)
+  else if (setup_mode == SETUP_MODE_SHORTCUTS_1)
   {
-    setup_info = setup_info_shortcut_1;
+    setup_info = setup_info_shortcuts_1;
     title_string = "Setup Shortcuts";
   }
-  else if (setup_mode == SETUP_MODE_SHORTCUT_2)
+  else if (setup_mode == SETUP_MODE_SHORTCUTS_2)
   {
-    setup_info = setup_info_shortcut_2;
+    setup_info = setup_info_shortcuts_2;
     title_string = "Setup Shortcuts";
   }
 
@@ -6379,8 +6413,10 @@ void CreateScreenGadgets()
 
   CreateScreenMenubuttons();
 
+#if 0
   /* force LEVELS draw offset for scrollbar / scrollbutton gadgets */
   game_status = GAME_MODE_LEVELS;
+#endif
 
   CreateScreenScrollbuttons();
   CreateScreenScrollbars();