added check for null MacroDef
additional checks for checkoffs and logic support or NSP script Cautions with bullets fixed pagelist processing issue when pagelist row has more than one token support for NSP script Cautions fixed problem where the END message was not printing for NSP (the Y location was negative – off the page)
This commit is contained in:
@@ -919,6 +919,13 @@ namespace Volian.Print.Library
|
||||
if (itemInfo.MyHeader != null && itemInfo.MyHeader.Text != null && !doSectTab)
|
||||
yoff += SetHeader(this, cb, itemInfo, formatInfo);
|
||||
YOffset = yoff;
|
||||
if (mytab != null && mytab.SeparateBullet)
|
||||
{
|
||||
string identB = formatInfo.PlantFormat.FormatData.SectData.StepSectionData.IdentB;
|
||||
vlnText myBullet = new vlnText(cb, this, identB, identB, XOffset - 12, YOffset, MyItemInfo.FormatStepData.TabData.Bullet.Font);
|
||||
myBullet.Rtf = myBullet.Rtf.Replace("\u25CF", @"\f1\u9679?\f0 ");
|
||||
PartsLeft.Add(myBullet);
|
||||
}
|
||||
if (itemInfo.IsRNOPart)
|
||||
{
|
||||
// there may be other places that double space, but this supports it for RNOs (the DoubleRNOspace flag)
|
||||
@@ -1005,7 +1012,10 @@ namespace Volian.Print.Library
|
||||
CheckOff co = itemInfo.GetCheckOffStep();
|
||||
if (co != null)
|
||||
{
|
||||
float xloc_co = (float)formatInfo.PlantFormat.FormatData.ProcData.CheckOffData.XLocation + (float)itemInfo.MyDocStyle.Layout.LeftMargin;
|
||||
//float xloc_co = (float)formatInfo.PlantFormat.FormatData.ProcData.CheckOffData.XLocation + (float)itemInfo.MyDocStyle.Layout.LeftMargin;
|
||||
float xloc_co = (float)itemInfo.MyDocStyle.Layout.LeftMargin;
|
||||
if (formatInfo.PlantFormat.FormatData.ProcData.CheckOffData.XLocation != null)
|
||||
xloc_co += (float)formatInfo.PlantFormat.FormatData.ProcData.CheckOffData.XLocation;
|
||||
PartsRight.Add(new vlnMacro(xloc_co, yForCheckoff, co.Macro));
|
||||
}
|
||||
float yOffRight = yoff;
|
||||
@@ -1493,10 +1503,15 @@ namespace Volian.Print.Library
|
||||
//if (myTab != null) myTab.XOffset += xoff;
|
||||
//xoff = MyParent.XOffset - myTab.XOffset;
|
||||
//XOffset += xoff;
|
||||
float tabOffset = (myTab == null?0: myTab.XOffset) - XOffset;
|
||||
|
||||
XOffset = (float)colOvrd;
|
||||
if (myTab != null)
|
||||
{
|
||||
myTab.XOffset += (MyParent.XOffset - myTab.XOffset);
|
||||
//myTab.XOffset += (MyParent.XOffset - myTab.XOffset);
|
||||
myTab.XOffset = XOffset + tabOffset;
|
||||
//if (myTab.ScriptCaution)
|
||||
// myTab.XOffset += 10.8F;
|
||||
//myTab.XOffset += xoff;
|
||||
}
|
||||
return;
|
||||
@@ -1642,30 +1657,34 @@ namespace Volian.Print.Library
|
||||
float CheckOffAdj = 0;
|
||||
if (itemInfo.MyDocStyle.UseCheckOffs)
|
||||
{
|
||||
CheckOffAdj = -(float)formatInfo.PlantFormat.FormatData.ProcData.CheckOffData.CheckOffAdjustment;
|
||||
if (!HasCheckOffHeading(itemInfo, formatInfo))
|
||||
if (formatInfo.PlantFormat.FormatData.ProcData.CheckOffData.CheckOffAdjustment != null)
|
||||
CheckOffAdj = -(float)formatInfo.PlantFormat.FormatData.ProcData.CheckOffData.CheckOffAdjustment;
|
||||
if (!HasCheckOffHeading(itemInfo, formatInfo) && CheckOffAdj < 0)
|
||||
CheckOffAdj += (float)(9 * 7.2); // 9 is the size of the SIGNOFF adjustment
|
||||
}
|
||||
float adjwidth = CheckOffAdj;
|
||||
SectData sd = formatInfo.PlantFormat.FormatData.SectData;
|
||||
if (sd.StepSectionData.StepSectionLayoutData.TieTabToLevel && sd.UseMetaSections)
|
||||
if (sd.UseMetaSections)
|
||||
{
|
||||
if (itemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.ShowSectionTitles
|
||||
&& !itemInfo.MyDocStyle.CancelSectTitle
|
||||
&& !(itemInfo.MyDocStyle.SpecialStepsFoldout && itemInfo.MyDocStyle.UseColSByLevel))
|
||||
if (sd.StepSectionData.StepSectionLayoutData.TieTabToLevel)
|
||||
{
|
||||
int indxLevel = itemInfo.PrintLevel + itemInfo.CurrentSectionLevel();
|
||||
adjwidth += formatInfo.PlantFormat.FormatData.SectData.MetaSectionList[indxLevel % formatInfo.PlantFormat.FormatData.SectData.MetaSectionList.Count].WidSAdjByLevel ?? 0; ;
|
||||
float colsbylevel = (float)formatInfo.PlantFormat.FormatData.SectData.MetaSectionList[indxLevel % formatInfo.PlantFormat.FormatData.SectData.MetaSectionList.Count].ColSByLevel;
|
||||
float seclvlindent = colsbylevel - (float)formatInfo.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.ColS;
|
||||
adjwidth -= seclvlindent;
|
||||
adjwidth -= AdjustForSectionLevelTab();
|
||||
if (itemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.ShowSectionTitles
|
||||
&& !itemInfo.MyDocStyle.CancelSectTitle
|
||||
&& !(itemInfo.MyDocStyle.SpecialStepsFoldout && itemInfo.MyDocStyle.UseColSByLevel))
|
||||
{
|
||||
int indxLevel = itemInfo.PrintLevel + itemInfo.CurrentSectionLevel();
|
||||
adjwidth += formatInfo.PlantFormat.FormatData.SectData.MetaSectionList[indxLevel % formatInfo.PlantFormat.FormatData.SectData.MetaSectionList.Count].WidSAdjByLevel ?? 0; ;
|
||||
float colsbylevel = (float)formatInfo.PlantFormat.FormatData.SectData.MetaSectionList[indxLevel % formatInfo.PlantFormat.FormatData.SectData.MetaSectionList.Count].ColSByLevel;
|
||||
float seclvlindent = colsbylevel - (float)formatInfo.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.ColS;
|
||||
adjwidth -= seclvlindent;
|
||||
adjwidth -= AdjustForSectionLevelTab();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (formatInfo.PlantFormat.FormatData.SectData.MetaSectionList.Count > 0)
|
||||
adjwidth += (float)formatInfo.PlantFormat.FormatData.SectData.MetaSectionList[itemInfo.PrintLevel % formatInfo.PlantFormat.FormatData.SectData.MetaSectionList.Count].ColSByLevel;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (formatInfo.PlantFormat.FormatData.SectData.MetaSectionList.Count > 0)
|
||||
adjwidth += (float)formatInfo.PlantFormat.FormatData.SectData.MetaSectionList[itemInfo.PrintLevel % formatInfo.PlantFormat.FormatData.SectData.MetaSectionList.Count].ColSByLevel;
|
||||
}
|
||||
|
||||
Width = ToInt(formatInfo.MyStepSectionLayoutData.WidSTablePrint, maxRNO);
|
||||
|
Reference in New Issue
Block a user