diff options
author | Hugo Hörnquist <hugo@hornquist.se> | 2019-04-23 17:11:27 +0200 |
---|---|---|
committer | Hugo Hörnquist <hugo@hornquist.se> | 2019-04-23 17:11:27 +0200 |
commit | 40c20dd98f31138cb4e27e6ab8ccfe16c250179d (patch) | |
tree | 193acb6f1d70d3560bc5c61c70f6a047b9ced9fa | |
parent | Rewrote fix-event-widths! (diff) | |
download | calp-40c20dd98f31138cb4e27e6ab8ccfe16c250179d.tar.gz calp-40c20dd98f31138cb4e27e6ab8ccfe16c250179d.tar.xz |
Reorder CSS output for event size.
Diffstat (limited to '')
-rw-r--r-- | module/html/html.scm | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/module/html/html.scm b/module/html/html.scm index 6c77030b..afe34963 100644 --- a/module/html/html.scm +++ b/module/html/html.scm @@ -69,7 +69,11 @@ never on absolute times. For that see date->decimal-hour" (define (vevent->sxml day ev) (define time (date->time-utc day)) (define style - (format #f "top: ~,3f%; left: ~,3f%; height: ~,3f%; width: ~,3f%;" + (format #f "left:~,3f%;width:~,3f%;top:~,3f%;height:~,3f%;" + + (* 100 (x-pos ev)) ; left + (* 100 (width ev)) ; width + ;; top (if (in-day? day (attr ev 'DTSTART)) (* (/ 24) 100 @@ -78,9 +82,6 @@ never on absolute times. For that see date->decimal-hour" (start-of-day* (attr ev 'DTSTART))))) 0) - ;; left - (* 100 (x-pos ev)) - ;; height (* (/ 24) 100 (time->decimal-hour @@ -98,11 +99,8 @@ never on absolute times. For that see date->decimal-hour" (attr ev 'DTSTART)) ;; start earlier, end earlier (time-difference (add-day time) - time))))) + time))))))) - ;; width - (* 100 (width ev)) - )) `(div (@ (class "event CAL_" ,(html-attr (let ((l (attr (parent ev) 'NAME))) (if (pair? l) (car l) l))) ,(if (time<? (attr ev 'DTSTART) time) |