Added logic to not extend the change bar on different types of Notes and Cautions if using the LimitCautionNoteWidthToHLS
Logic to adjust the Note/Caution width when off of a substep and when using the LimitCautionNoteWidthToHLS format flag. Logic to adjust the Yoffset of a note when off of a borderless table.
This commit is contained in:
parent
7cb179f085
commit
ae47368d34
@ -121,6 +121,12 @@ namespace Volian.Print.Library
|
|||||||
{
|
{
|
||||||
string sep = parent.MyItemInfo.MyHeader == null ? "" : parent.MyItemInfo.MyHeader.CleanText;
|
string sep = parent.MyItemInfo.MyHeader == null ? "" : parent.MyItemInfo.MyHeader.CleanText;
|
||||||
vlnHeader tmp = vph as vlnHeader;
|
vlnHeader tmp = vph as vlnHeader;
|
||||||
|
// if the part above is not the same type and it's a Note or Caution and the OnlyBulletSameCautionNoteType is true
|
||||||
|
// don't extend the change bar to the item above
|
||||||
|
if (!parent.MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.OnlyBulletSameCautionNoteType ||
|
||||||
|
((parent.MyItemInfo.IsCaution || parent.MyItemInfo.IsNote) &&
|
||||||
|
(parent.MyItemInfo.MyContent.Type != vph.MyParent.MyItemInfo.MyContent.Type)))
|
||||||
|
{
|
||||||
// the separator must exist and the previous must have a change bar.
|
// the separator must exist and the previous must have a change bar.
|
||||||
|
|
||||||
if ((sep != "") && (tmp.Text == sep) && parent.MyItemInfo.MyPrevious != null && parent.MyItemInfo.MyPrevious.HasChangeBar)
|
if ((sep != "") && (tmp.Text == sep) && parent.MyItemInfo.MyPrevious != null && parent.MyItemInfo.MyPrevious.HasChangeBar)
|
||||||
@ -141,6 +147,7 @@ namespace Volian.Print.Library
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
_MessageAlignment = msgAlignment;
|
_MessageAlignment = msgAlignment;
|
||||||
}
|
}
|
||||||
public override string ToString()
|
public override string ToString()
|
||||||
|
@ -2719,7 +2719,16 @@ namespace Volian.Print.Library
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (adjustAgain)
|
if (adjustAgain)
|
||||||
|
{
|
||||||
AdjustXOffsetForTab(itemInfo, maxRNO, formatInfo, mytab, xMetaAdj);
|
AdjustXOffsetForTab(itemInfo, maxRNO, formatInfo, mytab, xMetaAdj);
|
||||||
|
// Used in Ginna's Attachment format.
|
||||||
|
// if the Note/Caution is off of a sub-step, then adjust the width so that the Caution/Note text box does not extend past the HLS text box
|
||||||
|
if (itemInfo.IsCautionOrNotePart && maxRNO == 0 && itemInfo.MyActiveSection.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.LimitCautionNoteWidthToHLS)
|
||||||
|
{
|
||||||
|
float wMax = MyHighLevelParagraph.Width + MyHighLevelParagraph.XOffset - XOffset;
|
||||||
|
if (wMax < Width && (Width + XOffset > MyItemInfo.MyDocStyle.Layout.PageWidth) ) Width = wMax;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// For Calvert Alarms: if within the CONDITION/RESPONSE table, indent by 1 character.
|
// For Calvert Alarms: if within the CONDITION/RESPONSE table, indent by 1 character.
|
||||||
// Sequential substeps are ok because of the tab string, but items without a tab & other step
|
// Sequential substeps are ok because of the tab string, but items without a tab & other step
|
||||||
@ -2785,7 +2794,13 @@ namespace Volian.Print.Library
|
|||||||
// yoff from this. Without this, an overlap of text between the note and the bottom of the
|
// yoff from this. Without this, an overlap of text between the note and the bottom of the
|
||||||
// RNO was occurring for FNP - Unit 2/AOP, AOP-4.0.
|
// RNO was occurring for FNP - Unit 2/AOP, AOP-4.0.
|
||||||
if (yoffRightParent > yoff && ((itemInfo.MyDocStyle.StructureStyle.Style & E_DocStructStyle.DoubleBoxHLS) != E_DocStructStyle.DoubleBoxHLS)) yoff = yoffRightParent;
|
if (yoffRightParent > yoff && ((itemInfo.MyDocStyle.StructureStyle.Style & E_DocStructStyle.DoubleBoxHLS) != E_DocStructStyle.DoubleBoxHLS)) yoff = yoffRightParent;
|
||||||
if (loadChildren) yoff = ChildrenAbove.Add(cb, itemInfo.Notes, xoff, yoff, yoff, rnoLevel, maxRNO, formatInfo);
|
if (loadChildren)
|
||||||
|
{
|
||||||
|
float yoffadj = 0;
|
||||||
|
if (itemInfo.IsTable && MyFlexGrid.BorderStyle == C1.Win.C1FlexGrid.Util.BaseControls.BorderStyleEnum.None && !MyFlexGrid.TopRowHasBorder())
|
||||||
|
yoffadj = SixLinesPerInch; // adjust the yoffset if the note is off of a borderless table
|
||||||
|
yoff = ChildrenAbove.Add(cb, itemInfo.Notes, xoff, yoff + yoffadj, yoff + yoffadj, rnoLevel, maxRNO, formatInfo) - yoffadj;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4827,7 +4842,7 @@ namespace Volian.Print.Library
|
|||||||
XOffset += mycolT; // adjust caution/note text position
|
XOffset += mycolT; // adjust caution/note text position
|
||||||
if (PartsLeft != null && PartsLeft.Count > 0)// adjust tab position
|
if (PartsLeft != null && PartsLeft.Count > 0)// adjust tab position
|
||||||
{
|
{
|
||||||
if(myTab!=null && (itemInfo.IsNote || itemInfo.IsCaution))
|
if (myTab != null && (itemInfo.IsNote || itemInfo.IsCaution))
|
||||||
Width -= myTab.Width;
|
Width -= myTab.Width;
|
||||||
foreach (vlnPrintObject vpo in PartsLeft)
|
foreach (vlnPrintObject vpo in PartsLeft)
|
||||||
vpo.XOffset += mycolT;
|
vpo.XOffset += mycolT;
|
||||||
@ -4868,7 +4883,7 @@ namespace Volian.Print.Library
|
|||||||
}
|
}
|
||||||
else if (itemInfo.MyParent.IsCaution || itemInfo.MyParent.IsNote)
|
else if (itemInfo.MyParent.IsCaution || itemInfo.MyParent.IsNote)
|
||||||
{
|
{
|
||||||
if(itemInfo.ActiveFormat.MyStepSectionLayoutData.DevNoteOrCautionTabOffset != null)
|
if (itemInfo.ActiveFormat.MyStepSectionLayoutData.DevNoteOrCautionTabOffset != null)
|
||||||
Width = MyParent.MyParent.Width - tabWidth + (myTab == null ? 0 : myTab.TabAlign);
|
Width = MyParent.MyParent.Width - tabWidth + (myTab == null ? 0 : myTab.TabAlign);
|
||||||
else
|
else
|
||||||
Width = MyParent.Width - tabWidth + (myTab == null ? 0 : myTab.TabAlign);
|
Width = MyParent.Width - tabWidth + (myTab == null ? 0 : myTab.TabAlign);
|
||||||
@ -4884,7 +4899,7 @@ namespace Volian.Print.Library
|
|||||||
else if (MyParent.WidthNoLimit != 0)
|
else if (MyParent.WidthNoLimit != 0)
|
||||||
Width = adjwidth + MyParent.WidthNoLimit - tabWidth + (myTab == null ? 0 : myTab.TabAlign);
|
Width = adjwidth + MyParent.WidthNoLimit - tabWidth + (myTab == null ? 0 : myTab.TabAlign);
|
||||||
else if ((itemInfo.MyDocStyle.StructureStyle.Style & E_DocStructStyle.DSS_PageListSpBckgrnd) == E_DocStructStyle.DSS_PageListSpBckgrnd)
|
else if ((itemInfo.MyDocStyle.StructureStyle.Style & E_DocStructStyle.DSS_PageListSpBckgrnd) == E_DocStructStyle.DSS_PageListSpBckgrnd)
|
||||||
Width = adjwidth + MyParent.Width - (MyTab!=null?MyTab.Width:0);
|
Width = adjwidth + MyParent.Width - (MyTab != null ? MyTab.Width : 0);
|
||||||
else
|
else
|
||||||
Width = adjwidth + MyParent.Width - tabWidth + (myTab == null ? 0 : myTab.TabAlign);
|
Width = adjwidth + MyParent.Width - tabWidth + (myTab == null ? 0 : myTab.TabAlign);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user