Commit 7598e87b authored by David Byers's avatar David Byers
Browse files

Bug i lyskom-lookup-conf-by-name

Go to point-max i lyskom-button-actions
parent f11d8fac
2000-07-28 David Byers <davby@ida.liu.se>
* completing-read.el (lyskom-read-conf-lookup-specials): Return
conf-z-info, not uconf-stat.
2000-07-27 David Byers <davby@ida.liu.se>
* lyskom-buttons.el: Go to point-max in relevant button actions.
2000-07-25 David Byers <davby@ida.liu.se>
* lyskom-buttons.el (lyskom-keyboard-menu): Couldn't handle
symbols for menu items in lyskom-button-actions. Fixed.
2000-07-17 David Byers <davby@ida.liu.se> 2000-07-17 David Byers <davby@ida.liu.se>
* vars.el.in (lyskom-add-sub-recipients-hook): Renamed function * vars.el.in (lyskom-add-sub-recipients-hook): Renamed function
......
...@@ -268,11 +268,14 @@ conference number specifications to something useful." ...@@ -268,11 +268,14 @@ conference number specifications to something useful."
(defun lyskom-read-conf-lookup-specials (string predicate login-list x-list) (defun lyskom-read-conf-lookup-specials (string predicate login-list x-list)
"Used internally by lyskom-read-conf-internal to look up conf-stats "Used internally by lyskom-read-conf-internal to look up conf-stats
from person and conference number specifications." from person and conference number specifications."
(lyskom-read-conf-expand-specials string (let ((cs (lyskom-read-conf-expand-specials string
predicate predicate
login-list login-list
x-list x-list
t)) t)))
(lyskom-create-conf-z-info (uconf-stat->name cs)
(uconf-stat->conf-type cs)
(uconf-stat->conf-no cs))))
(defun lyskom-lookup-conf-by-name (string predicate) (defun lyskom-lookup-conf-by-name (string predicate)
"Return the conf-z-info associated with STRING that also satisfies "Return the conf-z-info associated with STRING that also satisfies
...@@ -354,14 +357,14 @@ function work as a name-to-conf-stat translator." ...@@ -354,14 +357,14 @@ function work as a name-to-conf-stat translator."
login-list login-list
candidate-list))) candidate-list)))
(cond ((and kom-complete-numbers-before-names (cond ((and kom-complete-numbers-before-names specials)
specials)
(lyskom-read-conf-lookup-specials string (lyskom-read-conf-lookup-specials string
predicate predicate
login-list login-list
candidate-list)) candidate-list))
((= (length result-list) 1) ((= (length result-list) 1)
(car result-list)) (car result-list))
((and (> (length result-list) 1) ((and (> (length result-list) 1)
(lyskom-completing-member string names)) (lyskom-completing-member string names))
(elt result-list (elt result-list
......
...@@ -227,22 +227,28 @@ If there is no active area, then do something else." ...@@ -227,22 +227,28 @@ If there is no active area, then do something else."
(defun lyskom-keyboard-menu (title entries buf arg text) (defun lyskom-keyboard-menu (title entries buf arg text)
"Do a keyboard menu selection." "Do a keyboard menu selection."
(let ((prompt nil) (let* ((prompt nil)
(maxlen 0) (maxlen 0)
(e entries) (entries (mapcar (lambda (el)
(completion-ignore-case t)) (cons (if (stringp (car el)) (car el) (lyskom-get-string (car el)))
(while e (cdr el))) entries))
(if (> (lyskom-string-width (car (car e))) maxlen) (title (if (stringp title) title (lyskom-get-string title)))
(setq maxlen (lyskom-string-width (car (car e))))) (completion-ignore-case t))
(setq e (cdr e))) (lyskom-traverse e entries
(if (> (lyskom-string-width (car e)) maxlen)
(setq maxlen (lyskom-string-width (car e)))))
(setq prompt (concat (setq prompt (concat
(substring title 0 (substring title 0
(min (lyskom-string-width title) (min (lyskom-string-width title)
(- (window-width (minibuffer-window)) (- (window-width (minibuffer-window))
maxlen 3))) ": ")) maxlen 3))) ": "))
(let ((choice (completing-read prompt entries nil t (let ((choice (completing-read prompt
(cons (car (car entries)) 0) nil))) entries
nil
t
(cons (car (car entries))
0) nil)))
(when choice (when choice
(funcall (cdr (lyskom-string-assoc choice entries)) (funcall (cdr (lyskom-string-assoc choice entries))
buf arg text))))) buf arg text)))))
...@@ -547,6 +553,7 @@ up." ...@@ -547,6 +553,7 @@ up."
This is a LysKOM button action." This is a LysKOM button action."
(cond ((not (integerp arg)) nil) (cond ((not (integerp arg)) nil)
(t (pop-to-buffer buf) (t (pop-to-buffer buf)
(goto-char (point-max))
(kom-view arg)))) (kom-view arg))))
(defun lyskom-button-review-noconversion (buf arg text) (defun lyskom-button-review-noconversion (buf arg text)
...@@ -554,6 +561,7 @@ This is a LysKOM button action." ...@@ -554,6 +561,7 @@ This is a LysKOM button action."
Last argument TEXT is ignored. This is a LysKOM button action." Last argument TEXT is ignored. This is a LysKOM button action."
(cond ((not (integerp arg)) nil) (cond ((not (integerp arg)) nil)
(t (pop-to-buffer buf) (t (pop-to-buffer buf)
(goto-char (point-max))
(kom-review-noconversion arg)))) (kom-review-noconversion arg))))
(defun lyskom-button-review-tree (buf arg text) (defun lyskom-button-review-tree (buf arg text)
...@@ -561,6 +569,7 @@ Last argument TEXT is ignored. This is a LysKOM button action." ...@@ -561,6 +569,7 @@ Last argument TEXT is ignored. This is a LysKOM button action."
This is a LysKOM button action." This is a LysKOM button action."
(cond ((not (integerp arg)) nil) (cond ((not (integerp arg)) nil)
(t (pop-to-buffer buf) (t (pop-to-buffer buf)
(goto-char (point-max))
(kom-review-tree arg)))) (kom-review-tree arg))))
(defun lyskom-button-find-root (buf arg text) (defun lyskom-button-find-root (buf arg text)
...@@ -568,6 +577,7 @@ This is a LysKOM button action." ...@@ -568,6 +577,7 @@ This is a LysKOM button action."
This is a LysKOM button action." This is a LysKOM button action."
(cond ((not (integerp arg)) nil) (cond ((not (integerp arg)) nil)
(t (pop-to-buffer buf) (t (pop-to-buffer buf)
(goto-char (point-max))
(kom-find-root arg)))) (kom-find-root arg))))
(defun lyskom-button-comment-text (buf arg text) (defun lyskom-button-comment-text (buf arg text)
...@@ -622,6 +632,7 @@ Last argument TEXT is ignored. ...@@ -622,6 +632,7 @@ Last argument TEXT is ignored.
This is a LysKOM button action." This is a LysKOM button action."
(cond ((not (integerp arg)) nil) (cond ((not (integerp arg)) nil)
(t (pop-to-buffer buf) (t (pop-to-buffer buf)
(goto-char (point-max))
(kom-review-presentation arg)))) (kom-review-presentation arg))))
(defun lyskom-button-view-conf-status (buf arg text) (defun lyskom-button-view-conf-status (buf arg text)
...@@ -630,6 +641,7 @@ TEXT is ignored. ...@@ -630,6 +641,7 @@ TEXT is ignored.
This is a LysKOM button action." This is a LysKOM button action."
(cond ((not (integerp arg)) nil) (cond ((not (integerp arg)) nil)
(t (pop-to-buffer buf) (t (pop-to-buffer buf)
(goto-char (point-max))
(kom-status-conf arg)))) (kom-status-conf arg))))
(defun lyskom-button-goto-conf (buf arg text) (defun lyskom-button-goto-conf (buf arg text)
...@@ -638,6 +650,7 @@ ignored. ...@@ -638,6 +650,7 @@ ignored.
This is a LysKOM button action." This is a LysKOM button action."
(cond ((not (integerp arg)) nil) (cond ((not (integerp arg)) nil)
(t (pop-to-buffer buf) (t (pop-to-buffer buf)
(goto-char (point-max))
(kom-go-to-conf arg)))) (kom-go-to-conf arg))))
(defun lyskom-button-add-self (buf arg text) (defun lyskom-button-add-self (buf arg text)
...@@ -664,6 +677,7 @@ Last argument TEXT is ignored. ...@@ -664,6 +677,7 @@ Last argument TEXT is ignored.
This is a LysKOM button action." This is a LysKOM button action."
(cond ((not (integerp arg)) nil) (cond ((not (integerp arg)) nil)
(t (pop-to-buffer buf) (t (pop-to-buffer buf)
(goto-char (point-max))
(kom-status-person arg)))) (kom-status-person arg))))
(defun lyskom-button-mail (buf arg text) (defun lyskom-button-mail (buf arg text)
...@@ -1039,6 +1053,7 @@ depending on the value of `kom-lynx-terminal'." ...@@ -1039,6 +1053,7 @@ depending on the value of `kom-lynx-terminal'."
(defun lyskom-button-info-aux (buf arg text) (defun lyskom-button-info-aux (buf arg text)
(pop-to-buffer buf) (pop-to-buffer buf)
(goto-char (point-max))
(let ((aux nil)) (let ((aux nil))
(cond ((lyskom-aux-item-p arg)) (cond ((lyskom-aux-item-p arg))
((listp arg) ((listp arg)
......
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