X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=xaw%2Fxboard.c;h=8d0fb2446b89d5592fc43e4a172e1c93f1746e08;hb=b5529b539614b61fa62d9f6cc374f335e7103024;hp=a94431335283f0de951f65d4338cf911939bd054;hpb=51e9503489f2cee28a076bf52c56185a5283b069;p=xboard.git diff --git a/xaw/xboard.c b/xaw/xboard.c index a944313..8d0fb24 100644 --- a/xaw/xboard.c +++ b/xaw/xboard.c @@ -537,6 +537,12 @@ ParseColor (int n, char *name) if(colorVariable[n]) *(char**)colorVariable[n] = strdup(name); } +char * +Col2Text (int n) +{ + return *(char**)colorVariable[n]; +} + void ParseTextAttribs (ColorClass cc, char *s) { @@ -1109,6 +1115,8 @@ main (int argc, char **argv) programName, appData.boardSize); exit(2); } + if(BOARD_WIDTH > 8) + squareSize = (squareSize*8 + BOARD_WIDTH/2)/BOARD_WIDTH; // scale height if (i < 7) { /* Find some defaults; use the nearest known size */ SizeDefaults *szd, *nearest; @@ -1132,8 +1140,8 @@ main (int argc, char **argv) } else { SizeDefaults *szd = sizeDefaults; if (*appData.boardSize == NULLCHAR) { - while (DisplayWidth(xDisplay, xScreen) < szd->minScreenSize || - DisplayHeight(xDisplay, xScreen) < szd->minScreenSize) { + while (DisplayWidth(xDisplay, xScreen) < (szd->minScreenSize*BOARD_WIDTH + 4)/8 || + DisplayHeight(xDisplay, xScreen) < (szd->minScreenSize*BOARD_HEIGHT + 4)/8) { szd++; } if (szd->name == NULL) szd--;