summaryrefslogtreecommitdiffabout
path: root/korganizer/koagendaview.cpp
authorzautrix <zautrix>2005-04-01 18:10:09 (UTC)
committer zautrix <zautrix>2005-04-01 18:10:09 (UTC)
commitedc032c21ae3788d02a632ea8066e4ac5a4feedb (patch) (side-by-side diff)
tree8e59c8dcf1cc3021694025627d36e152f7adc389 /korganizer/koagendaview.cpp
parent5d88f92b76a760f100384ea5fa6ed143088d19bb (diff)
downloadkdepimpi-edc032c21ae3788d02a632ea8066e4ac5a4feedb.zip
kdepimpi-edc032c21ae3788d02a632ea8066e4ac5a4feedb.tar.gz
kdepimpi-edc032c21ae3788d02a632ea8066e4ac5a4feedb.tar.bz2
fixes
Diffstat (limited to 'korganizer/koagendaview.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/koagendaview.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/korganizer/koagendaview.cpp b/korganizer/koagendaview.cpp
index 218396d..072d464 100644
--- a/korganizer/koagendaview.cpp
+++ b/korganizer/koagendaview.cpp
@@ -120,5 +120,6 @@ void TimeLabels::drawContents(QPainter *p,int cx, int cy, int cw, int ch)
// these two assignments fix the weird redraw bug
+ mRedrawNeeded = true;
if ( mRedrawNeeded ) {
- cx = contentsX() + 2;
- cw = contentsWidth() - 2;
+ cx = contentsX() + frameWidth()*2;
+ cw = contentsWidth() ;
// end of workaround
@@ -154,3 +155,3 @@ void TimeLabels::drawContents(QPainter *p,int cx, int cy, int cw, int ch)
}
- timeHeight -= (timeHeight/4-2);
+ //timeHeight -= (timeHeight/4-2);
QFont sFont = nFont;
@@ -159,4 +160,4 @@ void TimeLabels::drawContents(QPainter *p,int cx, int cy, int cw, int ch)
int sHei = fmS.height();
- sHei -= (sHei/4-2);
- int startW = this->width() - frameWidth();
+ //sHei -= (sHei/4-2);
+ int startW = this->width() - frameWidth()-1;
while (y < cy + ch) {
@@ -175,3 +176,3 @@ void TimeLabels::drawContents(QPainter *p,int cx, int cy, int cw, int ch)
// center and draw the time label
- int timeWidth = fm.width(hour+"i");
+ int timeWidth = fm.width(hour);
int tw2 = fm.width(suffix);
@@ -179,6 +180,6 @@ void TimeLabels::drawContents(QPainter *p,int cx, int cy, int cw, int ch)
p->setFont( nFont );
- p->drawText(cx - borderWidth + offset, y+ timeHeight, hour);
+ p->drawText( offset, y+ timeHeight, hour);
p->setFont( sFont );
- offset = startW - tw2-1;
- p->drawText(cx - borderWidth + offset, y+ sHei, suffix);
+ offset = startW - tw2+1;
+ p->drawText( offset, y+ sHei, suffix);
@@ -420,4 +421,3 @@ KOAgendaView::KOAgendaView(Calendar *cal,QWidget *parent,const char *name) :
widebut = heibut ;
- if ( QApplication::desktop()->width() < 480 )
- widebut = widebut*3/2;
+
//mExpandButton->setSizePolicy( QSizePolicy( QSizePolicy::Fixed,
@@ -719,3 +719,3 @@ void KOAgendaView::createDayLabels()
}
- dayLabel->setFixedWidth( mTimeLabels->width()+2 );
+ dayLabel->setFixedWidth( mTimeLabels->width()+mAgenda->frameWidth() );
dayLabel->setFont( dlf );
@@ -830,4 +830,4 @@ void KOAgendaView::createDayLabels()
//dayLabel->hide();//test only
-
- int offset = (mAgenda->width() - mAgenda->verticalScrollBar()->width()-3 ) % mSelectedDates.count() ;
+ qDebug("fremwidd %d ", mAgenda->frameWidth());
+ int offset = (mAgenda->width() - mAgenda->verticalScrollBar()->width()- (mAgenda->frameWidth()*2) ) % mSelectedDates.count() ;
if ( offset < 0 ) offset = 0;