Fix for calendar
Paul van Tilburg
paul at luon.net
Tue Sep 12 14:22:29 EDT 2006
Hey all,
I've found that using the calender in a relatively small sidebar it
behaves a bit obnoxious. The main cause of this, is that it wants to be
bigger than required because of the fillers at the end.
When is this the case? This is the case when a month is longer then >
28 days, which is almost all. Since it tries to fill with (7 - offset)
at the end, it produces (days_in_the_month - 28) too many fillers.
An example:
Mo Tu We Th Fr Sa Su
F F F F 1 2 3 # offset is 4 (fillers placed)
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 F F F # so 3 fillers added here
We can:
* Do use heuristics using the number of days in a month.
* Remove the fillers at the end all together.
I am currently using the latter option and can commit that, but maybe I
haven't though of someting? If there are objections, please let me know,
otherwise I will commit a fix soon.
Regards,
Paul
P.S. My Hobix stopped generating index pages anymore for the sections
(i.e. /life/index.html, /life/study/index.html, etc.), anyone any
idea why?
--
Student @ Eindhoven | email: paul at luon.net
University of Technology, The Netherlands | JID: paul at luon.net
>>> Using the Power of Debian GNU/Linux <<< | GnuPG key ID: 0x50064181
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://rubyforge.org/pipermail/hobix-is-the-way/attachments/20060912/29517b8c/attachment.bin
More information about the Hobix-is-the-way
mailing list