From 286870c70d5f7c20c7b6fd94625cb2d028102ee3 Mon Sep 17 00:00:00 2001 From: Graeme Geldenhuys Date: Fri, 7 Aug 2015 12:52:47 +0100 Subject: richview: fixes bug with Italic text adding an extra space at the end I thought I fixed all of these before, but I missed this one. --- docview/components/richtext/RichTextDisplayUnit.pas | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'docview/components/richtext') diff --git a/docview/components/richtext/RichTextDisplayUnit.pas b/docview/components/richtext/RichTextDisplayUnit.pas index 482a587b..613dba84 100644 --- a/docview/components/richtext/RichTextDisplayUnit.pas +++ b/docview/components/richtext/RichTextDisplayUnit.pas @@ -263,9 +263,10 @@ ProfileEvent('DEBUG: DrawRichTextLine >>>'); and ( faItalic in Style.FontAttributes ) and ( not FontManager.IsFixed ) then + begin // end of italic; add a space - inc( X, FontManager.CharWidth( ' ' ) ); - +// inc( X, FontManager.CharWidth( ' ' ) ); + end; Layout.PerformStyleTag( Element.Tag, Style, X ); NewMarginX := ( Start.X + Style.LeftMargin ); if NewMarginX > X then -- cgit v1.2.3-70-g09d2