From a113501901055bb1a650b56d3ff7e0b1319d82af Mon Sep 17 00:00:00 2001 From: michael Date: Wed, 18 Jul 2018 11:50:35 +0000 Subject: [PATCH] * Patch from Petr-K to fix underline and strikethrough (Bug ID 34000) git-svn-id: trunk@39467 - --- packages/fcl-pdf/src/fppdf.pp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/fcl-pdf/src/fppdf.pp b/packages/fcl-pdf/src/fppdf.pp index d7e831cbb8..be50ccea16 100644 --- a/packages/fcl-pdf/src/fppdf.pp +++ b/packages/fcl-pdf/src/fppdf.pp @@ -3439,8 +3439,8 @@ begin { line segment is relative to matrix translation coordinate, set above } if Underline then - WriteString(Format('0 -1.5 m %s -1.5 l S', [FloatStr(mmToPDF(lTextWidthInMM))]) + CRLF, AStream) - else + WriteString(Format('0 -1.5 m %s -1.5 l S', [FloatStr(mmToPDF(lTextWidthInMM))]) + CRLF, AStream); + if StrikeThrough then WriteString(Format('0 %s m %s %0:s l S', [FloatStr(mmToPDF(lTextHeightInMM) / 2), FloatStr(mmToPDF(lTextWidthInMM))]) + CRLF, AStream); { restore graphics state to before the translation matrix adjustment }