-rw-r--r-- | korganizer/kolistview.cpp | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/korganizer/kolistview.cpp b/korganizer/kolistview.cpp index b378330..192f8c0 100644 --- a/korganizer/kolistview.cpp +++ b/korganizer/kolistview.cpp | |||
@@ -1406,6 +1406,7 @@ void KOListViewListView::printList() | |||
1406 | clearSelection (); | 1406 | clearSelection (); |
1407 | QPainter p; | 1407 | QPainter p; |
1408 | p.begin ( &printer ); | 1408 | p.begin ( &printer ); |
1409 | p.setFont(font()); | ||
1409 | QPaintDeviceMetrics m = QPaintDeviceMetrics ( &printer ); | 1410 | QPaintDeviceMetrics m = QPaintDeviceMetrics ( &printer ); |
1410 | float dx, dy; | 1411 | float dx, dy; |
1411 | int wid = (m.width() * 9)/10; | 1412 | int wid = (m.width() * 9)/10; |
@@ -1432,7 +1433,26 @@ void KOListViewListView::printList() | |||
1432 | header()->paintSection ( & p, header()->mapToIndex (iii), rect ); | 1433 | header()->paintSection ( & p, header()->mapToIndex (iii), rect ); |
1433 | } | 1434 | } |
1434 | p.translate( 0, header()->height()); | 1435 | p.translate( 0, header()->height()); |
1435 | drawContentsOffset ( &p, 0,0, 0,0, contentsWidth (), contentsHeight () ); | 1436 | //drawContentsOffset ( &p, 0,0, 0,0, contentsWidth (), contentsHeight () ); |
1437 | |||
1438 | const QColorGroup &cg = colorGroup(); | ||
1439 | KOListViewItem* item = (KOListViewItem* )firstChild(); | ||
1440 | int yOff = 0; | ||
1441 | while ( item ) { | ||
1442 | p.translate( 0, yOff ); | ||
1443 | p.save(); | ||
1444 | for ( iii = 0; iii < cou; ++iii ) { | ||
1445 | int align = columnAlignment( iii ); | ||
1446 | if ( align == AlignAuto ) align = AlignLeft; | ||
1447 | p.restore(); | ||
1448 | p.save(); | ||
1449 | p.translate( header()->sectionPos( iii ), 0); | ||
1450 | item->paintCell( &p, cg, iii, header()->sectionSize (iii), align ); | ||
1451 | } | ||
1452 | yOff = item->height(); | ||
1453 | item = (KOListViewItem* )(item->itemBelow()); | ||
1454 | p.restore(); | ||
1455 | } | ||
1436 | p.end(); | 1456 | p.end(); |
1437 | #endif | 1457 | #endif |
1438 | } | 1458 | } |