diff options
| author | screwlisp <screwtape@sdf.org> | 2026-07-02 23:19:05 +1200 |
|---|---|---|
| committer | screwlisp <screwtape@sdf.org> | 2026-07-02 23:19:05 +1200 |
| commit | 2e0110e9e99034f49a59d68af509ae3015184b7a (patch) | |
| tree | 86a30d5fe0a3cb6633d09b956c7be1d2f57397df | |
| parent | 4bbc0b00023cc8b7db24142febb8695838b78752 (diff) | |
just use package inferred.
| -rw-r--r-- | better-eg.png | bin | 0 -> 119973 bytes | |||
| -rw-r--r-- | class.lisp | 27 | ||||
| -rw-r--r-- | frame.lisp | 19 | ||||
| -rw-r--r-- | packages.lisp | 0 | ||||
| -rw-r--r-- | simple-text-clim-frame.asd | 6 | ||||
| -rw-r--r-- | some.text | 7 |
6 files changed, 59 insertions, 0 deletions
diff --git a/better-eg.png b/better-eg.png Binary files differnew file mode 100644 index 0000000..efd8344 --- /dev/null +++ b/better-eg.png diff --git a/class.lisp b/class.lisp new file mode 100644 index 0000000..ba68fcc --- /dev/null +++ b/class.lisp @@ -0,0 +1,27 @@ +(uiop:define-package + :simple-text-clim-frame/class + (:export #:my-class #:my-display) + (:import-from :asdf)) + +(in-package :simple-text-clim-frame/class) + +(defclass my-class () + ((text-slot + :initform #.(format + nil + "~{~a~^~%~}" + (with-open-file + (in (merge-pathnames + #P"some.text" + (asdf:system-source-directory + "simple-text-clim-frame"))) + (loop for line = (read-line in nil nil) + while line + collect line)))))) + +(defmethod my-display ((obj my-class) stream) + (with-slots + (text-slot) + obj + (princ text-slot stream))) + @@ -0,0 +1,19 @@ +(uiop:define-package + :simple-text-clim-frame/frame + (:export) + (:mix-reexport :simple-text-clim-frame/class) + (:mix :clim :clim-lisp)) + +(in-package :simple-text-clim-frame/frame) + +(define-application-frame + my-frame + (my-class standard-application-frame) + () + (:panes + (title :title :display-string "My title") + (app :application :display-function 'my-display)) + (:layouts + (default + (vertically () title app)))) + diff --git a/packages.lisp b/packages.lisp deleted file mode 100644 index e69de29..0000000 --- a/packages.lisp +++ /dev/null diff --git a/simple-text-clim-frame.asd b/simple-text-clim-frame.asd index e69de29..08afcb3 100644 --- a/simple-text-clim-frame.asd +++ b/simple-text-clim-frame.asd @@ -0,0 +1,6 @@ +(defsystem + simple-text-clim-frame + :class :package-inferred-system + :depends-on (:simple-text-clim-frame/frame) + :components + ((:static-file "some.text"))) @@ -0,0 +1,7 @@ +this + is + some + text + ! ,,,, + checking commas work + is a lisp thing. |
