From 395066201d7d1ced328b4a980691ea4c5e0e50da Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Thu, 18 Apr 2002 22:40:21 +0000 Subject: *** no comment *** --- TODO | 3 +++ chess-file.el | 15 ++++++++------- chess-pgn.el | 4 ++-- 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/TODO b/TODO index 234361e..58464af 100644 --- a/TODO +++ b/TODO @@ -12,6 +12,9 @@ Hotlist +- TAB in chess-pgn-mode at move 1 thinks O-O and O-O-O are legal + moves. + - Make a command binding (for reading NG articles and such) which will assume there is a PGN game under point and will read it as such and jump to the move before cursor; right now, C-c C-c in chess-pgn diff --git a/chess-file.el b/chess-file.el index e22ede3..dfbd3b6 100644 --- a/chess-file.el +++ b/chess-file.el @@ -17,13 +17,14 @@ (current-buffer))) ((eq event 'rescan) - (goto-char (point-min)) - (setq chess-file-locations nil) - (while (search-forward "[Event " nil t) - (goto-char (match-beginning 0)) - (push (point) chess-file-locations) - (forward-char 1)) - (setq chess-file-locations (nreverse chess-file-locations))) + (save-excursion + (goto-char (point-min)) + (setq chess-file-locations nil) + (while (search-forward "[Event " nil t) + (goto-char (match-beginning 0)) + (push (point) chess-file-locations) + (forward-char 1)) + (setq chess-file-locations (nreverse chess-file-locations)))) ((eq event 'save) (save-buffer)) diff --git a/chess-pgn.el b/chess-pgn.el index 1cae1b2..3da9f46 100644 --- a/chess-pgn.el +++ b/chess-pgn.el @@ -315,8 +315,8 @@ If INDENTED is non-nil, indent the move texts." (let ((chess-game-inhibit-events t)) (setq chess-pgn-display (chess-create-display)))) (/= (chess-game-data chess-pgn-current-game 'database-index) - (chess-game-data (chess-display-game chess-pgn-display) - 'database-index))) + (or (chess-game-data (chess-display-game chess-pgn-display) + 'database-index) -1))) (progn (chess-display-disable-popup chess-pgn-display) (chess-display-set-game chess-pgn-display -- cgit v1.2.3