The option -trueColors is now saved with the theme settings when a
pieceImageDirectory was given in XBoard, and the piece colors are
saved when this option is off even with a piece directory. The square
colors are now also saved when useBooardTextures is on, but the textures
are transparent. For this the transparency also had to be made visible in
the WinBoard front end, (by moving the flags for it to backend.c), but
always stay at the default 0 there.
{ "flashRate", ArgInt, (void *) &appData.flashRate, XBOARD, (ArgIniType) FLASH_RATE },
{ "pieceImageDirectory", ArgFilename, (void *) &appData.pieceDirectory, TRUE, (ArgIniType) "" },
{ "pid", ArgFilename, (void *) &appData.pieceDirectory, FALSE, INVALID },
{ "flashRate", ArgInt, (void *) &appData.flashRate, XBOARD, (ArgIniType) FLASH_RATE },
{ "pieceImageDirectory", ArgFilename, (void *) &appData.pieceDirectory, TRUE, (ArgIniType) "" },
{ "pid", ArgFilename, (void *) &appData.pieceDirectory, FALSE, INVALID },
- { "trueColors", ArgBoolean, (void *) &appData.trueColors, TRUE, (ArgIniType) FALSE },
+ { "trueColors", ArgBoolean, (void *) &appData.trueColors, XBOARD, (ArgIniType) (2*!XBOARD) },
{ "jewelled", ArgInt, (void *) &appData.jewelled, FALSE, (ArgIniType) -1 },
{ "soundDirectory", ArgFilename, (void *) &appData.soundDirectory, XBOARD, (ArgIniType) "" },
{ "msLoginDelay", ArgInt, (void *) &appData.msLoginDelay, XBOARD, (ArgIniType) MS_LOGIN_DELAY },
{ "jewelled", ArgInt, (void *) &appData.jewelled, FALSE, (ArgIniType) -1 },
{ "soundDirectory", ArgFilename, (void *) &appData.soundDirectory, XBOARD, (ArgIniType) "" },
{ "msLoginDelay", ArgInt, (void *) &appData.msLoginDelay, XBOARD, (ArgIniType) MS_LOGIN_DELAY },
ToNrEvent(currentMove+1);
}
ToNrEvent(currentMove+1);
}
appData.liteBackTextureMode,
appData.darkBackTextureMode );
} else {
appData.liteBackTextureMode,
appData.darkBackTextureMode );
} else {
- snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -ubt false -lsc %s -dsc %s",
- Col2Text(2), // lightSquareColor
- Col2Text(3) ); // darkSquareColor
+ snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -ubt false");
+ }
+ if(!appData.useBitmaps || transparency[0]) {
+ snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -lsc %s", Col2Text(2) ); // lightSquareColor
+ }
+ if(!appData.useBitmaps || transparency[1]) {
+ snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -dsc %s", Col2Text(3) ); // darkSquareColor
}
if(appData.useBorder) {
snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -ub true -border \"%s\"",
}
if(appData.useBorder) {
snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -ub true -border \"%s\"",
Col2Text(9), // appData.fontBackColorWhite
Col2Text(10) ); // appData.fontForeColorBlack
} else {
Col2Text(9), // appData.fontBackColorWhite
Col2Text(10) ); // appData.fontForeColorBlack
} else {
- snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -upf false -pid \"%s\"",
- appData.pieceDirectory);
- if(!appData.pieceDirectory[0])
+ snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -upf false");
+ if(appData.pieceDirectory[0]) {
+ snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -pid \"%s\"", appData.pieceDirectory);
+ if(appData.trueColors != 2) // 2 is a kludge to suppress this in WinBoard
+ snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -trueColors %s", appData.trueColors ? "true" : "false");
+ }
+ if(!appData.pieceDirectory[0] && !appData.trueColors)
snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -wpc %s -bpc %s",
Col2Text(0), // whitePieceColor
Col2Text(1) ); // blackPieceColor
snprintf(buf+strlen(buf), MSG_SIZ-strlen(buf), " -wpc %s -bpc %s",
Col2Text(0), // whitePieceColor
Col2Text(1) ); // blackPieceColor
extern int dragging;
extern char variantError[];
extern char lastTalker[];
extern int dragging;
extern char variantError[];
extern char lastTalker[];
+extern int transparency[];
void MarkMenuItem P((char *menuRef, int state));
char *CmailMsg P((void));
void MarkMenuItem P((char *menuRef, int state));
char *CmailMsg P((void));
-static int modV[2], modH[2], transparency[2];
+static int modV[2], modH[2];
static void
CreatePNGBoard (char *s, int kind)
static void
CreatePNGBoard (char *s, int kind)