Compare commits

...

18 Commits

Author SHA1 Message Date
65c874508e Merge pull request 'F2023-135: Farley FSG - override width of unnumbered HLS' (#115) from FarleyWork into Development
No review required format only
2023-09-14 09:18:23 -04:00
830c84a62e F2023-135: Farley FSG - override width of unnumbered HLS 2023-09-14 09:11:36 -04:00
8b666ed287 Merge pull request 'B2023-093 Convert PROMS Word sections to the DOCX format if needed before Editing or Printing' (#114) from SaveWordSection_PDF_Security into Development
Merging into Development after successful code review
2023-09-13 16:32:24 -04:00
6d5d87f04d B2023-093 added a Try Catch to the Convert method per suggestion from review 2023-09-13 16:27:13 -04:00
ef3efe2380 B2023-093 Convert PROMS Word sections to the DOCX format if needed before Editing or Printing 2023-09-13 14:27:38 -04:00
a923a597f3 Merge pull request 'C2023-015: Pagination on sub-step (currently only for Vogtle 3_4)' (#112) from VogtleWork into Development
Reviewed and approved the code for allowing page breaks at the sub-step level for the Vogtle Unit 3  & 4 Alarms.
2023-09-12 08:48:44 -04:00
e4af381d0c C2023-015: Pagination on sub-step (currently only for Vogtle 3_4) 2023-09-12 06:56:48 -04:00
350b943066 Merge pull request 'B2023-091: Vogtle Alarms pagination fix' (#109) from VogtleWork into Development
passed the code review
2023-08-30 14:09:40 -04:00
1cf3a52afa Merge pull request 'B2023-078 When using the split screen PROMS was crashing when the user closed a procedure tab on the other split screen side which didn’t have the current editing focus. PROMS was trying to reposition to the procedure tab that had editing focus, we…' (#110) from B2023-078 into Development
Merging B2023-078 into Development.
2023-08-30 13:26:14 -04:00
10821a478b B2023-078 When using the split screen PROMS was crashing when the user closed a procedure tab on the other split screen side which didn’t have the current editing focus. PROMS was trying to reposition to the procedure tab that had editing focus, we were not taking into account that saved currently active procedure tab could be in a different split screen. 2023-08-30 10:55:07 -04:00
3a6b1adc47 B2023-091: Vogtle Alarms pagination fix 2023-08-30 10:22:49 -04:00
ad476d8de4 Merge pull request 'F2023-134' (#107) from F2023-134_dontUnderlineAfterUnderbar into Development
format only change.
2023-08-24 14:59:31 -04:00
a472169c9d F2023-134
Turned off the format flag that was underlining text after an underbar when printing a RO return value
2023-08-24 14:56:37 -04:00
dcc49a10e5 Merge pull request '~Added script to update local repository branches with remote repository branches' (#105) from GitAutomation into Development
Merging into development
2023-08-24 09:07:14 -04:00
3ea3c32d06 ~Added script to update local repository branches with remote repository branches 2023-08-24 09:05:40 -04:00
25d500c44e Merge pull request 'B2023-089: Search results – reselection of search results step that was deleted causes unexpected results when redisplayed in editor.' (#103) from GenWork into Development
Looks good. The new logic will now handle if the step that is trying to be opened was deleted.
2023-08-24 08:51:13 -04:00
0fa0213eac Merge pull request 'F2023-131 change font of generic EOP format to Arial' (#102) from F2023-131_ERGsFont into Development
Format only changes
2023-08-23 14:16:02 -04:00
314356de36 F2023-131 change font of generic EOP format to Arial 2023-08-23 14:14:13 -04:00
21 changed files with 408 additions and 10 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -44,8 +44,9 @@ using System.Runtime.InteropServices;
// Revision DHH (day - no leading zero, two digit hour - military time
//
// ********* REMEMBER TO CHECK THE AssemblyConfiguration SETTING (ABOVE) ********
[assembly: AssemblyVersion("2.1.2308.2110")]
[assembly: AssemblyFileVersion("2.1.2308.2110")]
[assembly: AssemblyVersion("2.1.2308.2414")]
[assembly: AssemblyFileVersion("2.1.2308.2414")]

View File

@ -333,6 +333,25 @@ namespace VEPROMS.CSLA.Library
OnPropertyChanged("Step_PreferredPagebreak");
}
}
// C2023-015: Pagination on a sub-step
public bool Step_SubStepPagebreak
{
get
{
string s = _Xp["Step", "SubStepPagebreak"];
if (s == string.Empty) return false;
if (s == "True") return true;
return false;
}
set
{
string s = _Xp["Step", "SubStepPagebreak"];
if (value.ToString() == s) return;
_Xp["Step", "SubStepPagebreak"] = value.ToString();
OnPropertyChanged("Step_SubStepPagebreak");
}
}
//[Category("Step Attributes")]
//[DisplayName("Step Change Bar Override")]
//[RefreshProperties(RefreshProperties.All)]

View File

@ -160,6 +160,107 @@ namespace VEPROMS.CSLA.Library
}
}
}
// B2023-093 This method is called before editing or printing a Word section and will convert it the Word .DOCX format if needed.
// Note that the core logic was taken from frmSectionProperties.cs and modified to convert both .RTF and .DOC files
// The conversion to DOCX is needs to be done only one time per Word section
public static void ConvertWordSectionToDOCX(ItemInfo itmInfo)
{
// check the Word file extension that is saved in the tblDocuments SQL database table
DocumentInfo docInfo = itmInfo.MyContent.MyEntry.MyDocument;
if (docInfo.FileExtension.ToUpper() == ".DOCX") return; // already a DOCX - no need to convert
FrmPopupStatusMessage pmsg = null;
DSOFile myfile = null;
LBWordLibrary.LBApplicationClass ap = null;
LBWordLibrary.LBDocumentClass doc = null;
string orgFilename = null;
string filename = null;
FileInfo fi = null;
FileStream fs = null;
SectionInfo msi = null;
Section sec = null;
SectionConfig cfg = null;
try
{
// show user a status window of the Word section being converted to DOCX
// use the section number (DisplayNumber) unless the length is zero, then use the section title (DisplayText)
string statMsg = itmInfo.DisplayNumber;
if (statMsg.Length == 0)
statMsg = itmInfo.DisplayText;
pmsg = new FrmPopupStatusMessage("Converting This Section to Word DOCX", statMsg);
pmsg.Show();
// Get Document as file - it's placed in the user's temporary folder (like we do when we edit a Word section)
myfile = new DSOFile(docInfo);
// Open MSWord App
ap = new LBWordLibrary.LBApplicationClass();
doc = ap.Documents.Open(myfile.FullName);
// Older versions of PROMS saved the Word section as either a RTF or the old-style Word DOC file
// In either case, we want to convert it to a Word DOCX file
// So now create a file name with the .DOCX extension
orgFilename = myfile.FullName.ToUpper();
filename = orgFilename.Replace(".RTF", ".DOCX").Replace(".DOC", ".DOCX"); // we want to convert either .RTF or .DOC Word sections
// This calls Word's convert function to convert the opened .DOC or .RTF to DOCX and save it to our new DOCX file name
doc.SaveAs(filename, LBWordLibrary.LBWdSaveFormat.wdFormatXMLDocument); // Convert to Word DOCX
doc.Close();
doc = null;
// Now read in the new .DOCX file and save the contents to the SQL database
fi = new FileInfo(filename);
fs = File.Open(filename, FileMode.Open, FileAccess.Read, FileShare.ReadWrite);// B2016-053
long len = fs.Length;
byte[] ByteArray = new byte[len];
int nBytesRead = fs.Read(ByteArray, 0, (int)len);
bool isLibraryDocument = (docInfo.LibTitle != null && docInfo.LibTitle != "");
Document myDoc = null;
if (isLibraryDocument)
myDoc = Document.Get(docInfo.DocID);
else
myDoc = Document.MakeDocument(null, ByteArray, docInfo.DocAscii, docInfo.Config, ".DOCX");
// update the document information in the database
msi = itmInfo as SectionInfo;
sec = msi.Get();
cfg = sec.SectionConfig;
if (!isLibraryDocument)
cfg.MySection.MyContent.MyEntry.MyDocument = myDoc; // resetting MyDocument will clear the library doc link - so don't do if a library document
else
cfg.MySection.MyContent.MyEntry.MyDocument.DocContent = ByteArray; // only update .DocContent for library documents
cfg.MySection.MyContent.MyEntry.MyDocument.FileExtension = ".DOCX"; // make sure the Word file extension is .DOCX
cfg.MySection.MyContent.MyEntry.MyDocument.DTS = fi.LastWriteTimeUtc;
cfg.MySection.MyContent.MyEntry.MyDocument.MarkDirty();
cfg.MySection.MyContent.MyEntry.Save();
_MyLog.InfoFormat("Converted Word Section to DOCX - Old ID {0} - New ID {1} - {2}", docInfo.DocID, myDoc.DocID, statMsg); // record in log file (aka error log) that conversion was done
// delete the temporary files
FileInfo orgFile = new FileInfo(orgFilename);
orgFile.Delete();// delete the old temporary Word file (.DOC or .RTF)
}
catch (Exception ex)
{
_MyLog.ErrorFormat("Error converting Word section to DOCX - {0}", ex.Message);
_MyLog.ErrorFormat("Error converting Word section to DOCX - ConvertWordSetionToDOXX: ItemID ={0} DOCID={1} LibTitle = {2}", itmInfo, docInfo.DocID, docInfo.LibTitle);
}
finally
{
if (pmsg != null)
pmsg.Close();// close the statue message
if (ap != null)
ap.Quit(); // close the Word app
if (doc != null)
doc.Close();
if (fs != null)
fs.Close();
if (fi != null && fi.Exists)
fi.Delete();// delete the temporary .DOCX file
}
}
/// <summary>
/// FixString processes the string returned and changes any symbols (0xF0??) to normal characters
/// </summary>

View File

@ -0,0 +1,72 @@

namespace Volian.Base.Library
{
partial class FrmPopupStatusMessage
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.popMsg = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// popMsg
//
this.popMsg.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
this.popMsg.Location = new System.Drawing.Point(13, 13);
this.popMsg.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.popMsg.Name = "popMsg";
this.popMsg.Size = new System.Drawing.Size(536, 16);
this.popMsg.TabIndex = 0;
this.popMsg.Text = "label1";
this.popMsg.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.popMsg.UseWaitCursor = true;
//
// FrmPopupStatusMessage
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
this.ClientSize = new System.Drawing.Size(562, 38);
this.ControlBox = false;
this.Controls.Add(this.popMsg);
this.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "FrmPopupStatusMessage";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "FrmPopupStatusMessage";
this.TopMost = true;
this.UseWaitCursor = true;
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Label popMsg;
}
}

View File

@ -0,0 +1,28 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace Volian.Base.Library
{
public partial class FrmPopupStatusMessage : Form
{
// This creates a simple message box consisting of a title and the message
// The purpose is to allow the coder to pop up brief status message during the running of a method for a 3rd party.
// i.e. this is used when PROMS uses Word to convert to a DOCX file format for PROMS Word sections.
// The message is centered in the message box - we can expand on this class if needed
// The coder uses the Show method to display the message box and Close to remove it
// The user is not prompted for a response.
public FrmPopupStatusMessage(string title, string msg)
{
InitializeComponent();
Text = title;
popMsg.Text = msg;
}
}
}

View File

@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@ -95,6 +95,12 @@
<Compile Include="FlagEnumEditor.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="FrmPopupStatusMessage.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmPopupStatusMessage.Designer.cs">
<DependentUpon>FrmPopupStatusMessage.cs</DependentUpon>
</Compile>
<Compile Include="frmRtfEdit.cs">
<SubType>Form</SubType>
</Compile>
@ -117,6 +123,9 @@
<Compile Include="VolianTimer.cs" />
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="FrmPopupStatusMessage.resx">
<DependentUpon>FrmPopupStatusMessage.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmRtfEdit.resx">
<DependentUpon>frmRtfEdit.cs</DependentUpon>
</EmbeddedResource>

View File

@ -655,6 +655,7 @@ namespace Volian.Controls.Library
}
else // Otherwise open it in the Word editor
{
Document.ConvertWordSectionToDOCX(myItemInfo); // B2023-093 Convert a Word section to the DOCX Word format if needed before opening it for edit
return OpenDSOTabPage(myItemInfo);
}
}
@ -827,7 +828,11 @@ namespace Volian.Controls.Library
private DisplayTabItem FindRemainingTab(Bar myBar)
{
// C2023-004: Proms reverts to first tab rather than active tab/save last selected tab is and use to reset to it
if (LastSelectedDisplayTabItem != null && !_RemovedDisplayTabItems.Contains(LastSelectedDisplayTabItem))
// B2023-078 Added the check for LastSelectedDisplayTabItem is in myBar. This fixes a crash issue where user has as split screen
// each with procedure tabs and closes a procedure tab in the split screen that does not currently have focus.
// that other screen has its own myBar list which does not contain the LastSelectedDisplayTabItem references.
// In that case we want to run through the foreach loop to find a tab in the currently active split screen side
if (LastSelectedDisplayTabItem != null && myBar.Items.Contains(LastSelectedDisplayTabItem) && !_RemovedDisplayTabItems.Contains(LastSelectedDisplayTabItem))
return LastSelectedDisplayTabItem;
foreach (DisplayTabItem itm in myBar.Items)
{

View File

@ -30,6 +30,7 @@ namespace Volian.Controls.Library
{
this.groupPanelPaginate = new DevComponents.DotNetBar.Controls.GroupPanel();
this.cbPrefPageBreak = new DevComponents.DotNetBar.Controls.CheckBoxX();
this.cbSubStepPageBreak = new DevComponents.DotNetBar.Controls.CheckBoxX();
this.cbPageBreak = new DevComponents.DotNetBar.Controls.CheckBoxX();
this.cbCAS = new DevComponents.DotNetBar.Controls.CheckBoxX();
this.cmbCheckoff = new DevComponents.DotNetBar.Controls.ComboBoxEx();
@ -74,6 +75,7 @@ namespace Volian.Controls.Library
this.groupPanelPaginate.BackColor = System.Drawing.Color.Transparent;
this.groupPanelPaginate.CanvasColor = System.Drawing.SystemColors.Control;
this.groupPanelPaginate.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.Office2007;
this.groupPanelPaginate.Controls.Add(this.cbSubStepPageBreak);
this.groupPanelPaginate.Controls.Add(this.cbPrefPageBreak);
this.groupPanelPaginate.Controls.Add(this.cbPageBreak);
this.groupPanelPaginate.DisabledBackColor = System.Drawing.Color.Empty;
@ -130,6 +132,23 @@ namespace Volian.Controls.Library
this.cbPrefPageBreak.Text = "Preferred Page Break (for Sup Info)";
this.cbPrefPageBreak.CheckedChanged += new System.EventHandler(this.cbPrefPageBreak_CheckedChanged);
//
// cbSubStepPageBreak
//
this.cbSubStepPageBreak.AutoSize = true;
//
//
//
this.cbSubStepPageBreak.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
this.cbSubStepPageBreak.Location = new System.Drawing.Point(3, 19);
this.cbSubStepPageBreak.Margin = new System.Windows.Forms.Padding(2);
this.cbSubStepPageBreak.Name = "cbSubStepPageBreak";
this.cbSubStepPageBreak.Size = new System.Drawing.Size(195, 15);
this.superTooltipTags.SetSuperTooltip(this.cbSubStepPageBreak, new DevComponents.DotNetBar.SuperTooltipInfo("Page Break for Sub-Steps", "", "When set, starts this step at the top of a page.\r\n\r\nkeyboard command: <Ctrl><Ente" +
"r>", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
this.cbSubStepPageBreak.TabIndex = 1;
this.cbSubStepPageBreak.Text = "Substep Page Break";
this.cbSubStepPageBreak.CheckedChanged += new System.EventHandler(this.cbSubStepPageBreak_CheckedChanged);
//
// cbPageBreak
//
this.cbPageBreak.AutoSize = true;
@ -770,6 +789,7 @@ namespace Volian.Controls.Library
private System.Windows.Forms.TrackBar trBarFS;
private System.Windows.Forms.Button btnFSrestore;
private DevComponents.DotNetBar.Controls.CheckBoxX cbPrefPageBreak;
private DevComponents.DotNetBar.Controls.CheckBoxX cbSubStepPageBreak;
private DevComponents.DotNetBar.Controls.CheckBoxX cbIncludeInTOC;
private DevComponents.DotNetBar.Controls.CheckBoxX cbTCAS;
}

View File

@ -110,6 +110,7 @@ namespace Volian.Controls.Library
cmbCheckoff.Enabled = false;
cbPageBreak.Enabled = false;
cbPrefPageBreak.Enabled = false;
cbSubStepPageBreak.Enabled = false;
cbPlaceKeeper.Enabled = false;
cbPlaceKeeperCont.Enabled = false;
cbIncludeInTOC.Enabled = false;
@ -244,10 +245,13 @@ namespace Volian.Controls.Library
groupPanelFigSize.Style.BackColor = Color.Cornsilk;
cbPageBreak.Checked = false; // will be set below if HLS & config has it on
cbPrefPageBreak.Checked = false;
cbSubStepPageBreak.Checked = false;
cbPlaceKeeper.Checked = false; // will be set below if HLS & config has this set
cbPlaceKeeperCont.Checked = false; // will be set below if substep & config has this set
cbPageBreak.Enabled = CurItemInfo.IsHigh;
cbPrefPageBreak.Visible = cbPrefPageBreak.Enabled = (!CurItemInfo.IsInSupInfo && CurItemInfo.MyDocStyle.SupplementalInformation);
// C2023-015: Pagination on a sub-step
cbSubStepPageBreak.Visible = cbSubStepPageBreak.Enabled = CurItemInfo.IsSubStep && CurItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.AlarmPagination;
if (!CurItemInfo.IsFigure && !CurItemInfo.IsRtfRaw)
{
cbPlaceKeeper.Enabled = (((SectionConfig)CurItemInfo.ActiveSection.MyConfig).Section_Placekeeper == "Y");
@ -304,6 +308,7 @@ namespace Volian.Controls.Library
if (CurItemInfo.IsHigh)
cbPageBreak.Checked = sc.Step_NewManualPagebreak; // High Level Step has a manual page break
if (cbPrefPageBreak.Enabled) cbPrefPageBreak.Checked = sc.Step_PreferredPagebreak;
if (cbSubStepPageBreak.Enabled) cbSubStepPageBreak.Checked = sc.Step_SubStepPagebreak;
cbPlaceKeeper.Checked = (sc.Step_Placekeeper == "Y"); // step text to be included on PlaceKeeper (Calvert Cliffs)
cbPlaceKeeperCont.Checked = (sc.Step_Placekeeper == "C"); // step is included on Placekeeper and marked as continuous action (Calvert Cliffs)
// set the Continuous Action Summary check box to the saved setting in the config or, if nothing in config, set to format flag setting
@ -891,7 +896,17 @@ namespace Volian.Controls.Library
sc.Step_PreferredPagebreak = cbPrefPageBreak.Checked;
MyEditItem.ChangeBarForConfigItemChange = true;
}
// C2023-015: Pagination on a sub-step
private void cbSubStepPageBreak_CheckedChanged(object sender, EventArgs e)
{
if (_Initalizing) return;
MyEditItem.SaveContents();
StepConfig sc = CurItemInfo.MyConfig as StepConfig;
if (sc == null) return;
MyEditItem.ChangeBarForConfigItemChange = false;
sc.Step_SubStepPagebreak = cbSubStepPageBreak.Checked;
MyEditItem.ChangeBarForConfigItemChange = true;
}
//private void txbxAltConActSumText_Leave(object sender, EventArgs e)
//{

View File

@ -99,13 +99,15 @@ namespace Volian.Print.Library
}
return retval;
}
else if (MyItemInfo.MyDocStyle.SupplementalInformation && MyItemInfo.IsStep)
// C2023-015: Pagination on a sub-step added. Do the code if supplemental info or if format supports sub-step pagination
else if ((MyItemInfo.MyDocStyle.SupplementalInformation || MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.AlarmPagination) && MyItemInfo.IsStep)
{
// if this is the first caution or note from a substep, if the substep has preferred page break, break at the first caution or note:
if ((MyItemInfo.IsCaution || MyItemInfo.IsNote) && MyItemInfo.MyParent.IsSubStep)
{
StepConfig scs = MyItemInfo.MyParent.MyConfig as StepConfig;
if (MyItemInfo.MyPrevious == null && scs.Step_PreferredPagebreak)
// C2023-015: Pagination on a sub-step added on this check
if (MyItemInfo.MyPrevious == null && (scs.Step_PreferredPagebreak || scs.Step_SubStepPagebreak))
{
// B2018-103: The following flags a break within the step. Before returning a '2' (flags break within step), clear it out of the
// ParaBreaks. Without the 'RemoveAt', a page break will occur after this step also.
@ -120,7 +122,7 @@ namespace Volian.Print.Library
}
// Now see if there is a preferred page break on this step.
StepConfig sci = MyItemInfo.MyConfig as StepConfig;
if (sci.Step_PreferredPagebreak)
if (sci.Step_PreferredPagebreak || sci.Step_SubStepPagebreak)
{
if (MyItemInfo.IsHigh) return 1;
// if this is the top caution/note return 1 also. Cautions always are first, that is why the check does not need to know if on a
@ -1472,7 +1474,8 @@ namespace Volian.Print.Library
// substep with preferred page break (B2017-109)
private SortedList<float, vlnParagraph> GetMyPreferredBreaks(StepLevelList myList)
{
if (!MyItemInfo.MyDocStyle.SupplementalInformation) return null;
// C2023-015: Pagination on a sub-step added. Do the code if supplemental info or if format supports sub-step pagination
if (!MyItemInfo.MyDocStyle.SupplementalInformation && !MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.AlarmPagination) return null;
SortedList<float, vlnParagraph> sdpara = null;
foreach (int stepLevel in myList.Keys) // loop thru StepLevels, starting with lowest.
{
@ -1480,7 +1483,7 @@ namespace Volian.Print.Library
{
vlnParagraph myPara = myList[stepLevel][yLocation];
StepConfig sci = myPara.MyItemInfo.MyConfig as StepConfig;
if (sci != null && sci.Step_PreferredPagebreak)
if (sci != null && sci.Step_PreferredPagebreak || sci.Step_SubStepPagebreak)
{
if (sdpara == null) sdpara = new SortedList<float, vlnParagraph>();
if (myPara.ChildrenAbove != null && myPara.ChildrenAbove.Count > 0) sdpara.Add(-yLocation, myPara.ChildrenAbove[0]);

View File

@ -761,6 +761,10 @@ namespace Volian.Print.Library
int cnt = 0;
foreach (SectionInfo mySection in myProcedure.Sections)
{
if (!mySection.MyDocStyle.IsStepSection && !mySection.IsAutoTOCSection)
{
VEPROMS.CSLA.Library.Document.ConvertWordSectionToDOCX((ItemInfo)mySection); // B2023-093 Convert a Word section to the DOCX Word format if needed before printing
}
//C2019-042 Section_IsFoldout checks Section Number, Section Title, and use of check box
if ((myProcedure.ActiveFormat.PlantFormat.FormatData.PrintData.SectionLevelFoldouts && (mySection.MyConfig as SectionConfig).Section_IsFoldout == "Y")
|| (myProcedure.ActiveFormat.PlantFormat.FormatData.PrintData.AlternateFloatingFoldout && (mySection.MyConfig as SectionConfig).Section_IsFoldout == "Y"))

View File

@ -7098,7 +7098,7 @@ namespace Volian.Print.Library
//if (paraLoc.MyParagraph.MyItemInfo.MyPrevious == null) // First substep
level = 0;
else
level = AlarmPagination?3:1; // B2023-088 make it easier to break on a sequential for alarms
level = 1; // AlarmPagination?3:1; // B2023-091: backout B2023-088 make it easier to break on a sequential for alarms
}
else if (AlarmPagination && paraLoc.MyParagraph.MyItemInfo.IsSubStep)
{

1
UpdateBranches.bat Normal file
View File

@ -0,0 +1 @@
start "" "%PROGRAMFILES%\Git\bin\sh.exe" -c "git fetch -p ; git branch -r | awk '{print $1}' | egrep -v -f /dev/fd/0 <(git branch -vv | grep origin) | awk '{print $1}' | xargs --no-run-if-empty git branch -d;"