ICSInputBoxUp = False, askQuestionUp = False,
filenameUp = False, promotionUp = False, pmFromX = -1, pmFromY = -1,
errorUp = False, errorExitStatus = -1, lineGap, defaultLineGap;
+Dimension textHeight;
Pixel timerForegroundPixel, timerBackgroundPixel;
Pixel buttonForegroundPixel, buttonBackgroundPixel;
char *chessDir, *programName, *programVersion,
XtSetArg(args[0], XtNtop, XtChainTop);
XtSetArg(args[1], XtNbottom, XtChainTop);
XtSetValues(messageWidget, args, 2);
+ XtSetArg(args[0], XtNheight, &textHeight); // [HGM] get height for use in generic popup
+ XtGetValues(messageWidget, args, 1);
widgetList[j++] = boardWidget =
XtCreateWidget("board", widgetClass, formWidget, boardArgs,
extern char ICSInputTranslations[];
extern char *selected_fen_position;
extern GC coordGC;
+extern Dimension textHeight; // of message widget in board window
#define TOPLEVEL 1 /* preference item; 1 = make popup windows toplevel */
XtSetArg(args[j], XtNfromHoriz, dialog); j++;
XtSetArg(args[j], XtNborderWidth, 1); j++;
XtSetArg(args[j], XtNwidth, w); j++;
+ XtSetArg(args[j], XtNheight, textHeight); j++; // [HGM] use message widget
if(option[i].type == TextBox && option[i].min) {
- XtSetArg(args[j], XtNheight, option[i].min); j++;
+ XtSetArg(args[j-1], XtNheight, option[i].min); // overwrite
if(option[i].value & 1) { XtSetArg(args[j], XtNscrollVertical, XawtextScrollAlways); j++; }
if(option[i].value & 2) { XtSetArg(args[j], XtNscrollHorizontal, XawtextScrollAlways); j++; }
if(option[i].value & 4) { XtSetArg(args[j], XtNautoFill, True); j++; }