-rw-r--r-- | korganizer/kodaymatrix.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/korganizer/kodaymatrix.cpp b/korganizer/kodaymatrix.cpp index 619ae39..9181936 100644 --- a/korganizer/kodaymatrix.cpp +++ b/korganizer/kodaymatrix.cpp @@ -793,6 +793,17 @@ void KODayMatrix::paintEvent(QPaintEvent * pevent) void KODayMatrix::resizeEvent(QResizeEvent *) { QRect sz = frameRect(); daysize.setHeight(sz.height()*7 / NUMDAYS); daysize.setWidth(sz.width() / 7); } + +QSize KODayMatrix::sizeHint() const +{ + + QFontMetrics fm ( font() ); + int wid = fm.width( "30") *7+7; + int hei = fm.height() * 6+4; + //qDebug("KODayMatrix::sizeHint()********************* %d %d", wid , hei); + return QSize ( wid, hei ); + +} |