Commit 24bba9c4 authored by Johan Sundström's avatar Johan Sundström
Browse files

Added a mark-as-read review variable and commands to change it.

parent ef7ddd69
2001-11-04 Johan Sundstrm <jhs@lysator.liu.se>
* vars.el.in (kom-review-marks-texts-as-read): New variable.
* view-text.el (lyskom-view-text): Honour the above; when
reviwing, the texts read are always marked as red when the
variable is non-nil.
* option-edit.el (lyskom-custom-variables,
lyskom-customize-buffer-format): User configurable default too.
* commands2.el (kom-make-review-mark-as-read,
kom-make-review-not-mark-as-read): Change the review behaviour.
"terse lsmarkerar" and "terse lsmarkerar inte" now choose
review mode, effectively overriding the configured mode for the
lifetime of the current kom buffer.
* swedish-strings.el (lyskom-custom-strings, lyskom-command):
Variable docs, method names and assorted strings.
* english-strings.el (lyskom-custom-strings, lyskom-command):
Ditto.
2001-10-18 Kent Engstrm <kent@ceres.unit.liu.se>
* vars.el.in (kom-server-aliases): change dskom.studkar.hj.se to
......
......@@ -2517,3 +2517,15 @@ the text on one line."
(flags (and (> (length item) 2)
(elt item 2))))
(lyskom-display-help-category category flags))))))
(def-kom-command kom-make-review-mark-as-read ()
"Makes all review commands mark texts as read. Overrides the value of the
configurable variable `kom-review-marks-texts-as-read' in the current buffer."
(interactive)
(setq kom-review-marks-texts-as-read t))
(def-kom-command kom-make-review-not-mark-as-read ()
"Makes all review commands not mark texts as read. Overrides the value of the
configurable variable `kom-review-marks-texts-as-read' in the current buffer."
(interactive)
(setq kom-review-marks-texts-as-read nil))
......@@ -1741,6 +1741,9 @@ You must become an active member of the conference to enter it.\n")
(kom-is-person-member-of-conference . "Check (if person is a) member (of conference)")
(kom-change-conf-faq . "Change FAQ")
(kom-make-review-mark-as-read . "Review marks as read")
(kom-make-review-not-mark-as-read . "Review does not mark as read")
))
(lyskom-language-var lyskom-language-codes en
......@@ -3277,6 +3280,10 @@ be saved in the server. Otherwise it will be saved in your .emacs.")
commands run significantly faster, but in some cases the texts may
have changed since they were copied, and you will not see those
changes.")
(kom-review-marks-texts-as-read-doc . "\
If this is turned on, commands that review texts will also mark them
as read. Otherwise, the review commands will leave your reading history
untouched, as usual.")
;;
;; Tags for variables
......@@ -3440,6 +3447,7 @@ be saved in the server. Otherwise it will be saved in your .emacs.")
(kom-print-relative-dates-tag . "Show relative dates:")
(kom-print-seconds-in-time-strings-tag . "Include seconds in time strings:")
(kom-review-uses-cache-tag . "Review commands use cached texts:")
(kom-review-marks-texts-as-read-tag . "Review commands mark texts as read:")
)
)
......
......@@ -159,6 +159,7 @@
[kom-created-texts-are-read]
[kom-created-texts-are-saved]
[kom-review-uses-cache]
[kom-review-marks-texts-as-read]
"\n"
[kom-saved-file-name]
[kom-default-mark]
......@@ -495,6 +496,7 @@ customize buffer but do not save them to the server."
(kom-cite-string (string))
(kom-created-texts-are-read (toggle (yes no)))
(kom-review-uses-cache (toggle (yes no)))
(kom-review-marks-texts-as-read (toggle (yes no)))
(kom-created-texts-are-saved (choice ((const (no nil))
(file nil :tag to-file))))
(kom-default-mark (choice ((number (0 255)
......@@ -686,6 +688,7 @@ customize buffer but do not save them to the server."
:tag name) :indent 4))
(kom-print-relative-dates (toggle (yes no)))
(kom-print-seconds-in-time-strings (toggle (yes no)))
()
))
(defvar lyskom-widget-functions
......
......@@ -1740,6 +1740,9 @@ Du m
(kom-is-person-member-of-conference . "Kontrollera (om person r) medlem (i mte)")
(kom-change-conf-faq . "ndra FAQ")
(kom-make-review-mark-as-read . "terse lsmarkerar")
(kom-make-review-not-mark-as-read . "terse lsmarkerar inte")
))
(lyskom-language-strings lyskom-help-strings sv
......@@ -3721,6 +3724,10 @@ i servern. Annars sparas det i din .emacs.")
anvnda sparade kopior av inlggen om de finns. Det gr att kommandona
gr lite snabbare, men det finns en viss risk fr att ett inlgg kan
ha ndrats sedan kopian sparades.")
(kom-review-marks-texts-as-read-doc . "\
Om detta r pslaget s kommer kommandon som terser inlgg att
lsmarkera de inlgg som visas. I annat fall lmnar tersekommandona
din lshistorik orrd, precis som vanligt.")
;;
......@@ -3885,6 +3892,7 @@ i servern. Annars sparas det i din .emacs.")
(kom-print-relative-dates-tag . "Visa relativa datumangivelser:")
(kom-print-seconds-in-time-strings-tag . "Inkludera sekunder i tidsangivelser:")
(kom-review-uses-cache-tag . "tersekommandon anvnder sparade inlgg:")
(kom-review-marks-texts-as-read-tag . "tersekommandon lsmarkerar visade texter:")
)
)
......
......@@ -223,6 +223,11 @@ The value of this variable is the file name on which to save new texts."
server
inherited)
(def-kom-var kom-review-marks-texts-as-read nil
"*If non-nil, review commands mark the reviewed texts as read."
server
inherited)
(def-kom-var kom-postpone-default 17
"*The number of articles to postpone by default."
server)
......@@ -1695,6 +1700,9 @@ is a list of vectors, where each vector specifies an item.
kom-who-is-present-in-conference
kom-is-person-member-of-conference
kom-change-conf-faq
kom-make-review-mark-as-read
kom-make-review-not-mark-as-read
))
;;; ================================================================
......
......@@ -49,7 +49,8 @@
"Display text number TEXT-NO.
Args: TEXT-NO &optional MARK-AS-READ FOLLOW-COMMENTS CONF-STAT
PRIORITY BUILD-REVIEW-TREE FLAT-REVIEW.
If MARK-AS-READ is non-nil the text will be marked as read.
If MARK-AS-READ (or `kom-review-marks-texts-as-read') is non-nil the text will
be marked as read.
If FOLLOW-COMMENTS is non-nil all comments and footnotes to this text will be
read before the next text. CONF-STAT must be the conference status of the
current conference, and PRIORITY the priority, if FOLLOW-COMMENTS is non-nil.
......@@ -291,7 +292,9 @@ Note that this function must not be called asynchronously."
;; Insert the text body.
(lyskom-print-text text-stat text
mark-as-read text-no flat-review))
(or mark-as-read kom-review-marks-texts-as-read)
text-no flat-review)
(if kom-review-marks-texts-as-read (lyskom-is-read text-no)))
;; Insert aux-items that go in the footer.
......@@ -381,7 +384,8 @@ Note that this function must not be called asynchronously."
kom-review-uses-cache)
(lyskom-prefetch-texttree text-no))
(lyskom-follow-comments text-stat
conf-stat mark-as-read
conf-stat
(or mark-as-read kom-review-marks-texts-as-read)
priority build-review-tree)))
(if (lyskom-text-p (cache-get-text text-no))
(cache-del-text text-no))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment