aboutsummaryrefslogtreecommitdiff
path: root/module/vcalendar.scm
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2019-03-31 00:12:37 +0100
committerHugo Hörnquist <hugo@lysator.liu.se>2019-03-31 00:12:37 +0100
commit5b782cce0b60f67ca06085bb7a48528ce5a14987 (patch)
tree1a29d3d90830f3c07ee12f6ce744f6abe34b235b /module/vcalendar.scm
parentAdd as-{string,symb}. (diff)
downloadcalp-5b782cce0b60f67ca06085bb7a48528ce5a14987.tar.gz
calp-5b782cce0b60f67ca06085bb7a48528ce5a14987.tar.xz
Add (read only) property access from scheme.
Diffstat (limited to 'module/vcalendar.scm')
-rw-r--r--module/vcalendar.scm12
1 files changed, 12 insertions, 0 deletions
diff --git a/module/vcalendar.scm b/module/vcalendar.scm
index 51c4f8e3..0f1a3c57 100644
--- a/module/vcalendar.scm
+++ b/module/vcalendar.scm
@@ -39,6 +39,18 @@
component
(as-string attr)))
+(define (get-property component attr prop)
+ (%vcomponent-get-property
+ component
+ (as-string attr)
+ (as-string prop)))
+
+;; TODO replace this with procedure-with-setter
+(define-public prop get-property)
+
+(define-public (properties component attr)
+ (%vcomponent-property-list component (as-string attr)))
+
;; Enables symmetric get and set:
;; (set! (attr ev "KEY") 10)
(define-public attr (make-procedure-with-setter get-attr set-attr!))