I'm testing the free version at the moment before taking the plunge.
I've edited the source a little to allow events to have different colored backgrounds on screen.
Most browsers default to not printing background colors or images, therefore when printing a calendar, the calendar hour lines show through the Event DIV which makes the whole thing look untidy and unclear.
Is there an easy way to fix this other than asking users to change their browser options?
steve65
-
6/11/2007 5:26:51 PM
I've just tried print preview in FF2 and IE7. While Firefox output is not so bad, IE does exactly what you describe.
The problem is that DayPilot was not designed to be printable. I think it would be better to have a special DayPilot control that would be printer-friendly (otherwise it's like designing for at least three other "browsers" - IE6/7 and FF print previews).
The white background might be created using a white 1x1 pixel image stretched on an underlying div (... not so easy). That's what I would probably try first.
Thanks for your reply, I've tried quite a few solutions without success but I think I've finally settled on the following
in the daypilotcalendar renderevent function
I added
output.AddStyleAttribute("border-left", "1px solid " + stringFromColor(EventBorderColor));
output.AddStyleAttribute("border-right", "1px solid " + stringFromColor(EventBorderColor));
output.AddStyleAttribute("border-top", "1px solid " + stringFromColor(EventBorderColor));
output.AddStyleAttribute("border-bottom", "1px solid " + stringFromColor(EventBorderColor));
I then removed
divFix.AddStyleAttribute("border-left", "1px solid " + stringFromColor(EventBorderColor));
divFix.AddStyleAttribute("border-right", "1px solid " + stringFromColor(EventBorderColor));
This gives each event a better defined border when printing in ie6/7 and firefox, so the hourlines showing through are not such an issue.
Let me know if you think that breaks anything else.
steve65
-
6/12/2007 12:09:33 PM
This should work fine. You just need to keep margin-top set to 1px and height set to 2px less than full height. You can even remove
output.AddStyleAttribute("background-color", stringFromColor(EventBorderColor));
from the main DIV definition.