[kronolith] Render error in week view

Colin Burnett cburnett@candysporks.org
Tue, 24 Sep 2002 19:45:12 -0500


I'm currently running 1.0 of Kronolith and 2.0 of Horde.

When rendering the week view, it miscalculates the colspan of some events in the
circumstances permit.

I have two events at 9am and 4 events at 6pm.  The maxspan of that day is 4
which leavs the colspan for the two 9am events is 4-2+1=3 but it should be 2. 
So i get 6 columns taken up for a 4 column day...which throws the rest of the
days off by 2 columns as well.  (Which I figured out by delving into
/lib/WeekView.php and /lib/DayView.php and echoing out the values.)

I tried doing a search on the archive for something like this but couldn't find
anything.

In trying to understand the parsing algorithm in the DayView.php file, I came up
with a suggestion.  First an example.  If you have two events at one time and
three events at another time (same day) then the two events have to split three
columns (maxspan=3).  I suggest setting maxspan to the LCM of the overlap
values.  So in this case, LCM(2,3)=6 which splits all five events up evenly.  I
would be willing to code it out, but alas my list of projects is quite long.

So I suppose this is a bug/suggestion email. :)
-- 


Colin