Update of /project/climacs/cvsroot/climacs In directory common-lisp.net:/tmp/cvs-serv20581
Modified Files: gui.lisp Log Message: Be gentle to those users (i.e. .gold.ac.uk) using climacs for its buffers and syntaxes without the gui. Pile another hack in the :around method for (setf syntax). Live in hope that one day all this will be cleaned up.
Date: Thu Nov 3 11:17:42 2005 Author: crhodes
Index: climacs/gui.lisp diff -u climacs/gui.lisp:1.193 climacs/gui.lisp:1.194 --- climacs/gui.lisp:1.193 Mon Oct 31 14:42:31 2005 +++ climacs/gui.lisp Thu Nov 3 11:17:40 2005 @@ -1427,9 +1427,16 @@ ;;; similar method on (SETF BUFFER). -- CSR, 2005-10-31. (defmethod (setf syntax) :around (syntax (buffer climacs-buffer)) (call-next-method) - (let ((pane (current-window))) - (assert (eq (buffer pane) buffer)) - (note-pane-syntax-changed pane syntax))) + ;; FIXME: we need this because some clients (e.g. the tablature + ;; editor) use climacs buffers without a gui, for off-line (e.g. Web + ;; backend) processing. The problem here is that (setf syntax) + ;; /should/ have no GUI effects whatsoever. So maybe the right + ;; answer would instead be to find the active pane's buffer in the + ;; top-level loop? That might need to be pushed into ESA. + (when clim:*application-frame* + (let ((pane (current-window))) + (assert (eq (buffer pane) buffer)) + (note-pane-syntax-changed pane syntax))))
;;; FIXME - what should this specialise on? (defmethod set-syntax ((buffer climacs-buffer) syntax)