diff options
author | Caolán McNamara <caolanm@redhat.com> | 2013-11-01 15:05:15 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-11-01 15:05:30 +0000 |
commit | 55369420bd488411dd5428a66f4ad70c2ef9b007 (patch) | |
tree | 00f7877c7f1baa15f812986d991c963285b7ac56 /sw | |
parent | 0921642e7f15d3abf6a96e19529b313cf8fd1a8e (diff) |
stop unbalanced OutputDevice Push/Pop warnings on closing help
where it takes the early GetBackColor return after Push but before Pop
Change-Id: I5fac78b7270c8561cb8e7d26bd2bff44628c8547
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/text/inftxt.cxx | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/sw/source/core/text/inftxt.cxx b/sw/source/core/text/inftxt.cxx index 7ee6c8092769..1ff5a9cd2e1d 100644 --- a/sw/source/core/text/inftxt.cxx +++ b/sw/source/core/text/inftxt.cxx @@ -1182,17 +1182,22 @@ void SwTxtPaintInfo::DrawBackBrush( const SwLinePortion &rPor ) const // #i16816# tagged pdf support SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pTmpOut ); - pTmpOut->Push( PUSH_LINECOLOR | PUSH_FILLCOLOR ); + Color aFillColor; if( m_pFnt->GetHighlightColor() != COL_TRANSPARENT ) { - pTmpOut->SetFillColor( m_pFnt->GetHighlightColor() ); + aFillColor = m_pFnt->GetHighlightColor(); } else { - if( !m_pFnt->GetBackColor() ) return; - pTmpOut->SetFillColor( *m_pFnt->GetBackColor() ); + if( !m_pFnt->GetBackColor() ) + return; + aFillColor = *m_pFnt->GetBackColor(); } + + pTmpOut->Push( PUSH_LINECOLOR | PUSH_FILLCOLOR ); + + pTmpOut->SetFillColor(aFillColor); pTmpOut->SetLineColor(); DrawRect( aIntersect, sal_True, sal_False ); |