summaryrefslogtreecommitdiff
path: root/class.lisp
diff options
context:
space:
mode:
authorscrewlisp <screwtape@sdf.org>2026-07-02 23:19:05 +1200
committerscrewlisp <screwtape@sdf.org>2026-07-02 23:19:05 +1200
commit2e0110e9e99034f49a59d68af509ae3015184b7a (patch)
tree86a30d5fe0a3cb6633d09b956c7be1d2f57397df /class.lisp
parent4bbc0b00023cc8b7db24142febb8695838b78752 (diff)
just use package inferred.
Diffstat (limited to 'class.lisp')
-rw-r--r--class.lisp27
1 files changed, 27 insertions, 0 deletions
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)))
+