Callawy & Farley

Callaway & Farley
This commit is contained in:
Kathy Ruffing 2013-10-17 15:59:40 +00:00
parent 883392a51a
commit 812ca6582e
5 changed files with 108 additions and 14 deletions

View File

@ -118,6 +118,10 @@ namespace fmtxml
case "FNP.FMT":
AddFNPfmt(ref fmtdata);
break;
case "FNP.X00":
case "FNP.X01":
AddFNP_X0x(ref fmtdata);
break;
case "CPL.FMT":
AddCPLfmt(ref fmtdata);
break;
@ -163,8 +167,11 @@ namespace fmtxml
}
private void AddFNPfmt(ref FormatData fmtdata)
{
fmtdata.ComponentTableFormat = "True";
//fmtdata.TPL = "0,8,0,6,0,0,title
1,8,2,6,0,8192,
2,41,12,24,0,0,Component Number:
2,41,40,42,0,0,Name:
";
fmtdata.SectData.StepSectionData.StpSectLayData.WidSTableEdit = "445,186,120";
fmtdata.SectData.StepSectionData.StpSectLayData.WidSTablePrint = "445,186,120";
fmtdata.SectData.StepSectionData.StpSectLayData.WidSTablePrint = "420,186,120";
fmtdata.SectData.StepSectionData.StpSectLayData.RNOWidthAlt = "0,134";
fmtdata.SectData.StepSectionData.StpSectLayData.ColRTable = "0,198,138";
fmtdata.SectData.StepSectionData.SequentialTabFormat[2].TabFormat = "#2#{seq} ";
fmtdata.SectData.StepSectionData.SequentialTabFormat[2].PrintTabFormat = "#2#{seq} ";
@ -178,8 +185,20 @@ namespace fmtxml
fmtdata.BoxData[2].Start = -15;
fmtdata.BoxData[2].End = 505;
fmtdata.StepData[40].AdjHighLevelTab = "-24";
fmtdata.StepData[41].AlignHLSTabWithSectOvride = "True";
fmtdata.StepData[42].ReadOnly = "True";
fmtdata.StepData[43].ReadOnly = "True";
fmtdata.StepData[9].UseOldTemplate = "True";
}
private void AddFNP_X0x(ref FormatData fmtdata)
{
fmtdata.ComponentTableFormat = "True";
//fmtdata.TPL = "0,8,0,6,0,0,title
1,8,2,6,0,8192,
2,41,12,24,0,0,Component Number:
2,41,40,42,0,0,Name:
";
fmtdata.SectData.StepSectionData.SequentialTabFormat[2].TabFormat = "#2#{seq} ";
fmtdata.SectData.StepSectionData.SequentialTabFormat[2].PrintTabFormat = "#2#{seq} ";
fmtdata.SectData.StepSectionData.SequentialTabFormat[3].TabFormat = "#2#{seq} ";
fmtdata.SectData.StepSectionData.SequentialTabFormat[3].PrintTabFormat = "#2#{seq} ";
}
private void AddCAL2fmt(ref FormatData fmtdata)
{
fmtdata.SectData.StepSectionData.StpSectLayData.Separator.SeparatorLocation = 10;
@ -1554,7 +1573,6 @@ namespace fmtxml
case "TUEC.PAG":
AddTUECPage(ref pgstyles);
break;
/* Under Development
case "TP.PAG":
AddTPPage(ref pgstyles);
@ -1563,9 +1581,46 @@ namespace fmtxml
AddTP00Page(ref pgstyles);
break;
* */
case "FNP.PAG":
AddFNPPage(ref pgstyles);
break;
case "FNP.Z00":
AddFNP_00Page(ref pgstyles);
break;
case "FNP.Z01":
AddFNP_01Page(ref pgstyles);
break;
}
}
private void AddFNP_00Page(ref PageStyles pgstyles)
{
pgstyles.PgStyles[0].Items[2].Col = 30;
pgstyles.PgStyles[1].Items[2].Col = 30;
pgstyles.PgStyles[2].Items[2].Col = 30;
pgstyles.PgStyles[3].Items[2].Col = 30;
}
private void AddFNP_01Page(ref PageStyles pgstyles)
{
pgstyles.PgStyles[0].Items[2].Col = 30;
pgstyles.PgStyles[1].Items[2].Col = 30;
pgstyles.PgStyles[2].Items[2].Col = 30;
}
private void AddFNPPage(ref PageStyles pgstyles)
{
pgstyles.PgStyles[0].Items[2].Col = 30;
pgstyles.PgStyles[1].Items[2].Col = 30;
pgstyles.PgStyles[2].Items[2].Col = 30;
pgstyles.PgStyles[3].Items[2].Col = 30;
pgstyles.PgStyles[4].Items[3].Col = 30; // foldout
pgstyles.PgStyles[7].Items[2].Col = 30; // component list
pgstyles.PgStyles[8].Items[2].Col = 30;
pgstyles.PgStyles[9].Items[2].Col = 30;
pgstyles.PgStyles[10].Items[2].Col = 30;
pgstyles.PgStyles[11].Items[2].Col = 30;
}
private void AddCALBCKPage(ref PageStyles pgstyles)
{
pgstyles.PgStyles[1].Items[3].Style.FontSize = "14";
@ -2984,13 +3039,12 @@ namespace fmtxml
case "IP3.Y15":
AddIP315DOC(ref dcstyles);
break;
case "FNP.DOC":
AddFNPDOC(ref dcstyles);
break;
case "CAL2.DOC":
AddCAL2DOC(ref dcstyles);
break;
case "CALOTO.DOC":
case "CAL2.Y00":
AddCAL2DOC(ref dcstyles);
AddCAL2RestDOC(ref dcstyles);
break;
case "CALBCK.DOC":
AddCALBCKDOC(ref dcstyles);
@ -3010,22 +3064,36 @@ namespace fmtxml
case "TUEC.DOC":
AddTUCEDOC(ref dcstyles);
break;
case "FNP.DOC":
AddFNPDOC(ref dcstyles);
break;
case "FNP.Y00":
case "FNP.Y01":
AddFNP_Y0x(ref dcstyles);
break;
}
}
private void AddFNPDOC(ref DocStyles dcstyles)
{
dcstyles.DcStyles[5].TopMargin = 144;
}
private void AddFNP_Y0x(ref DocStyles dcstyles)
{
dcstyles.DcStyles[1].TopMargin = 144;
}
private void AddCALBCKDOC(ref DocStyles dcstyles)
{
dcstyles.DcStyles[0].PageWidth = 560;
dcstyles.DcStyles[0].ContTop = "";
}
private void AddCAL2DOC(ref DocStyles dcstyles)
private void AddCAL2RestDOC(ref DocStyles dcstyles)
{
dcstyles.DcStyles[1].PageLength = 672;
}
private void AddFNPDOC(ref DocStyles dcstyles)
private void AddCAL2DOC(ref DocStyles dcstyles)
{
dcstyles.DcStyles[2].AlignHLSTabWithSect = true;
dcstyles.DcStyles[1].PageLength = 672;
dcstyles.DcStyles[5].ExtraLineHeader = true;
}
private void AddIP315DOC(ref DocStyles dcstyles)
{

View File

@ -20,7 +20,8 @@ using System.ComponentModel;
[Serializable]
public struct FormatData
{
public string Name;
public string Name;
public string ComponentTableFormat;
public string PurchaseOptions;
public string TPL;
//public XtraFlgs XtraFlags;
@ -908,6 +909,7 @@ public struct Step
public string PageBreakOnStep; // PageBreakOnHighLevelStep, PageBreakOnCautions, PageBreakOnNotes
public string UseOldTemplate;
public string AlignNullTabWSectHead;
public string AlignHLSTabWithSectOvride;
public string TextSubFollowsTextStyle;
public string CautionOrNoteSubstepIndent;
public string TreatAsSequential; // TreatAND_ORasSequential
@ -1597,6 +1599,7 @@ namespace fmtxml
//if (fmtName.ToUpper() != "OHLP" && fmtName.ToUpper() != "BASE" && fmtName.ToUpper() != "WCN2") return;
//if (fmtName.ToUpper() != "WCNCKL" && fmtName.ToUpper() != "BASE") return;
//if (fmtName.ToUpper() != "NSPARP" && fmtName.ToUpper() != "BASE") return;
//if (!fmtName.ToUpper().StartsWith("FNP") && fmtName.ToUpper() != "BASE") return;
try
{
LoadFormatFile(nm + ".fmt", ref SubXtraFlags);
@ -2190,8 +2193,21 @@ namespace fmtxml
// if this format has an associated PSI or TPL file, just read in the string & save
// it.
string otherfile = MyPath + @"\" + fname.Substring(0, fname.LastIndexOf(".")) + @".tpl";
if (File.Exists(otherfile))
// if this is subformat, the tpl file will be name FNP00.TPL for fnp.x00, using 'fnp' as
// an example. check for this too.
bool issub = (fname.ToUpper().Substring(fname.LastIndexOf(".") + 1, 1) == "X");
if (File.Exists(otherfile) && !issub)
fmtdata.TPL = FixXmlString(File.ReadAllText(otherfile));
else
{
if (issub)
{
string subtpl = fname.Substring(0, fname.LastIndexOf(".")) + fname.Substring(fname.Length - 2, 2);
otherfile = MyPath + @"\" + subtpl + @".tpl";
if (File.Exists(otherfile))
fmtdata.TPL = FixXmlString(File.ReadAllText(otherfile));
}
}
// http://www.w3.org/TR/2000/REC-xml-20001006#NT-Char
otherfile = MyPath + @"\" + fname.Substring(0, fname.LastIndexOf(".")) + @".ini";
if (File.Exists(otherfile)) PsiIniToXml(ref fmtdata, otherfile);
@ -4798,6 +4814,7 @@ namespace fmtxml
#region COMPAREACTIVE
subFmt.FontData = FixInheritedFont(subFmt.FontData, mainFmt.FontData); // Phase 10
if (mainFmt.PurchaseOptions == subFmt.PurchaseOptions) subFmt.PurchaseOptions = null;
if (mainFmt.ComponentTableFormat == subFmt.ComponentTableFormat) subFmt.ComponentTableFormat = null;
if (mainFmt.TPL == subFmt.TPL) subFmt.TPL = null;
if (mainFmt.EditData.EMode == subFmt.EditData.EMode) subFmt.EditData.EMode = null;
if (mainFmt.EditData.PromptForCautionType != null && mainFmt.EditData.PromptForCautionType == subFmt.EditData.PromptForCautionType) subFmt.EditData.PromptForCautionType = "null";
@ -5306,6 +5323,7 @@ namespace fmtxml
private string StepPartPageBreakOnStep(Step stp) { return stp.PageBreakOnStep; }
private string StepPartUseOldTemplate(Step stp) { return stp.UseOldTemplate; }
private string StepPartAlignNullTabWSectHead(Step stp) { return stp.AlignNullTabWSectHead; }
private string StepPartAlignHLSTabWithSectOvride(Step stp) { return stp.AlignHLSTabWithSectOvride; }
private string StepPartTextSubFollowsTextStyle(Step stp) { return stp.TextSubFollowsTextStyle; }
private string StepPartTreatAsSequential(Step stp) { return stp.TreatAsSequential; }
private string StepPartMatchUpRNO(Step stp) { return stp.MatchUpRNO; }
@ -5555,6 +5573,7 @@ namespace fmtxml
if (CheckInheritedStr(new StepPartStr(StepPartPageBreakOnStep), step, dicParents)) step.PageBreakOnStep = null;
if (CheckInheritedStr(new StepPartStr(StepPartUseOldTemplate), step, dicParents)) step.UseOldTemplate = null;
if (CheckInheritedStr(new StepPartStr(StepPartAlignNullTabWSectHead), step, dicParents)) step.AlignNullTabWSectHead = null;
if (CheckInheritedStr(new StepPartStr(StepPartAlignHLSTabWithSectOvride), step, dicParents)) step.AlignHLSTabWithSectOvride = null;
if (CheckInheritedStr(new StepPartStr(StepPartTextSubFollowsTextStyle), step, dicParents)) step.TextSubFollowsTextStyle = null;
if (CheckInheritedStr(new StepPartStr(StepPartTreatAsSequential), step, dicParents)) step.TreatAsSequential = null;
if (CheckInheritedStr(new StepPartStr(StepPartMatchUpRNO), step, dicParents)) step.MatchUpRNO = null;

View File

@ -76,6 +76,7 @@ public struct DocStyle
public bool CancelSectTitle; // Was format flags CancelSecTitlesOnS1 & CancelSecTitlesOnS2
public bool SpecialStepsFoldout; // Was format flag SpecialStepsFoldout - but put on E2 (was in 16bit code)
public bool UndSpecialStepsFoldout; // Was format flag UndSpecialStepsFoldout - but put here on E2 only.
public bool ExtraLineHeader; // added for Callaway foldout Notes (needed line bewteen 'NOTE' and text)
public bool AlignHLSTabWithSect; // added for FNP (was in WST)
public short ContTopHLS; // Flag for including High Level step
// as part of top continue message.

View File

@ -25,6 +25,7 @@
<xsl:apply-templates select="CancelSectTitle"/>
<xsl:apply-templates select="SpecialStepsFoldout"/>
<xsl:apply-templates select="UndSpecialStepsFoldout"/>
<xsl:apply-templates select="ExtraLineHeader"/>
<xsl:apply-templates select="AlignHLSTabWithSect"/>
<xsl:apply-templates select="pagestyle"/>
<xsl:apply-templates select="dstyle|DocStructStyle|TopMargin|ContStyle|EndStyle|FinalMsg|CenterLineX|CenterLineYTop|CenterLineYBottom|LandscapePageList|ShowSectionTitles"/>
@ -107,6 +108,11 @@
<xsl:value-of select="."/>
</xsl:attribute>
</xsl:template>
<xsl:template match="ExtraLineHeader">
<xsl:attribute name="ExtraLineHeader">
<xsl:value-of select="."/>
</xsl:attribute>
</xsl:template>
<xsl:template match="AlignHLSTabWithSect">
<xsl:attribute name="AlignHLSTabWithSect">
<xsl:value-of select="."/>

Binary file not shown.