From 40c0ff75d2a0f987454b068a663908e6d9b87b9b Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Tue, 13 Mar 2012 10:33:10 +0100 Subject: TextEngine::SeekCursor needs to call SetFont after all 10f28d5c9a072bf108a79f3b05ad8247ca0dcea5 "callcatcher: build fixes" had removed this with the comment "SetFont() doesn't do anything" but that is clearly wrong: Without this, e.g. bold text within text fields is not displayed as such (e.g., "File - New - Templates and Documnets - Templates - Presentation Backgrounds - Black and White": the captions in the right hand pane ("Title:", "Date:", etc.) should be bold). --- svtools/source/edit/texteng.cxx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'svtools') diff --git a/svtools/source/edit/texteng.cxx b/svtools/source/edit/texteng.cxx index 6baf8a9c4eb1..30aef8f319f6 100644 --- a/svtools/source/edit/texteng.cxx +++ b/svtools/source/edit/texteng.cxx @@ -1476,7 +1476,11 @@ void TextEngine::SeekCursor( sal_uLong nPara, sal_uInt16 nPos, Font& rFont, Outp if ( ( ( pAttrib->GetStart() < nPos ) && ( pAttrib->GetEnd() >= nPos ) ) || !pNode->GetText().Len() ) { - if ( pAttrib->Which() == TEXTATTR_FONTCOLOR ) + if ( pAttrib->Which() != TEXTATTR_FONTCOLOR ) + { + pAttrib->GetAttr().SetFont(rFont); + } + else { if ( pOutDev ) pOutDev->SetTextColor( ((TextAttribFontColor&)pAttrib->GetAttr()).GetColor() ); -- cgit