Added label clip path to page renderer.

This commit is contained in:
Jim Evins
2016-05-21 13:34:16 -04:00
parent 4cc6ddab6c
commit 91cefb7287
10 changed files with 87 additions and 15 deletions
+10
View File
@@ -38,6 +38,10 @@ namespace glabels
: mW(w), mH(h), mR(r), mXWaste(xWaste), mYWaste(yWaste), Frame(id)
{
mPath.addRoundedRect( 0, 0, mW.pt(), mH.pt(), mR.pt(), mR.pt() );
mClipPath.addRoundedRect( -mXWaste.pt(), -mYWaste.pt(),
mW.pt() + 2*mXWaste.pt(), mH.pt() + 2*mYWaste.pt(),
mR.pt(), mR.pt() );
}
@@ -108,6 +112,12 @@ namespace glabels
}
const QPainterPath& FrameRect::clipPath() const
{
return mClipPath;
}
QPainterPath FrameRect::marginPath( const Distance& size ) const
{
Distance w = mW - 2*size;