[mcclim-cvs] CVS mcclim/Drei

thenriksen thenriksen at common-lisp.net
Wed Jan 16 12:01:06 UTC 2008


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

Modified Files:
	drei-redisplay.lisp 
Log Message:
Removed some seemingly unnecessary code from the input-editor Drei
variant. I admit I never really fully grasped how it worked, and I may
need someone with major output-record foo to help me figure out the
last bugs.


--- /project/mcclim/cvsroot/mcclim/Drei/drei-redisplay.lisp	2008/01/15 19:31:54	1.36
+++ /project/mcclim/cvsroot/mcclim/Drei/drei-redisplay.lisp	2008/01/16 12:01:05	1.37
@@ -990,19 +990,9 @@
 (defmethod replay-output-record ((drei drei-area) (stream extended-output-stream) &optional
                                  (x-offset 0) (y-offset 0) (region +everywhere+))
   (declare (ignore x-offset y-offset region))
-  (letf (((stream-current-output-record stream) drei)
-         ((stream-cursor-position stream) (values-list (input-editor-position drei))))
-    ;; XXX: If the display begins with a blank area - for example
-    ;; spaces - CLIM will (rightly) think the output records
-    ;; position is at the first output. This is not good, because
-    ;; it means that the output record will "walk" across the
-    ;; screen if the buffer starts with blanks. Therefore, we make
-    ;; sure that an output record exists at the very beginning of
-    ;; the output.
-    (with-new-output-record (stream 'standard-sequence-output-record record)
-      (invalidate-all-strokes (view drei))
-      (display-drei-view-contents stream (view drei))
-      (setf (output-record-position record) (values-list (input-editor-position drei))))))
+  (letf (((stream-cursor-position stream) (values-list (input-editor-position drei))))
+    (invalidate-all-strokes (view drei))
+    (display-drei-view-contents stream (view drei))))
 
 (defmethod replay-output-record :after ((drei drei-area) (stream extended-output-stream) &optional
                                         (x-offset 0) (y-offset 0) (region +everywhere+))
@@ -1014,10 +1004,9 @@
                                          (x-offset 0) (y-offset 0) (region +everywhere+))
   (declare (ignore x-offset y-offset region))
   (clear-output-record cursor)
-  (when (active cursor)
-    (with-output-recording-options (stream :record t :draw nil)
-      (letf (((stream-current-output-record stream) cursor))
-        (display-drei-view-cursor stream (view cursor) cursor)))))
+  (with-output-recording-options (stream :record t :draw nil)
+    (when (active cursor)
+      (display-drei-view-cursor stream (view cursor) cursor))))
 
 (defun display-drei-area (drei)
   (with-accessors ((stream editor-pane) (view view)) drei




More information about the Mcclim-cvs mailing list