sw/source/core/text/porrst.cxx | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-)
New commits: commit 5a49362a9c75566568e18fff973635a53b9e594e Author: Jan Holesovsky <ke...@collabora.com> Date: Thu Jul 24 12:06:11 2014 +0200 fdo#80721: Use the old way of drawing the pilcrow (but with changed color). This fixes the reported problem (that the pilcrow stopped showning for centered paragraphs), and additionally makes the pilcrow large for large paragraphs (like titles) again. Change-Id: I78d9986c0da6abfb9936984bb8b72d5eba88c9d7 Reviewed-on: https://gerrit.libreoffice.org/10501 Reviewed-by: Caolán McNamara <caol...@redhat.com> Tested-by: Caolán McNamara <caol...@redhat.com> diff --git a/sw/source/core/text/porrst.cxx b/sw/source/core/text/porrst.cxx index 8aed6aa..68af074 100644 --- a/sw/source/core/text/porrst.cxx +++ b/sw/source/core/text/porrst.cxx @@ -59,13 +59,22 @@ SwTmpEndPortion::SwTmpEndPortion( const SwLinePortion &rPortion ) void SwTmpEndPortion::Paint( const SwTxtPaintInfo &rInf ) const { - if( rInf.OnWin() && rInf.GetOpt().IsParagraph() ) + if (rInf.OnWin() && rInf.GetOpt().IsParagraph()) { #ifdef LEGACY_NON_PRINTING_CHARACTER_COLOR_FUNCTIONALITY const OUString aTmp( CH_PAR ); rInf.DrawText( aTmp, *this ); #else - rInf.DrawSpecial( *this, CH_PAR, Color(NON_PRINTING_CHARACTER_COLOR) ); + const SwFont* pOldFnt = rInf.GetFont(); + + SwFont aFont(*pOldFnt); + aFont.SetColor(NON_PRINTING_CHARACTER_COLOR); + const_cast<SwTxtPaintInfo&>(rInf).SetFont(&aFont); + + // draw the pilcrow + rInf.DrawText(OUString(CH_PAR), *this); + + const_cast<SwTxtPaintInfo&>(rInf).SetFont(const_cast<SwFont*>(pOldFnt)); #endif } }
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits