]> git.sur5r.net Git - c128-kasse/blobdiff - include/general.h
improve formatting of the start screen
[c128-kasse] / include / general.h
index 4e45b297f80b09ea3751027ed625dddcc8536902..481c104ba0de783c8391535ba1a1e5d480f8f51b 100644 (file)
@@ -12,4 +12,11 @@ extern BYTE _oserror;
 #define PEEKW(addr)        (*(unsigned*) (addr))
 
 #define VIDEOMODE (((* (BYTE *)0xD7) == 0x80) ? 80 : 40)
+
+/* because there is no macro expansion when stringifying, we need to use two
+ * levels of macros to stringify the value of a macro (for example
+ * MAX_ITEM_NAME_LENGTH) */
+#define xstr(s) str(s)
+#define str(s) #s
+
 #endif /*GENERAL_H_*/