summaryrefslogtreecommitdiffabout
path: root/korganizer/koagendaitem.cpp
Side-by-side diff
Diffstat (limited to 'korganizer/koagendaitem.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/koagendaitem.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/korganizer/koagendaitem.cpp b/korganizer/koagendaitem.cpp
index abb29f7..f855b03 100644
--- a/korganizer/koagendaitem.cpp
+++ b/korganizer/koagendaitem.cpp
@@ -449,69 +449,65 @@ void KOAgendaItem::paintMe( bool selected, QPainter* paint )
align = ( AlignHCenter|BreakAnywhere|WordBreak|AlignTop);
#endif
}
}
QRect dr;
if ( w + x > parentWidget()->width() )
w = parentWidget()->width()-x;
paint->drawText ( x, yy, w, h, align, mDisplayedText, -1, &dr );
//qDebug("%d %d %d %d ", x, yy, w, h );
if ( mIncidence->cancelled() ){
small = ( height() < 20 );
if ( ! small ) {
QFontMetrics fm ( paint->font() );
paint->drawLine(dr.left(), yy+fm.height()/2, dr.right()-2, yy+fm.height()/2);
}
}
pa.end();
}
-void KOAgendaItem::resizePixmap( int w , int h )
-{
- paintPix()->resize( w, h );
-}
QPixmap * KOAgendaItem::paintPix()
{
static QPixmap* mPaintPix = 0;
if ( ! mPaintPix ) {
int w = QApplication::desktop()->width();
int h = QApplication::desktop()->height();
mPaintPix = new QPixmap(w,h);
}
return mPaintPix ;
}
QPixmap * KOAgendaItem::paintPixAllday()
{
static QPixmap* mPaintPixA = 0;
if ( ! mPaintPixA ) {
int w = QApplication::desktop()->width();
- int h = QApplication::desktop()->height()/3;
+ int h = QApplication::desktop()->height()/5;
mPaintPixA = new QPixmap(w,h);
}
return mPaintPixA ;
}
void KOAgendaItem::paintEvent ( QPaintEvent *e )
{
if ( globalFlagBlockAgendaItemPaint )
return;
if ( globalFlagBlockAgenda > 0 && globalFlagBlockAgenda < 5 )
return;
int yy;
if ( mAllDay )
yy = y();
else
yy = mCellYTop * ( height() / cellHeight() );
int xx = x();
if ( xPaintCoord != xx || yPaintCoord != yy ||
wPaintCoord != width() || hPaintCoord != height()) {
xPaintCoord= xx;
yPaintCoord = yy;
wPaintCoord = width();