Update of /project/beirc/cvsroot/beirc In directory common-lisp.net:/tmp/cvs-serv14202
Modified Files: beirc.lisp message-display.lisp Log Message: don't highlight the user's nickname in the first column.
Date: Sat Sep 24 20:13:44 2005 Author: afuchs
Index: beirc/beirc.lisp diff -u beirc/beirc.lisp:1.24 beirc/beirc.lisp:1.25 --- beirc/beirc.lisp:1.24 Sat Sep 24 19:39:36 2005 +++ beirc/beirc.lisp Sat Sep 24 20:13:44 2005 @@ -437,7 +437,8 @@ (sleep 1)))
(define-presentation-type nickname ()) -(define-presentation-type ignored-nickname (nickname)) +(define-presentation-type unhighlighted-nickname () :inherit-from 'nickname) +(define-presentation-type ignored-nickname () :inherit-from 'nickname)
(defun hash-alist (hashtable &aux res) (maphash (lambda (k v) (push (cons k v) res)) hashtable) @@ -471,12 +472,15 @@ (irc:normalize-nickname (current-connection *application-frame*) nickname))))
+(define-presentation-method present (o (type unhighlighted-nickname) *standard-output* (view textual-view) &key) + (write-string o)) + (define-presentation-method present (o (type nickname) *standard-output* (view textual-view) &key) (if (nick-equals-my-nick-p o) (with-drawing-options (t :ink +darkgreen+) (with-text-face (t :bold) - (format t "~A" o))) - (format t "~A" o))) + (write-string o))) + (write-string o)))
(define-presentation-type channel () :inherit-from 'string)
Index: beirc/message-display.lisp diff -u beirc/message-display.lisp:1.10 beirc/message-display.lisp:1.11 --- beirc/message-display.lisp:1.10 Sat Sep 24 19:28:38 2005 +++ beirc/message-display.lisp Sat Sep 24 20:13:44 2005 @@ -126,7 +126,7 @@ (if (message-from-focused-nick-p message receiver) :bold :roman)) (formatting-message (t message receiver) ((write-string start-string *standard-output*) - (present (irc:source message) 'nickname) + (present (irc:source message) 'unhighlighted-nickname) (write-string end-string *standard-output*)) ((format-message* (irc:trailing-argument message))))))))