mirror of
https://github.com/rabbibotton/clog.git
synced 2025-12-06 02:30:42 -08:00
tab highlighting
This commit is contained in:
parent
42c336a501
commit
d864468524
1 changed files with 13 additions and 2 deletions
|
|
@ -5,7 +5,8 @@
|
||||||
(in-package :clog-user)
|
(in-package :clog-user)
|
||||||
|
|
||||||
(defun on-new-window (body)
|
(defun on-new-window (body)
|
||||||
(let* ((t1 (create-button body :content "Tab1"))
|
(let* (last-tab
|
||||||
|
(t1 (create-button body :content "Tab1"))
|
||||||
(t2 (create-button body :content "Tab2"))
|
(t2 (create-button body :content "Tab2"))
|
||||||
(t3 (create-button body :content "Tab3"))
|
(t3 (create-button body :content "Tab3"))
|
||||||
(p1 (create-div body :content "Panel1 - Type here"))
|
(p1 (create-div body :content "Panel1 - Type here"))
|
||||||
|
|
@ -13,7 +14,7 @@
|
||||||
(p3 (create-div body :content "Panel3 - Type here")))
|
(p3 (create-div body :content "Panel3 - Type here")))
|
||||||
|
|
||||||
(place-after t3 (create-br body))
|
(place-after t3 (create-br body))
|
||||||
|
|
||||||
(setf (width p1) 600)
|
(setf (width p1) 600)
|
||||||
(setf (width p2) 600)
|
(setf (width p2) 600)
|
||||||
(setf (width p3) 600)
|
(setf (width p3) 600)
|
||||||
|
|
@ -34,16 +35,26 @@
|
||||||
(setf (hiddenp p1) t)
|
(setf (hiddenp p1) t)
|
||||||
(setf (hiddenp p2) t)
|
(setf (hiddenp p2) t)
|
||||||
(setf (hiddenp p3) t)
|
(setf (hiddenp p3) t)
|
||||||
|
|
||||||
|
(setf (background-color t1) :grey)
|
||||||
|
(setf (background-color t2) :grey)
|
||||||
|
(setf (background-color t3) :grey)
|
||||||
|
|
||||||
|
(setf (background-color last-tab) :lightblue)
|
||||||
(setf (hiddenp obj) nil)
|
(setf (hiddenp obj) nil)
|
||||||
(focus obj)))
|
(focus obj)))
|
||||||
|
|
||||||
|
(setf last-tab t1)
|
||||||
(select-tab p1)
|
(select-tab p1)
|
||||||
|
|
||||||
(set-on-click t1 (lambda (obj)
|
(set-on-click t1 (lambda (obj)
|
||||||
|
(setf last-tab obj)
|
||||||
(select-tab p1)))
|
(select-tab p1)))
|
||||||
(set-on-click t2 (lambda (obj)
|
(set-on-click t2 (lambda (obj)
|
||||||
|
(setf last-tab obj)
|
||||||
(select-tab p2)))
|
(select-tab p2)))
|
||||||
(set-on-click t3 (lambda (obj)
|
(set-on-click t3 (lambda (obj)
|
||||||
|
(setf last-tab obj)
|
||||||
(select-tab p3))))))
|
(select-tab p3))))))
|
||||||
|
|
||||||
(defun start-tutorial ()
|
(defun start-tutorial ()
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue