#63 TimeScale: Issues with daily scale during DST change

open
nobody
None
5
2009-03-12
2009-03-12
No

When timescale is building values, it assumes every day is 24 hours long, which is not true during the DST switch. This causes weird placement of grid lines and labels.

Building the day scale like the month scale solved the problem for me- I changed my Timescale::values() like this:
...
if (span < Dates.DAYS) {
for (var x:Number = _smin.time; x <= max; x += step) {
a.push(new Date(x));
}
} else if (span == Dates.DAYS) {
for (; d.time <= max; d = Dates.addDays(d,1)) {
a.push(d);
}
} else if (span == Dates.MONTHS) {
for (; d.time <= max; d = Dates.addMonths(d,1)) {
a.push(d);
}
} else {
...

Discussion


Log in to post a comment.