Make Fischer castling generally available
[xboard.git] / args.h
diff --git a/args.h b/args.h
index 362b2eb..dec7a5c 100644 (file)
--- a/args.h
+++ b/args.h
@@ -5,7 +5,7 @@
  * Massachusetts.
  *
  * Enhancements Copyright 1992-2001, 2002, 2003, 2004, 2005, 2006,
- * 2007, 2008, 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc.
+ * 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014 Free Software Foundation, Inc.
  *
  * Enhancements Copyright 2005 Alessandro Scotti
  *
@@ -558,6 +558,7 @@ ArgDescriptor argDescriptors[] = {
   { "pgnEventHeader", ArgString, (void *) &appData.pgnEventHeader, TRUE, (ArgIniType) "Computer Chess Game" },
   { "defaultFrcPosition", ArgInt, (void *) &appData.defaultFrcPosition, TRUE, (ArgIniType) -1 },
   { "shuffleOpenings", ArgTrue, (void *) &shuffleOpenings, FALSE, INVALID },
+  { "fischerCastling", ArgTrue, (void *) &appData.fischerCastling, FALSE, INVALID },
   { "gameListTags", ArgString, (void *) &appData.gameListTags, TRUE, (ArgIniType) GLT_DEFAULT_TAGS },
   { "saveOutOfBookInfo", ArgBoolean, (void *) &appData.saveOutOfBookInfo, TRUE, (ArgIniType) TRUE },
   { "showEvalInMoveHistory", ArgBoolean, (void *) &appData.showEvalInMoveHistory, TRUE, (ArgIniType) TRUE },
@@ -697,6 +698,9 @@ ArgDescriptor argDescriptors[] = {
   { "topLevel", ArgBoolean, (void *) &appData.topLevel, XBOARD, (ArgIniType) TOPLEVEL },
   { "dialogColor", ArgString, (void *) &appData.dialogColor, XBOARD, (ArgIniType) "" },
   { "buttonColor", ArgString, (void *) &appData.buttonColor, XBOARD, (ArgIniType) "" },
+  { "firstDrawDepth", ArgInt, (void *) &appData.drawDepth[0], FALSE, (ArgIniType) 0 },
+  { "secondDrawDepth", ArgInt, (void *) &appData.drawDepth[1], FALSE, (ArgIniType) 0 },
+  { "memoHeaders", ArgBoolean, (void *) &appData.headers, TRUE, (ArgIniType) FALSE },
 
 #if ZIPPY
   { "zippyTalk", ArgBoolean, (void *) &appData.zippyTalk, FALSE, (ArgIniType) ZIPPY_TALK },
@@ -909,7 +913,9 @@ ParseSettingsFile(char *name, char **addr)
     f = fopen(fullname, "r");
 #ifdef DATADIR
     if(f == NULL && *fullname != '/') {         // when a relative name did not work
-       MySearchPath(DATADIR "/themes/conf", name, fullname); // also look in standard place
+       char buf[MSG_SIZ];
+       snprintf(buf, MSG_SIZ, "%s/themes/conf", DATADIR);
+       MySearchPath(buf, name, fullname); // also look in standard place
        f = fopen(fullname, "r");
     }
 #endif
@@ -1145,14 +1151,12 @@ ParseArgs(GetFunc get, void *cl)
 
     case ArgString:
     case ArgFilename:
-#ifdef DATADIR
       if(argValue[0] == '~' && argValue[1] == '~') {
         char buf[4*MSG_SIZ]; // expand ~~
-        snprintf(buf, 4*MSG_SIZ, DATADIR "%s", argValue+2);
+        snprintf(buf, 4*MSG_SIZ, "%s%s", DATADIR, argValue+2);
         ASSIGN(*(char **) ad->argLoc, buf);
         break;
       }
-#endif
       ASSIGN(*(char **) ad->argLoc, argValue);
       break;