From fe7f95b869704735801cb23a56a1fafddf01c531 Mon Sep 17 00:00:00 2001 From: ondrej Date: Thu, 19 Apr 2018 09:59:07 +0000 Subject: [PATCH] LCL: remove double with, issue #33609 git-svn-id: trunk@57671 - --- lcl/include/font.inc | 38 ++++++++++++++++---------------------- 1 file changed, 16 insertions(+), 22 deletions(-) diff --git a/lcl/include/font.inc b/lcl/include/font.inc index c6d65e35f7..492efb1d3c 100644 --- a/lcl/include/font.inc +++ b/lcl/include/font.inc @@ -689,28 +689,22 @@ var begin BeginUpdate; try - with ALogFont do - begin - Height := ALogFont.lfHeight; - Charset := TFontCharset(ALogFont.lfCharSet); - AStyle := []; - with ALogFont do - begin - if lfWeight >= FW_SEMIBOLD then Include(AStyle, fsBold); - if lfItalic <> 0 then Include(AStyle, fsItalic); - if lfUnderline <> 0 then Include(AStyle, fsUnderline); - if lfStrikeOut <> 0 then Include(AStyle, fsStrikeOut); - end; - if (FIXED_PITCH and lfPitchAndFamily) <> 0 then - Pitch := fpFixed - else if (VARIABLE_PITCH and lfPitchAndFamily) <> 0 then - Pitch := fpVariable - else - Pitch := fpDefault; - Style := AStyle; - Quality := TFontQuality(ALogFont.lfQuality); - Name := ALogFont.lfFaceName; - end; + Height := ALogFont.lfHeight; + Charset := TFontCharset(ALogFont.lfCharSet); + AStyle := []; + if ALogFont.lfWeight >= FW_SEMIBOLD then Include(AStyle, fsBold); + if ALogFont.lfItalic <> 0 then Include(AStyle, fsItalic); + if ALogFont.lfUnderline <> 0 then Include(AStyle, fsUnderline); + if ALogFont.lfStrikeOut <> 0 then Include(AStyle, fsStrikeOut); + if (FIXED_PITCH and ALogFont.lfPitchAndFamily) <> 0 then + Pitch := fpFixed + else if (VARIABLE_PITCH and ALogFont.lfPitchAndFamily) <> 0 then + Pitch := fpVariable + else + Pitch := fpDefault; + Style := AStyle; + Quality := TFontQuality(ALogFont.lfQuality); + Name := ALogFont.lfFaceName; finally EndUpdate; end;