~neon/kolourpaint/master

« back to all changes in this revision

Viewing changes to views/kpView.cpp

  • Committer: Martin Koller
  • Date: 2011-02-07 22:13:51 UTC
  • Revision ID: git-v1:bc562d9cda59fbd08347bfa05309967931abaa25
Implement alpha channel (transparency) support by using QImage to paint onto
instead QPixmap.

BUG: 94607
BUG: 85280
BUG: 94445
BUG: 171762
BUG: 255278
BUG: 259994

svn path=/trunk/KDE/kdegraphics/kolourpaint/; revision=1219290

Show diffs side-by-side

added added

removed removed

Lines of Context:
420
420
        viewManager ()->restoreQueueUpdates ();
421
421
}
422
422
 
 
423
//---------------------------------------------------------------------
423
424
 
424
425
// public
425
426
double kpView::transformViewToDocX (double viewX) const
427
428
    return (viewX - origin ().x ()) * 100.0 / zoomLevelX ();
428
429
}
429
430
 
 
431
//---------------------------------------------------------------------
 
432
 
430
433
// public
431
434
double kpView::transformViewToDocY (double viewY) const
432
435
{
433
436
    return (viewY - origin ().y ()) * 100.0 / zoomLevelY ();
434
437
}
435
438
 
 
439
//---------------------------------------------------------------------
 
440
 
436
441
// public
437
442
QPoint kpView::transformViewToDoc (const QPoint &viewPoint) const
438
443
{
440
445
                   (int) transformViewToDocY (viewPoint.y ()));
441
446
}
442
447
 
 
448
//---------------------------------------------------------------------
 
449
 
443
450
// public
444
451
QRect kpView::transformViewToDoc (const QRect &viewRect) const
445
452
{
463
470
    }
464
471
}
465
472
 
 
473
//---------------------------------------------------------------------
466
474
 
467
475
// public
468
476
double kpView::transformDocToViewX (double docX) const