* guile: some internal improvements

This commit is contained in:
djcb
2012-07-12 15:46:19 +03:00
parent 62489a31d0
commit c2676540d0
3 changed files with 59 additions and 39 deletions

View File

@ -29,7 +29,7 @@ Sun..Sat) that match EXPR. If PLAIN-TEXT is true, use a plain-text
display, otherwise, use a graphical window."
(mu:plot
(sort
(mu:tabulate-messages
(mu:tabulate
(lambda (msg)
(tm:hour (localtime (mu:date msg)))) expr)
(lambda (x y) (< (car x) (car y))))
@ -41,7 +41,7 @@ Sun..Sat) that match EXPR. If PLAIN-TEXT is true, use a plain-text
display, otherwise, use a graphical window."
(mu:plot
(mu:weekday-numbers->names
(sort (mu:tabulate-messages
(sort (mu:tabulate
(lambda (msg)
(tm:wday (localtime (mu:date msg)))) expr)
(lambda (x y) (< (car x) (car y)))))
@ -54,7 +54,7 @@ display, otherwise, use a graphical window."
(mu:plot
(mu:month-numbers->names
(sort
(mu:tabulate-messages
(mu:tabulate
(lambda (msg)
(tm:mon (localtime (mu:date msg)))) expr)
(lambda (x y) (< (car x) (car y)))))
@ -66,10 +66,10 @@ display, otherwise, use a graphical window."
Sun..Sat) that match EXPR. If PLAIN-TEXT is true, use a plain-text
display, otherwise, use a graphical window."
(mu:plot
(sort (mu:tabulate-messages
(sort (mu:tabulate
(lambda (msg)
(string->number
(format #f "~d~2'0d"
(format #f "~d~2'0d"
(+ 1900 (tm:year (localtime (mu:date msg))))
(tm:mon (localtime (mu:date msg))))))
expr)
@ -84,7 +84,7 @@ display, otherwise, use a graphical window."
Sun..Sat) that match EXPR. If PLAIN-TEXT is true, use a plain-text
display, otherwise, use a graphical window."
(mu:plot
(sort (mu:tabulate-messages
(sort (mu:tabulate
(lambda (msg)
(+ 1900 (tm:year (localtime (mu:date msg))))) expr)
(lambda (x y) (< (car x) (car y))))
@ -118,7 +118,7 @@ display, otherwise, use a graphical window."
((string= what "per-hour") (per-hour expr text))
((string= what "per-day") (per-day expr text))
((string= what "per-month") (per-month expr text))
((string= what "per-year-month") (per-year-month expr text))
((string= what "per-year-month") (per-year-month expr text))
((string= what "per-year") (per-year expr text))
(else (begin
(display msg)