author | zautrix <zautrix> | 2005-03-22 14:59:07 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-03-22 14:59:07 (UTC) |
commit | 0fe23b2c9b74bac46f409098f950259bffbdbe3c (patch) (side-by-side diff) | |
tree | 80b4077661301ee3216217dfcb0bc9fd0a74b7d7 | |
parent | 03b3e902ed6362d8f72d0acfc5a9be9d9ee1ef21 (diff) | |
download | kdepimpi-0fe23b2c9b74bac46f409098f950259bffbdbe3c.zip kdepimpi-0fe23b2c9b74bac46f409098f950259bffbdbe3c.tar.gz kdepimpi-0fe23b2c9b74bac46f409098f950259bffbdbe3c.tar.bz2 |
more layout fixes
-rw-r--r-- | korganizer/datenavigatorcontainer.cpp | 7 | ||||
-rw-r--r-- | korganizer/kodaymatrix.cpp | 2 |
2 files changed, 4 insertions, 5 deletions
diff --git a/korganizer/datenavigatorcontainer.cpp b/korganizer/datenavigatorcontainer.cpp index 6de7c45..9720146 100644 --- a/korganizer/datenavigatorcontainer.cpp +++ b/korganizer/datenavigatorcontainer.cpp @@ -305,52 +305,50 @@ void DateNavigatorContainer::resizeEvent( QResizeEvent * e ) if ( horizontalCount == 0 ) horizontalCount = 1; if ( verticalCount == 0 ) verticalCount = 1; fontchange = true; count = horizontalCount * verticalCount; } else { if ( mNavigatorView->fontChanged() ) { fontchange = true; fo = KOPrefs::instance()->mDateNavigatorFont; mNavigatorView->changeFont( fo ); mNavigatorView->unsetFontChanged(); } } mLastDisplayedDN = horizontalCount*verticalCount-1; - bool setBaseD = false; while ( count > ( mExtraViews.count() + 1 ) ) { KDateNavigator *n = new KDateNavigator( this ); n->setMonthSignalOffset ( mExtraViews.count()+1 ); mExtraViews.append( n ); n->setCalendar( mCalendar ); - setBaseD = true; connectNavigatorView( n ); n->show(); } int iii = 0; while ( iii < ( mExtraViews.count() ) ) { if ( iii < count-1 ) mExtraViews.at( iii )->show(); else mExtraViews.at( iii )->hide(); ++iii; } - if ( setBaseD ) - setBaseDates(); + + setBaseDates(); if ( fontchange ) { //mNavigatorView->changeFont( fo ); uint i; for( i = 0; i < mExtraViews.count(); ++i ) { KDateNavigator *view = mExtraViews.at( i ); view->changeFont( fo ); } } mHorizontalCount = horizontalCount; mVerticalCount = verticalCount; } //qDebug("COUNT %d ", mExtraViews.count()); int height = size().height() / verticalCount; int width = size().width() / horizontalCount; @@ -361,27 +359,28 @@ void DateNavigatorContainer::resizeEvent( QResizeEvent * e ) mNavigatorView->setGeometry(0, 0, width, height ); for( uint i = 0; i < mLastDisplayedDN; ++i ) { int x = ( i + 1 ) % horizontalCount; int y = ( i + 1 ) / horizontalCount; KDateNavigator *view = mExtraViews.at( i ); bar = view->navigatorBar(); if ( y > 0 ) bar->showButtons( false, false ); else { if ( x + 1 == horizontalCount ) bar->showButtons( false, true ); else bar->showButtons( false, false ); } view->setGeometry( x * width, y * height, width, height ); } + //updateDayMatrixDates(); } QSize DateNavigatorContainer::minimumSizeHint() const { return mNavigatorView->minimumSizeHint(); } QSize DateNavigatorContainer::sizeHint() const { return mNavigatorView->yourSizeHint(); } diff --git a/korganizer/kodaymatrix.cpp b/korganizer/kodaymatrix.cpp index 3ee1fa7..366e8b8 100644 --- a/korganizer/kodaymatrix.cpp +++ b/korganizer/kodaymatrix.cpp @@ -90,33 +90,33 @@ void DynamicTip::maybeTip( const QPoint &pos ) //show holiday names only QString str = matrix->getHolidayLabel(col+row*7); if (str.isEmpty()) return; tip(rct, str); } // ============================================================================ // K O D A Y M A T R I X // ============================================================================ const int KODayMatrix::NOSELECTION = -1000; const int KODayMatrix::NUMDAYS = 42; KODayMatrix::KODayMatrix( QWidget *parent, const char *name ) - : QFrame( parent, name ), mCalendar( 0 ) + : QFrame( parent, name , Qt::WRepaintNoErase ), mCalendar( 0 ) #if 0 KODayMatrix::KODayMatrix(QWidget *parent, Calendar* calendar, QDate date, const char *name) : QFrame(parent, name) #endif { mKODaymatrixWhatsThis = new KODaymatrixWhatsThis(this); mPendingUpdateBeforeRepaint = false; mouseDown = false; // initialize dynamic arrays bDays.resize ( NUMDAYS ); days = new QDate[NUMDAYS]; daylbls = new QString[NUMDAYS]; events = new int[NUMDAYS]; mToolTip = new DynamicTip(this); |