Additional code to support special cases in Template for Calvert Alarms including a TemplateColumnMode and mix of Cautions/Notes
Added Support for BGE Alarms, bottom continue message location. Additional code to support special cases in Template for Calvert Alarms and new flag SpecialCaseCalvertAlarm Support for Docstyle DSS_PageBreakHLS for page break on HLS Changes for Calvert Alarms use of template to define top portion of alarm pages and CONDITION/RESPONSE table support. Handle 3 top/bottom continue messages for Calvert Alarms; support box around CONDITION/RESPONSE table in Calvert Alarms; {REVUNIT} fix; if TabPtsPerChar format is 0, set to a default of 6
This commit is contained in:
@@ -117,6 +117,8 @@ namespace VEPROMS.CSLA.Library
|
||||
BtwnTextAndBottom = 1,
|
||||
BottomOfPage = 2,
|
||||
BelowBottom1 = 3,
|
||||
// BottomWithFooter added for BGE for Alarms. This puts continue message on bottom AND if in CONDITION/RESPONSE table, at bottom of both columns.
|
||||
BottomWithFooter = 4,
|
||||
EndOfText2 = 5,
|
||||
BtwnTextAndBottom2 = 6 // Added for BGE, their continue message was a line or so too far down page.1
|
||||
};
|
||||
|
@@ -232,11 +232,14 @@ namespace VEPROMS.CSLA.Library
|
||||
// count newlines - which gives number of template records.
|
||||
int NumTemplates = 0;
|
||||
if (TPL == null) return null;
|
||||
int indx = TPL.IndexOf('\n');
|
||||
// if the template is modified by the plant specific code in the format migration,
|
||||
// it will contain an '&' rather than '&'.
|
||||
string tTPL = TPL.Replace("&", "&");
|
||||
int indx = tTPL.IndexOf('\n');
|
||||
while (indx > -1)
|
||||
{
|
||||
NumTemplates++;
|
||||
indx = TPL.Length > indx + 1 ? TPL.IndexOf('\n', indx + 1) : -1;
|
||||
indx = tTPL.Length > indx + 1 ? tTPL.IndexOf('\n', indx + 1) : -1;
|
||||
}
|
||||
if (NumTemplates == 0) return null;
|
||||
|
||||
@@ -261,7 +264,7 @@ namespace VEPROMS.CSLA.Library
|
||||
int type = 0;
|
||||
int start = 0;
|
||||
int width = 0;
|
||||
int nocol = 0;
|
||||
short nocol = 0;
|
||||
int row = 0;
|
||||
string stmp = null;
|
||||
if (!NewTemplateFormat)
|
||||
@@ -284,7 +287,7 @@ namespace VEPROMS.CSLA.Library
|
||||
start = Convert.ToInt32(tmpNew[2]);
|
||||
width = Convert.ToInt32(tmpNew[3]);
|
||||
row = Convert.ToInt32(tmpNew[4]);
|
||||
nocol = Convert.ToInt32(tmpNew[5]);
|
||||
nocol = Convert.ToInt16(tmpNew[5]);
|
||||
stmp = tmpNew.Length <= 6 ? null : tmpNew[6];
|
||||
}
|
||||
TPlate tp = new TPlate(level, type, start, width, row, nocol, stmp);
|
||||
@@ -558,6 +561,12 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
#endregion
|
||||
#region Templates
|
||||
// the nocolm field -- divided into 4 four-bit subfields;
|
||||
// starting with the 4 lowest order bits :
|
||||
// field 1 - number of columns
|
||||
// field 2 - the header macro to print instead of the text(fixed at 4 for now)
|
||||
// field 3 - the number of blank lines after the header macro
|
||||
// field 4 - 1 - identifies the template as being boxed, for latter retrieval
|
||||
public class TPlate
|
||||
{
|
||||
public int level; // sub-step level
|
||||
@@ -565,9 +574,11 @@ namespace VEPROMS.CSLA.Library
|
||||
public int start; // starting position (for horizontal only)
|
||||
public int width; // width of text in characters (")
|
||||
public int row;
|
||||
public int nocolm; // 1 or 2 columns - default(0) is one column
|
||||
public short nocolm; // 1 or 2 columns - default(0) is one column
|
||||
public string text; // text to be automatically entered
|
||||
public TPlate(int l, int t, int s, int w, int r, int c, string x)
|
||||
public bool boxed;
|
||||
public int hmacro = 0;
|
||||
public TPlate(int l, int t, int s, int w, int r, short c, string x)
|
||||
{
|
||||
level = l;
|
||||
type = t;
|
||||
@@ -575,6 +586,11 @@ namespace VEPROMS.CSLA.Library
|
||||
width = w;
|
||||
row = r;
|
||||
nocolm = c;
|
||||
hmacro = 0x00F0 & nocolm >> 4;
|
||||
if (hmacro > 0) hmacro = 4; // bge - this was in 16bit code
|
||||
int blines = (0x0F00 & nocolm) >> 8;
|
||||
boxed = ((0xF000 & nocolm) >> 12) != 0;
|
||||
nocolm = (short)(0x000F & nocolm);
|
||||
text = x;
|
||||
}
|
||||
}
|
||||
@@ -705,6 +721,14 @@ namespace VEPROMS.CSLA.Library
|
||||
return LazyLoad(ref _SpecialCaseCalvert, "@SpecialCaseCalvert");
|
||||
}
|
||||
}
|
||||
private LazyLoad<bool> _SpecialCaseCalvertAlarm;
|
||||
public bool SpecialCaseCalvertAlarm
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _SpecialCaseCalvertAlarm, "@SpecialCaseCalvertAlarm");
|
||||
}
|
||||
}
|
||||
private LazyLoad<bool> _SpecialStepsFoldout;
|
||||
public bool SpecialStepsFoldout
|
||||
{
|
||||
|
Reference in New Issue
Block a user