\r
struct History{\r
String *Nr,*white,*black;\r
- int aNr; /* space actually alocated */ \r
+ int aNr; /* space actually alocated */\r
Widget mvn,mvw,mvb,vbox,viewport,sh;\r
char Up;\r
};\r
}\r
j=0;\r
XtSetArg(args[j], XtNleftBitmap, None); j++;\r
- XtSetValues(XtNameToWidget(menuBarWidget, "menuMode.Show Move List"),\r
+ XtSetValues(XtNameToWidget(menuBarWidget, "menuMode.Show Move History"),\r
args, j);\r
}\r
\r
free(hist->Nr);free(hist->white);free(hist->black);\r
}\r
else{\r
- hist=(struct History*)malloc(sizeof(struct History)); \r
+ hist=(struct History*)malloc(sizeof(struct History));\r
}\r
hist->aNr=len;\r
hist->Nr=(String*)malloc(hist->aNr*sizeof(String*));\r
hist->white=(String*)malloc(hist->aNr*sizeof(String*));\r
hist->black=(String*)malloc(hist->aNr*sizeof(String*));\r
- \r
+\r
hist->Nr[0]=(String)malloc(hist->aNr*6);\r
hist->white[0]=(String)malloc(hist->aNr*MOVE_LEN);\r
hist->black[0]=(String)malloc(hist->aNr*MOVE_LEN);\r
} else {\r
extra = extra/2;\r
}\r
- \r
+\r
j = 0;\r
XtSetArg(args[j], XtNwidth, &w); j++;\r
XtGetValues(hist->mvw, args, j);\r
if(hist){\r
if(last >= hist->aNr) HistoryAlloc(last+_LL_);\r
for(i=0;i<last;i++) {\r
- if((i%2)==0) { \r
+ if((i%2)==0) {\r
if(movelist[i][0]) {\r
char* p = strchr(movelist[i], ' ');\r
if (p) {\r
hist->white[i/2+1][p-movelist[i]] = NULLCHAR;\r
} else {\r
strcpy(hist->white[i/2+1],movelist[i]);\r
- } \r
+ }\r
} else {\r
strcpy(hist->white[i/2+1],dots);\r
}\r
hist->black[i/2+1][p-movelist[i]] = NULLCHAR;\r
} else {\r
strcpy(hist->black[i/2+1],movelist[i]);\r
- } \r
+ }\r
} else {\r
strcpy(hist->black[i/2+1],"");\r
}\r
<Key>Right: ForwardProc() \n";\r
/*--- allocate memory for move-strings ---*/\r
HistoryAlloc(_LL_);\r
- \r
+\r
/*-------- create the widgets ---------------*/\r
j = 0;\r
XtSetArg(args[j], XtNresizable, True); j++;\r
- XtSetArg(args[j], XtNallowShellResize, True); j++; \r
+ XtSetArg(args[j], XtNallowShellResize, True); j++;\r
#if TOPLEVEL\r
hist->sh =\r
XtCreatePopupShell(_("Move list"), topLevelShellWidgetClass,\r
hist->sh =\r
XtCreatePopupShell(_("Move list"), transientShellWidgetClass,\r
shellWidget, args, j);\r
-#endif \r
+#endif\r
j = 0;\r
XtSetArg(args[j], XtNborderWidth, 0); j++;\r
XtSetArg(args[j], XtNdefaultDistance, 0); j++;\r
layout =\r
XtCreateManagedWidget(layoutName, formWidgetClass, hist->sh,\r
args, j);\r
- \r
+\r
j = 0;\r
XtSetArg(args[j], XtNborderWidth, 0); j++;\r
XtSetArg(args[j], XtNresizable, True); j++;\r
- \r
+\r
form =\r
XtCreateManagedWidget("form", formWidgetClass, layout, args, j);\r
j=0;\r
XtSetArg(args[j], XtNorientation,XtorientHorizontal);j++;\r
hist->vbox =\r
XtCreateManagedWidget("vbox", formWidgetClass, hist->viewport, args, j);\r
- \r
+\r
j=0;\r
XtSetArg(args[j], XtNtop, XtChainTop); j++;\r
XtSetArg(args[j], XtNbottom, XtChainTop); j++;\r
XtSetArg(args[j], XtNleft, XtChainLeft); j++;\r
- XtSetArg(args[j], XtNright, XtChainLeft); j++; \r
- \r
+ XtSetArg(args[j], XtNright, XtChainLeft); j++;\r
+\r
XtSetArg(args[j], XtNdefaultColumns, 1); j++;\r
XtSetArg(args[j], XtNforceColumns, True); j++;\r
XtSetArg(args[j], XtNverticalList, True); j++;\r
XtSetArg(args[j], XtNtop, XtChainTop); j++;\r
XtSetArg(args[j], XtNbottom, XtChainTop); j++;\r
XtSetArg(args[j], XtNleft, XtChainLeft); j++;\r
- XtSetArg(args[j], XtNright, XtRubber); j++; \r
- \r
+ XtSetArg(args[j], XtNright, XtRubber); j++;\r
+\r
XtSetArg(args[j], XtNdefaultColumns, 1); j++;\r
XtSetArg(args[j], XtNforceColumns, True); j++;\r
XtSetArg(args[j], XtNverticalList, True); j++;\r
XtSetArg(args[j], XtNbottom, XtChainTop); j++;\r
XtSetArg(args[j], XtNleft, XtRubber); j++;\r
XtSetArg(args[j], XtNright, XtRubber); j++;\r
- \r
+\r
XtSetArg(args[j], XtNdefaultColumns, 1); j++;\r
XtSetArg(args[j], XtNforceColumns, True); j++;\r
XtSetArg(args[j], XtNverticalList, True); j++;\r
XtSetArg(args[j], XtNright, XtChainLeft); j++;\r
XtSetArg(args[j], XtNfromVert, hist->viewport); j++;\r
b_close= XtCreateManagedWidget(_("Close"), commandWidgetClass,\r
- form, args, j); \r
+ form, args, j);\r
XtAddCallback(b_close, XtNcallback, HistoryPopDown, (XtPointer) 0);\r
\r
- XtAugmentTranslations(hist->sh,XtParseTranslationTable (trstr)); \r
+ XtAugmentTranslations(hist->sh,XtParseTranslationTable (trstr));\r
\r
XtRealizeWidget(hist->sh);\r
CatchDeleteWindow(hist->sh, "HistoryPopDown");\r
strcpy(hist->white[i],dots);\r
strcpy(hist->black[i],"");\r
}\r
- \r
+\r
return hist->sh;\r
}\r
\r
int j;\r
\r
if(!hist) HistoryCreate();\r
+\r
XtPopup(hist->sh, XtGrabNone);\r
\r
// [HGM] restore old position\r
\r
j=0;\r
XtSetArg(args[j], XtNleftBitmap, xMarkPixmap); j++;\r
- XtSetValues(XtNameToWidget(menuBarWidget, "menuMode.Show Move List"),\r
+ XtSetValues(XtNameToWidget(menuBarWidget, "menuMode.Show Move History"),\r
args, j);\r
hist->Up=True;\r
}\r
\r
- \r
+\r
void\r
HistoryShowProc(w, event, prms, nprms)\r
Widget w;\r
}\r
ToNrEvent(currentMove);\r
}\r
- \r
+\r