tags:

views:

172

answers:

1

Let's say that I have an application frame, and I want to show a popup QCalendarWidget over on the right side of the frame. Normally, QT will clip the edges of the QCalendarWidget, cutting it in half and not displaying the rest, as it would be over the right side border.

Is there a way to work around this limitation without resorting to implementing a QDialog?

I want the widget to be visible outside the bounds of it's container.

+1  A: 

If you'd show your Calendar, let's say, after a button click, as QDateTimeEditor does, it's contents will not be clipped, cause it do not belong to frame. It will be just a widget, that shows in a dialog manner. And maybe you should even place it in QDialog, that is modal and provides some convenience methods, rather then simple QWidget.

Btw, why don't you want to use QDatetimeEditor?

Max
I just checked, when using Qt 4.6 and the Eclipse Designer plugin, I don't get a button (by default) for a QDateTimeEdit control. I just get spinner arrows.
Chris Kaminski
You need to turn on calendarPopup property. setCalendarPopup(true)
Max