mirror of
https://github.com/rabbibotton/clog.git
synced 2025-12-06 02:30:42 -08:00
more stuff in demo 22
This commit is contained in:
parent
17656894de
commit
b020176157
1 changed files with 9 additions and 4 deletions
|
|
@ -4,19 +4,24 @@
|
||||||
|
|
||||||
(in-package :clog-user)
|
(in-package :clog-user)
|
||||||
|
|
||||||
(defun on-file-new (body)
|
(defun on-file-count (body)
|
||||||
(let ((win (create-gui-window body)))
|
(let ((win (create-gui-window body)))
|
||||||
(dotimes (n 100)
|
(dotimes (n 100)
|
||||||
(create-div (window-content win) :content n))))
|
(create-div (window-content win) :content n))))
|
||||||
|
|
||||||
|
(defun on-file-browse (body)
|
||||||
|
(let* ((win (create-gui-window body))
|
||||||
|
(browser (create-child (window-content win)
|
||||||
|
"<iframe width=100% height=98% src='https://common-lisp.net/'></iframe>")))))
|
||||||
|
|
||||||
(defun on-new-window (body)
|
(defun on-new-window (body)
|
||||||
(clog-gui-initialize body)
|
(clog-gui-initialize body)
|
||||||
(add-class body "w3-teal")
|
(add-class body "w3-cyan")
|
||||||
(let* ((menu (create-gui-menu-bar body))
|
(let* ((menu (create-gui-menu-bar body))
|
||||||
(icon (create-gui-menu-icon menu))
|
(icon (create-gui-menu-icon menu))
|
||||||
(file (create-gui-menu-drop-down menu :content "File"))
|
(file (create-gui-menu-drop-down menu :content "File"))
|
||||||
(new (create-gui-menu-item file :content "New" :on-click #'on-file-new))
|
(new (create-gui-menu-item file :content "Count" :on-click #'on-file-count))
|
||||||
(open (create-gui-menu-item file :content "Open"))
|
(open (create-gui-menu-item file :content "Browse" :on-click #'on-file-browse))
|
||||||
(save (create-gui-menu-item file :content "Save"))
|
(save (create-gui-menu-item file :content "Save"))
|
||||||
(help (create-gui-menu-drop-down menu :content "Help"))
|
(help (create-gui-menu-drop-down menu :content "Help"))
|
||||||
(about (create-gui-menu-item help :content "About"))
|
(about (create-gui-menu-item help :content "About"))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue