[mcclim-cvs] CVS mcclim/Drei

thenriksen thenriksen at common-lisp.net
Wed Jan 23 19:01:41 UTC 2008


Update of /project/mcclim/cvsroot/mcclim/Drei
In directory clnet:/tmp/cvs-serv13721/Drei

Modified Files:
	packages.lisp views.lisp 
Log Message:
Add `syntax-view-p' and `mark-view-p'.


--- /project/mcclim/cvsroot/mcclim/Drei/packages.lisp	2008/01/21 17:08:28	1.45
+++ /project/mcclim/cvsroot/mcclim/Drei/packages.lisp	2008/01/23 19:01:40	1.46
@@ -217,10 +217,10 @@
            ;; Views and their facilities.
            #:drei-view #:modified-p #:no-cursors
            #:drei-buffer-view #:buffer #:top #:bot #:buffer-view-p
-           #:drei-syntax-view #:syntax
+           #:drei-syntax-view #:syntax #:syntax-view-p
            #:pump-state-for-offset-with-syntax
            #:stroke-pump-with-syntax
-           #:point-mark-view
+           #:point-mark-view #:point-mark-view-p
            #:textual-drei-syntax-view
            #:tab-space-count #:space-width #:tab-width #:use-tabs
            #:auto-fill-mode #:auto-fill-column
--- /project/mcclim/cvsroot/mcclim/Drei/views.lisp	2008/01/22 20:14:43	1.27
+++ /project/mcclim/cvsroot/mcclim/Drei/views.lisp	2008/01/23 19:01:40	1.28
@@ -616,7 +616,7 @@
                    ;; If start/end is wholly before (first list), push
                    ;; on a new region.
                    ((< start (car (first list)))
-                    (cons (cons start end) (first list)))
+                    (cons (cons start end) list))
                    ;; If start/end is wholly before (first list), go
                    ;; further down list. If at end of list, add new
                    ;; element.
@@ -697,6 +697,10 @@
         (suffix-size view) 0
         (buffer-size view) -1))
 
+(defun syntax-view-p (view)
+  "Return true if `view' is a `drei-syntax-view'."
+  (typep view 'drei-syntax-view))
+
 (defmethod mode-enabled-p or ((modual drei-syntax-view) mode-name)
   (mode-enabled-p (syntax modual) mode-name))
 
@@ -819,6 +823,10 @@
     (setf point (clone-mark (point buffer))
           mark (clone-mark (point buffer) :right))))
 
+(defun point-mark-view-p (view)
+  "Return true if `view' is a `point-mark-view'"
+  (typep view 'point-mark-view))
+
 (defclass textual-drei-syntax-view (drei-syntax-view point-mark-view textual-view)
   ((%auto-fill-mode :initform nil :accessor auto-fill-mode)
    (%auto-fill-column :initform 70 :accessor auto-fill-column)




More information about the Mcclim-cvs mailing list