X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=common.h;h=755df7843d0ed051e0cdf64386281ba429487a2d;hb=1bb92a334cb80297755d51dcbb3847273b49226e;hp=2044c03a7a7cfe54d6fd6684eab9e3fbce4492e7;hpb=ac9d48038a86a672579abbcbbc53b17e2515ba13;p=xboard.git diff --git a/common.h b/common.h index 2044c03..755df78 100644 --- a/common.h +++ b/common.h @@ -5,7 +5,7 @@ * Massachusetts. * * Enhancements Copyright 1992-2001, 2002, 2003, 2004, 2005, 2006, - * 2007, 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc. + * 2007, 2008, 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc. * * Enhancements Copyright 2005 Alessandro Scotti * @@ -81,7 +81,14 @@ int pclose(FILE *); #endif #else +#ifdef X11 #include +#else +typedef char Boolean; +typedef char *String; +#define True 1 +#define False 0 +#endif #endif #endif @@ -218,6 +225,14 @@ int pclose(FILE *); #define ZIPPY_MAX_GAMES 0 #define ZIPPY_REPLAY_TIMEOUT 120 +typedef VOIDSTAR ProcRef; +#define NoProc ((ProcRef) 0) +typedef VOIDSTAR InputSourceRef; + +typedef void (*DelayedEventCallback) P((void)); + +typedef enum { Press, Release } ClickType; + typedef enum { BeginningOfGame, MachinePlaysWhite, MachinePlaysBlack, AnalyzeMode, AnalyzeFile, TwoMachinesPlay, @@ -408,14 +423,17 @@ typedef struct { Boolean firstPlaysBlack; Boolean noChessProgram; char *host[ENGINES]; - char *pngDirectory; - char *svgDirectory; + char *themeNames; + char *pieceDirectory; + char *border; char *soundDirectory; char *remoteShell; char *remoteUser; float timeDelay; char *timeControl; + Boolean trueColors; Boolean icsActive; + Boolean autoBox; char *icsHost; char *icsPort; char *icsCommPort; /* if set, use serial port instead of tcp host/port */ @@ -466,6 +484,7 @@ typedef struct { Boolean ponderNextMove; Boolean periodicUpdates; Boolean autoObserve; + Boolean autoCreateLogon; Boolean autoComment; Boolean getMoveList; Boolean testLegality; @@ -534,6 +553,7 @@ typedef struct { Boolean showButtonBar; Boolean icsEngineAnalyze; Boolean variations; /* [HGM] enable variation-tree walking */ + Boolean autoExtend; /* [HGM] enable playing move(s) of right-clicked PV in analysis mode */ /* [AS] New properties (down to the "ZIPPY" part) */ Boolean scoreIsAbsolute[ENGINES]; /* If true, engine score is always from white side */ @@ -541,6 +561,7 @@ typedef struct { Boolean hideThinkingFromHuman; /* If true, program thinking is generated but not displayed in human/computer matches */ Boolean useBitmaps; Boolean useFont; + Boolean useBorder; char * liteBackTextureFile; /* Name of texture bitmap for lite squares */ char * darkBackTextureFile; /* Name of texture bitmap for dark squares */ int liteBackTextureMode; @@ -777,6 +798,11 @@ extern WindowPlacement wpTags; extern int chatCount; extern char chatPartner[MAX_CHAT][MSG_SIZ]; +// Some prototypes of routines so general they should be available everywhere +/* If status == 0, we are exiting with a benign message, not an error */ +void DisplayFatalError P((String message, int error, int status)); +void DisplayError P((String message, int error)); + // [HGM] generally useful macros; there are way too many memory leaks... #define FREE(x) if(x) free(x) #define ASSIGN(x, y) if(x) free(x); x = strdup(y) @@ -818,4 +844,3 @@ extern char chatPartner[MAX_CHAT][MSG_SIZ]; #define secondOptions engOptions[1] #endif -