diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2022-06-23 03:23:44 +0200 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2022-06-23 03:48:22 +0200 |
commit | 1976980d4a272fb7fc3694c734bfc6825edfc721 (patch) | |
tree | 8460db1176c64895e9968447588953fac85fe7d6 /module/vcomponent/datetime/output.scm | |
parent | Remove all inline use-modules. (diff) | |
download | calp-1976980d4a272fb7fc3694c734bfc6825edfc721.tar.gz calp-1976980d4a272fb7fc3694c734bfc6825edfc721.tar.xz |
Centralize (almost) all exports to :export in define-module.
Diffstat (limited to '')
-rw-r--r-- | module/vcomponent/datetime/output.scm | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/module/vcomponent/datetime/output.scm b/module/vcomponent/datetime/output.scm index b75fd564..614438da 100644 --- a/module/vcomponent/datetime/output.scm +++ b/module/vcomponent/datetime/output.scm @@ -5,11 +5,15 @@ :use-module (text util) :use-module (calp translation) :use-module ((hnh util exceptions) :select (warning)) - ) + :export (format-recurrence-rule + format-summary + format-description + fmt-time-span + )) ;; ev → sxml ;; TODO translation -(define-public (format-recurrence-rule ev) +(define (format-recurrence-rule ev) ;; [FRR] ;; Part of the sentance "Repeated [every two weeks], except on ~a, ~a & ~a" ;; See everything tagged [FRR] @@ -37,11 +41,11 @@ (map value it))))) ".")) -(define-public (format-summary ev str) +(define (format-summary ev str) ((@ (calp html filter) summary-filter) ev str)) ;; NOTE this should have information about context (html/term/...) -(define-public (format-description ev str) +(define (format-description ev str) (catch #t (lambda () ((@ (calp html filter) description-filter) ev str)) (lambda (err . args) @@ -53,7 +57,7 @@ ;; Takes an event, and returns a pretty string for the time interval ;; the event occupies. -(define-public (fmt-time-span ev) +(define (fmt-time-span ev) (cond [(prop ev 'DTSTART) date? => (lambda (s) (cond [(prop ev 'DTEND) |