/*
* New (WinBoard-style) Move history for XBoard
*
- * Copyright 2009, 2010, 2011, 2012 Free Software Foundation, Inc.
+ * Copyright 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc.
* ------------------------------------------------------------------------
*
* GNU XBoard is free software: you can redistribute it and/or modify
#include <stdlib.h>
#include "common.h"
+#include "frontend.h"
#include "backend.h"
-#include "xhistory.h"
#include "dialogs.h"
#include "gettext.h"
return AppendText(&historyOptions[0], text); // for now ignore bold & color stuff, as Xaw cannot handle that
}
+void
+HighlightMove (int from, int to, Boolean highlight)
+{
+ HighlightText (&historyOptions[0], from, to, highlight);
+}
+
char *historyText;
int
{ 0, NO_OK, 0, NULL, (void*) NULL, "", NULL, EndMark , "" }
};
+void
+ScrollToCurrent (int caretPos)
+{
+ ScrollToCursor(&historyOptions[0], caretPos);
+}
+
// ------------ standard entry points into MoveHistory code -----------
Boolean
HistoryPopUp ()
{
if(GenericPopUp(historyOptions, _("Move list"), HistoryDlg, BoardWindow, NONMODAL, 1))
- AddHandler(&historyOptions[0], 0);
+ AddHandler(&historyOptions[0], HistoryDlg, 0);
MarkMenu("View.MoveHistory", HistoryDlg);
}