PDA

View Full Version : Calendar Widget - Change cell colour



Gavin Harper
15th March 2011, 07:57
I would like to change individual cells of the calendar widget to match values stored in a DB, I.e the cell of days matching a certain event are a certain colour.

I cannot find anything directly relating to this issue in the documentation.

I am otherwise entirely satisfied with the Calendar widget implemented in my application so if I can change this directly as opposed to build a calendar from a table widget, I'd like that.

Thank you

Ginsengelf
15th March 2011, 08:31
Hi, maybe you can overload QCalendarwidget::paintCell() and paint the cell in the color of your choice.

Ginsengelf