diff options
| author | John Wiegley <johnw@newartisans.com> | 2002-03-02 05:44:56 +0000 |
|---|---|---|
| committer | John Wiegley <johnw@newartisans.com> | 2002-03-02 05:44:56 +0000 |
| commit | 18883992b9cdfd564f7089f16c8ae3bd556b751e (patch) | |
| tree | 8737029ee206775d988d10344a0b7c2cc22d49d2 /chess-pgn.el | |
| parent | 63ec14391807a518bc9a4378a57e802e9a8f41dd (diff) | |
Made `chess-pgn-insert-plies' more useful as a standalone.
Diffstat (limited to 'chess-pgn.el')
| -rw-r--r-- | chess-pgn.el | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/chess-pgn.el b/chess-pgn.el index 7a83ba5..841cccb 100644 --- a/chess-pgn.el +++ b/chess-pgn.el @@ -71,20 +71,23 @@ (assert (listp ann)) (chess-pgn-insert-plies index ann)))) -(defun chess-pgn-insert-plies (index plies &optional for-black indented) +(defun chess-pgn-insert-plies (index plies &optional + for-black indented no-annotations) "NYI: Still have to implement INDENTED argument." (while plies (unless for-black (insert (format "%d. %s" index (chess-ply-to-algebraic (car plies)))) - (chess-pgn-insert-annotations index (car plies)) + (unless no-annotations + (chess-pgn-insert-annotations index (car plies))) (setq plies (cdr plies) index (1+ index))) (when plies (when for-black (insert (format "%d. ..." index)) (setq for-black nil)) (insert (format " %s" (chess-ply-to-algebraic (car plies)))) - (chess-pgn-insert-annotations index (car plies)) + (unless no-annotations + (chess-pgn-insert-annotations index (car plies))) (setq plies (cdr plies))) (if plies (insert ? )))) |
