From c8b01d803c6d4b4d079c963f0211a3b7acfbb1d8 Mon Sep 17 00:00:00 2001 From: John Date: Wed, 10 Apr 2019 18:45:01 +0000 Subject: [PATCH] B2019-057 The override width on sub-steps without tabs (i.e. paragraph) was being reset back to non-override value. Added logic to not do this if the step type has a width override set in the format. --- PROMS/Volian.Print.Library/vlnParagraph.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/PROMS/Volian.Print.Library/vlnParagraph.cs b/PROMS/Volian.Print.Library/vlnParagraph.cs index 38dd09b4..b984423f 100644 --- a/PROMS/Volian.Print.Library/vlnParagraph.cs +++ b/PROMS/Volian.Print.Library/vlnParagraph.cs @@ -5801,8 +5801,10 @@ namespace Volian.Print.Library XOffset = childindent + MyParent.XOffset + indentBG2;//(itemInfo.FormatStepData.Font.CharsToTwips * 2); // B2016-164: Added the following 'if' so that the width is not recalculated if in the alarm format & the parent has a template // B2016-168: The fix for 164 broke deviation document printing. The if statement was fixed for both: - if (!itemInfo.ActiveFormat.PlantFormat.FormatData.PrintData.SpecialCaseCalvertAlarm || !UseTemplateWidthOrXOff(itemInfo.MyParent)) - Width = (float)itemInfo.MyDocStyle.Layout.PageWidth - (float)itemInfo.MyDocStyle.Layout.LeftMargin - indentBG2; + // B2019-057 Added a check to see if there is a width override for this step element (Robinson AOP Backgrounds - paragraphs) + float wdthovrd = (itemInfo.FormatStepData.WidthOverride == null) ? 0 : (float)ToInt(itemInfo.FormatStepData.WidthOverride, maxRNO); + if ((!itemInfo.ActiveFormat.PlantFormat.FormatData.PrintData.SpecialCaseCalvertAlarm || !UseTemplateWidthOrXOff(itemInfo.MyParent)) && wdthovrd == 0) + Width = (float)itemInfo.MyDocStyle.Layout.PageWidth - (float)itemInfo.MyDocStyle.Layout.LeftMargin - indentBG2; } return; }