Commit 789e7226 authored by David Byers's avatar David Byers

Bug fix in lyskom-deferred-insert-footer.

Don't get the author to print the footer unless it's necessary.
parent 9a7c2a6a
1999-10-15 David Byers <davby@ida.liu.se>
* view-text.el (lyskom-print-text): Correct formatting of missing
person.
(lyskom-print-text): Format author in text footer correctly even
if deferred printing is off.
(lyskom-print-text): Don't do deferred printing of the footer
unless it's really necessary. Don't block to get the author for
the footer unless it's necessary.
1999-10-14 David Byers <davby@ida.liu.se>
* view-text.el (lyskom-view-text): Don't set first-line-face on
......
......@@ -684,7 +684,8 @@ blocking-do."
(name (cond (conf-stat nil)
((= (defer-info->call-par defer-info) 0)
(lyskom-get-string 'person-is-anonymous))
(t (lyskom-format 'person-does-not-exist)))))
(t (lyskom-format 'person-does-not-exist
(text-stat->author text-stat))))))
(setq name (or (lyskom-format-mx-author mx-from mx-author) name))
......@@ -766,8 +767,14 @@ Args: TEXT-STAT TEXT MARK-AS-READ TEXT-NO FLAT-REVIEW."
(if (lyskom-text-p (cache-get-text (text->text-no text)))
(cache-del-text (text->text-no text)))
(sit-for 0)
(let ((lyskom-current-function-phase 'footer))
(if kom-deferred-printing
(let* ((lyskom-current-function-phase 'footer)
(mx-from (car (lyskom-get-aux-item (text-stat->aux-items text-stat) 17)))
(mx-author (car (lyskom-get-aux-item (text-stat->aux-items text-stat) 16)))
(author-name (lyskom-format-mx-author mx-from mx-author)))
(if (and kom-deferred-printing
(or kom-text-footer-format
kom-show-author-at-end))
(progn
(lyskom-format-insert "%#1s\n" lyskom-defer-indicator)
(lyskom-defer-insertion
......@@ -782,18 +789,20 @@ Args: TEXT-STAT TEXT MARK-AS-READ TEXT-NO FLAT-REVIEW."
(length lyskom-defer-indicator)
"%#1s"
(list text-stat lyskom-last-text-format-flags))))
(let* ((conf-stat (blocking-do 'get-conf-stat
(text-stat->author text-stat)))
(author-name
(or (conf-stat->name conf-stat)
(and (eq (text-stat->author text-stat) 0)
(lyskom-get-string 'person-is-anonymous))
(lyskom-format 'person-does-not-exist
(text-stat->author text-stat)))))
(let* ((conf-stat (and (or kom-text-footer-format
kom-show-author-at-end)
(not (eq 0 (text-stat->author text-stat)))
(blocking-do 'get-conf-stat
(text-stat->author text-stat)))))
(lyskom-insert (lyskom-format-text-footer
text-stat
conf-stat
author-name
(cond (author-name author-name)
((eq (text-stat->author text-stat) 0)
(lyskom-get-string 'person-is-anonymous))
(conf-stat (conf-stat->name conf-stat))
(t (lyskom-format 'person-does-not-exist
(text-stat->author text-stat))))
kom-text-footer-format
lyskom-last-text-format-flags)))
(lyskom-insert "\n")))
......@@ -1041,7 +1050,7 @@ Args: TEXT-STAT of the text being read."
(setq author (concat (lyskom-get-string 'email-name-suffix) author))
)
author))
(defun lyskom-mx-date-to-time (mx-date)
"Attempt to convert MX-DATE to a lyskom time structure.
Returns the time structure if successful, otherwise nil."
......
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