X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=dialogs.c;h=d8f168480fdbd3414e32b449b471cdaa6940909f;hb=2087ac0f61e84f7f71cbea5a0a3325374f9e76ee;hp=6db9c6ec86bdfd68adcf3c8849b39ff8d1480eb1;hpb=6e119123be4cf0ac4b922318e8855ee9c71743cd;p=xboard.git diff --git a/dialogs.c b/dialogs.c index 6db9c6e..d8f1684 100644 --- a/dialogs.c +++ b/dialogs.c @@ -66,7 +66,7 @@ extern char *getenv(); int values[MAX_OPTIONS]; ChessProgramState *currentCps; -char dataDir[MSG_SIZ] = DATADIR, manDir[MSG_SIZ] = MANDIR; +char manDir[MSG_SIZ] = MANDIR; //----------------------------Generic dialog -------------------------------------------- @@ -557,6 +557,7 @@ Pick (int n) appData.pieceToCharTable = NULL; appData.pieceNickNames = ""; appData.colorNickNames = ""; + appData.men = ""; PopDown(TransientDlg); Reset(True, True); return; @@ -2473,7 +2474,7 @@ GetHelpText (FILE *f, char *name) int len, cnt = 0; snprintf(buf, MSG_SIZ, ".B %s", name); len = strlen(buf); - for(len=1; buf[len] == ' ' || buf[len] == '-' || isalpha(buf[len]) || isdigit(buf[len]); len++); + for(len=3; buf[len] && buf[len] != '(' && buf[len] != ':' && buf[len] != '.' && buf[len] != '?'; len++); buf[len] = NULLCHAR; while(buf[--len] == ' ') buf[len] = NULLCHAR; snprintf(title, MSG_SIZ, "Help on '%s'", buf+3); @@ -2543,6 +2544,8 @@ DisplayHelp (char *name) } else snprintf(buf, MSG_SIZ, "%s", xboardMan); // use xboard man f = fopen(buf, "r"); if(f) { + char *msg = "Right-clicking menu item or dialog text pops up help on it"; + ASSIGN(appData.suppress, msg); if(strstr(buf, ".gz")) { // man file is gzipped if(!manText[n]) { // unzipped text not buffered yet snprintf(tidy, MSG_SIZ, "gunzip -c %s", buf);