aboutsummaryrefslogtreecommitdiff
path: root/README
diff options
context:
space:
mode:
authorAdrian C. (anrxc) <anrxc@sysphere.org>2010-10-04 22:42:31 +0200
committerAdrian C. (anrxc) <anrxc@sysphere.org>2010-10-04 22:42:31 +0200
commite51d8ac39e67fdbd5ce26c024f1a85497dc7bc86 (patch)
tree9786249e6b1361655a442146c71c3653cc9d1b6c /README
parentc6085eef0648f54e1c70c92c544a89d9bb3d22c2 (diff)
downloadvicious-legacy-e51d8ac39e67fdbd5ce26c024f1a85497dc7bc86.tar.xz
date: turn time widget argument into an offset
The os.time() call should not be passed as an argument it self, because of a chance it will be stored internally and so we would always get the same time. Instead we can pass time offsets in seconds, i.e. to go 6 hours forward we can use the widget argument 21600, to go 6 hours back we use -21600 instead.
Diffstat (limited to 'README')
-rw-r--r--README7
1 files changed, 4 insertions, 3 deletions
diff --git a/README b/README
index f135209..c038eaf 100644
--- a/README
+++ b/README
@@ -266,9 +266,10 @@ vicious.widgets.weather
vicious.widgets.date
- provides access to os.date, with optional time formatting provided
- as the format string
- - takes optional time as an argument, for example to calculate
- time-zone differences, otherwise it formats the current time
+ as the format string - using regular date sequences
+ - takes optional time offset, in seconds, as an argument for example
+ to calculate time zone differences, otherwise current time is
+ formatted
- returns the output of os.date(), formatted by provided sequences