restore paren matching in the file editor and background colors
authorD Herring <dherring@at.tentpost.dot.com>
Mon, 7 Nov 2011 03:39:00 +0000 (22:39 -0500)
committerD Herring <dherring@at.tentpost.dot.com>
Mon, 7 Nov 2011 03:39:00 +0000 (22:39 -0500)
These were incorrectly disabled; they appear to be compatible with TTk.

controls.lisp
main.lisp

index f5b270d..b83393e 100644 (file)
@@ -8,6 +8,7 @@
   (setf (label sb) (make-instance 'ltk:label :master sb :font *buffer-font*))\r
   ;;(ltk:configure sb :background *highlight-background*)\r
   (ltk:configure (label sb)\r
+                 :background *highlight-background*\r
                  :foreground *highlight-text*)\r
   (ltk:pack (label sb) :side :left :pady 1 :padx 5 :fill :both))\r
 \r
index da359ec..c5637aa 100644 (file)
--- a/main.lisp
+++ b/main.lisp
   (setf (edit-ctrl txt) (ltk:textbox txt))
   (ltk:grid-forget (ltk::hscroll txt))  ; remove the horizontal scroll-bar
   (let ((edit-ctrl (ltk:textbox txt)))
-    (ltk:configure (edit-ctrl txt) :font *buffer-font*
+    (ltk:configure (edit-ctrl txt) :font *buffer-font* :background *highlight-background*
       :foreground *highlight-text* :relief :groove :undo 0 :insertbackground *highlight-text*)
     (ltk:bind edit-ctrl "<KeyPress>"
       (lambda (evt) (unless (plaintextp txt) (on-key-down edit-ctrl evt))))
       (lambda (evt) (unless (plaintextp txt)
                       (on-ctrl-left-bracket-key edit-ctrl evt))) :exclusive t)
     (ltk:bind edit-ctrl "<Escape>" #'on-escape :exclusive t)
-    ;;(ltk:tag-configure (edit-ctrl txt) "parens" "background" *highlight-paren-match*)
+    (ltk:tag-configure (edit-ctrl txt) "parens" "background" *highlight-paren-match*)
     (ltk:tag-configure (edit-ctrl txt) "keywords" "foreground" *highlight-primary*)
     (ltk:tag-configure (edit-ctrl txt) "user" "foreground" *highlight-secondary*)
     (ltk:tag-configure (edit-ctrl txt) "comments" "foreground" *highlight-comments*)))
     (ltk:tag-configure text "error" "foreground" *highlight-error*)
     (ltk:tag-configure text "parens" "background" *highlight-paren-match*)
     (ltk:tag-configure text "prompt" "foreground" *highlight-secondary*)
-    (ltk:configure text :font *buffer-font*
+    (ltk:configure text :font *buffer-font* :background *highlight-background*
       :foreground *highlight-primary* :relief :groove :insertbackground *highlight-text*)
     (ltk:pack text :side :left :fill :both :expand t)
     (prompt listener)))