diff --git a/PROMS/Volian.Controls.Library/DisplayTags.Designer.cs b/PROMS/Volian.Controls.Library/DisplayTags.Designer.cs index 9c6193ec..f0b1778a 100644 --- a/PROMS/Volian.Controls.Library/DisplayTags.Designer.cs +++ b/PROMS/Volian.Controls.Library/DisplayTags.Designer.cs @@ -43,9 +43,9 @@ namespace Volian.Controls.Library this.cbChgAll = new System.Windows.Forms.CheckBox(); this.listBoxStepTypes = new System.Windows.Forms.ListBox(); this.superTooltipTags = new DevComponents.DotNetBar.SuperTooltip(); - this.groupPanelIncludeOn = new DevComponents.DotNetBar.Controls.GroupPanel(); this.cbPlaceKeeperCont = new DevComponents.DotNetBar.Controls.CheckBoxX(); this.cbPlaceKeeper = new DevComponents.DotNetBar.Controls.CheckBoxX(); + this.groupPanelIncludeOn = new DevComponents.DotNetBar.Controls.GroupPanel(); this.groupPanelWcnTrnResp = new DevComponents.DotNetBar.Controls.GroupPanel(); this.tbRespons = new System.Windows.Forms.TextBox(); this.groupPanelPaginate.SuspendLayout(); @@ -110,7 +110,8 @@ namespace Volian.Controls.Library this.cbPageBreak.Margin = new System.Windows.Forms.Padding(2); this.cbPageBreak.Name = "cbPageBreak"; this.cbPageBreak.Size = new System.Drawing.Size(122, 15); - this.superTooltipTags.SetSuperTooltip(this.cbPageBreak, new DevComponents.DotNetBar.SuperTooltipInfo("Manual Page Break", "", "When set, starts this step at the top of a page.", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); + this.superTooltipTags.SetSuperTooltip(this.cbPageBreak, new DevComponents.DotNetBar.SuperTooltipInfo("Manual Page Break", "", "When set, starts this step at the top of a page.\r\n\r\nkeyboard command: ", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); this.cbPageBreak.TabIndex = 0; this.cbPageBreak.Text = "Manual Page Break"; this.cbPageBreak.CheckedChanged += new System.EventHandler(this.cbPageBreak_CheckedChanged); @@ -127,7 +128,8 @@ namespace Volian.Controls.Library this.cbCAS.Margin = new System.Windows.Forms.Padding(2); this.cbCAS.Name = "cbCAS"; this.cbCAS.Size = new System.Drawing.Size(162, 15); - this.superTooltipTags.SetSuperTooltip(this.cbCAS, new DevComponents.DotNetBar.SuperTooltipInfo("Continuous Action Summary", "", "Include this in the Continuous Action Summary section", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); + this.superTooltipTags.SetSuperTooltip(this.cbCAS, new DevComponents.DotNetBar.SuperTooltipInfo("Continuous Action Summary", "", "Include this in the Continuous Action Summary section\r\n\r\nkeyboard command: ", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); this.cbCAS.TabIndex = 1; this.cbCAS.Text = "Continuous Action Summary"; this.cbCAS.CheckedChanged += new System.EventHandler(this.cbCAS_CheckedChanged); @@ -236,6 +238,7 @@ namespace Volian.Controls.Library // // this.groupPanelChgBar.StyleMouseOver.CornerType = DevComponents.DotNetBar.eCornerType.Square; + this.superTooltipTags.SetSuperTooltip(this.groupPanelChgBar, new DevComponents.DotNetBar.SuperTooltipInfo("Change Bars", "", "This allows you to toggle the change bar on/off.\r\nkeyboard command: ", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); this.groupPanelChgBar.TabIndex = 18; this.groupPanelChgBar.Text = "Change Bar"; // @@ -266,7 +269,7 @@ namespace Volian.Controls.Library this.rbChgBarOff.Name = "rbChgBarOff"; this.rbChgBarOff.Size = new System.Drawing.Size(45, 17); this.superTooltipTags.SetSuperTooltip(this.rbChgBarOff, new DevComponents.DotNetBar.SuperTooltipInfo("Change Bar OFF", "", "Turn change bar off. Note that \'OVERRIDE\' will turn off a change bar even though" + - " text is changed.", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); + " text is changed.\r\n\r\nkeyboard command: ", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); this.rbChgBarOff.TabIndex = 2; this.rbChgBarOff.TabStop = true; this.rbChgBarOff.Text = "OFF"; @@ -280,7 +283,7 @@ namespace Volian.Controls.Library this.rbChgBarOn.Margin = new System.Windows.Forms.Padding(2); this.rbChgBarOn.Name = "rbChgBarOn"; this.rbChgBarOn.Size = new System.Drawing.Size(41, 17); - this.superTooltipTags.SetSuperTooltip(this.rbChgBarOn, new DevComponents.DotNetBar.SuperTooltipInfo("Change Bar ON", "", "Add a change bar on this step", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); + this.superTooltipTags.SetSuperTooltip(this.rbChgBarOn, new DevComponents.DotNetBar.SuperTooltipInfo("Change Bar ON", "", "Add a change bar on this step\r\n\r\nkeyboard command: ", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); this.rbChgBarOn.TabIndex = 1; this.rbChgBarOn.TabStop = true; this.rbChgBarOn.Text = "ON"; @@ -381,6 +384,41 @@ namespace Volian.Controls.Library this.superTooltipTags.DefaultTooltipSettings = new DevComponents.DotNetBar.SuperTooltipInfo("", "", "", null, null, DevComponents.DotNetBar.eTooltipColor.Gray); this.superTooltipTags.LicenseKey = "F962CEC7-CD8F-4911-A9E9-CAB39962FC1F"; // + // cbPlaceKeeperCont + // + this.cbPlaceKeeperCont.AutoSize = true; + this.cbPlaceKeeperCont.BackColor = System.Drawing.Color.Transparent; + // + // + // + this.cbPlaceKeeperCont.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square; + this.cbPlaceKeeperCont.Location = new System.Drawing.Point(3, 47); + this.cbPlaceKeeperCont.Margin = new System.Windows.Forms.Padding(2); + this.cbPlaceKeeperCont.Name = "cbPlaceKeeperCont"; + this.cbPlaceKeeperCont.Size = new System.Drawing.Size(158, 15); + this.superTooltipTags.SetSuperTooltip(this.cbPlaceKeeperCont, new DevComponents.DotNetBar.SuperTooltipInfo("Placekeeper Continuous Action", "", "Include this on the Placekeeper marked as a Continuous Action\r\n\r\nkeyboard command" + + ": ", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); + this.cbPlaceKeeperCont.TabIndex = 1; + this.cbPlaceKeeperCont.Text = "Placekeeper as Cont Action"; + this.cbPlaceKeeperCont.CheckedChanged += new System.EventHandler(this.cbPlaceKeeperCont_CheckedChanged); + // + // cbPlaceKeeper + // + this.cbPlaceKeeper.AutoSize = true; + this.cbPlaceKeeper.BackColor = System.Drawing.Color.Transparent; + // + // + // + this.cbPlaceKeeper.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square; + this.cbPlaceKeeper.Location = new System.Drawing.Point(3, 28); + this.cbPlaceKeeper.Margin = new System.Windows.Forms.Padding(2); + this.cbPlaceKeeper.Name = "cbPlaceKeeper"; + this.cbPlaceKeeper.Size = new System.Drawing.Size(84, 15); + this.superTooltipTags.SetSuperTooltip(this.cbPlaceKeeper, new DevComponents.DotNetBar.SuperTooltipInfo("Placekeeper", "", "Include this on the Placekeeper\r\n\r\nkeyboard command: ", null, null, DevComponents.DotNetBar.eTooltipColor.Gray)); + this.cbPlaceKeeper.TabIndex = 1; + this.cbPlaceKeeper.Text = "Placekeeper"; + this.cbPlaceKeeper.CheckedChanged += new System.EventHandler(this.cbPlacekeeper_CheckedChanged); + // // groupPanelIncludeOn // this.groupPanelIncludeOn.BackColor = System.Drawing.Color.Transparent; @@ -426,38 +464,6 @@ namespace Volian.Controls.Library this.groupPanelIncludeOn.TabIndex = 17; this.groupPanelIncludeOn.Text = "Include On"; // - // cbPlaceKeeperCont - // - this.cbPlaceKeeperCont.AutoSize = true; - this.cbPlaceKeeperCont.BackColor = System.Drawing.Color.Transparent; - // - // - // - this.cbPlaceKeeperCont.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square; - this.cbPlaceKeeperCont.Location = new System.Drawing.Point(3, 47); - this.cbPlaceKeeperCont.Margin = new System.Windows.Forms.Padding(2); - this.cbPlaceKeeperCont.Name = "cbPlaceKeeperCont"; - this.cbPlaceKeeperCont.Size = new System.Drawing.Size(158, 15); - this.cbPlaceKeeperCont.TabIndex = 1; - this.cbPlaceKeeperCont.Text = "Placekeeper as Cont Action"; - this.cbPlaceKeeperCont.CheckedChanged += new System.EventHandler(this.cbPlaceKeeperCont_CheckedChanged); - // - // cbPlaceKeeper - // - this.cbPlaceKeeper.AutoSize = true; - this.cbPlaceKeeper.BackColor = System.Drawing.Color.Transparent; - // - // - // - this.cbPlaceKeeper.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square; - this.cbPlaceKeeper.Location = new System.Drawing.Point(3, 28); - this.cbPlaceKeeper.Margin = new System.Windows.Forms.Padding(2); - this.cbPlaceKeeper.Name = "cbPlaceKeeper"; - this.cbPlaceKeeper.Size = new System.Drawing.Size(84, 15); - this.cbPlaceKeeper.TabIndex = 1; - this.cbPlaceKeeper.Text = "Placekeeper"; - this.cbPlaceKeeper.CheckedChanged += new System.EventHandler(this.cbPlacekeeper_CheckedChanged); - // // groupPanelWcnTrnResp // this.groupPanelWcnTrnResp.BackColor = System.Drawing.Color.Transparent; diff --git a/PROMS/Volian.Controls.Library/DisplayTags.cs b/PROMS/Volian.Controls.Library/DisplayTags.cs index 6b9586d6..9988b513 100644 --- a/PROMS/Volian.Controls.Library/DisplayTags.cs +++ b/PROMS/Volian.Controls.Library/DisplayTags.cs @@ -65,6 +65,8 @@ namespace Volian.Controls.Library } _MyEditItem = value; CurItemInfo = value.MyItemInfo; + _MyEditItem.MyStepPropertiesPanel = this; // this allows us to access the Step Property pannel and toggle check boxes with shortcut keystrokes + // originally the change all (for step type) checkbox was initialized based // on whether all steps at level were same type, i.e. if same type, default // it to checked. This may confuse the user, so we decided to always default @@ -135,6 +137,35 @@ namespace Volian.Controls.Library // left here in case we change our mind. //groupPanelChgStepType.Style.BackColor = Color.PaleVioletRed; } + public void ToggleChangeBar() // for use with shortcut keystoke + { + if (rbChgBarOff.Checked) + rbChgBarOn.Checked = true; + else + rbChgBarOff.Checked = true; + } + + public void ToggleContActSummary() // for use with shortcut keystroke + { + cbCAS.Checked = !cbCAS.Checked; + } + public void TogglePlaceKeeper() // for use with shortcut keystroke + { + cbPlaceKeeper.Checked = !cbPlaceKeeper.Checked; + } + public void TogglePlaceKeeperContAct() // for use with shortcut keystroke F7> + { + cbPlaceKeeperCont.Checked = !cbPlaceKeeperCont.Checked; + } + public void UpdatePageBreakCheckBox() // for use with shortcut keystroke + { + StepConfig sc = CurItemInfo.MyConfig as StepConfig; + if (CurItemInfo.IsHigh) cbPageBreak.Checked = false; // Page Break is set to false + if (sc != null && CurItemInfo.IsHigh) // otherwise, get data from config + cbPageBreak.Checked = sc.Step_NewManualPagebreak; // High Level Step has a manual page break + else + cbPageBreak.Checked = false; // Page Break is set to false + } private void TagsFillIn() { _Initalizing = true; diff --git a/PROMS/Volian.Controls.Library/EditItem.cs b/PROMS/Volian.Controls.Library/EditItem.cs index cce255a0..628e3f51 100644 --- a/PROMS/Volian.Controls.Library/EditItem.cs +++ b/PROMS/Volian.Controls.Library/EditItem.cs @@ -157,6 +157,14 @@ namespace Volian.Controls.Library get { return _MyStepPanel; } set { _MyStepPanel = value; } } + + private DisplayTags _MyStepPropertiesPanel; + public DisplayTags MyStepPropertiesPanel // gives us access to the Step Properties panel - used with shortcut keystrokes + { + get { return _MyStepPropertiesPanel; } + set { _MyStepPropertiesPanel = value; } + } + /// /// This returns the section or procedure for the current item. /// If the item is a step or section, it returns the section @@ -1682,6 +1690,45 @@ namespace Volian.Controls.Library protected void InsertPgBrk() { MyStepPanel.MyStepTabPanel.MyStepTabRibbon.btnInsPgBrk_Click(this, new EventArgs()); + MyStepPropertiesPanel.UpdatePageBreakCheckBox(); // update the checkbox on the Step Properties panel + if (!MyStepRTB.ContainsFocus) + MyStepRTB.Focus(); + } + protected void ToggleChangeBar() + { + MyStepPropertiesPanel.ToggleChangeBar(); // update the checkbox on the Step Properties panel + if (!MyStepRTB.ContainsFocus) + MyStepRTB.Focus(); + } + protected void ToggleContinuousActionSummary() + { + MyStepPropertiesPanel.ToggleContActSummary(); // update the checkbox on the Step Properties panel + if (!MyStepRTB.ContainsFocus) + MyStepRTB.Focus(); + } + protected void TogglePlaceKeeper() + { + MyStepPropertiesPanel.TogglePlaceKeeper(); // update the checkbox on the Step Properties panel + if (!MyStepRTB.ContainsFocus) + MyStepRTB.Focus(); + } + protected void TogglePlaceKeeperContAct() + { + MyStepPropertiesPanel.TogglePlaceKeeperContAct(); // update the checkbox on the Step Properties panel + if (!MyStepRTB.ContainsFocus) + MyStepRTB.Focus(); + } + protected void ToggleSuperScript() + { + MyStepPanel.MyStepTabPanel.MyStepTabRibbon.btnSuperscript_Click(this, new EventArgs()); // click the Superscrpt button on the ribbon + if (!MyStepRTB.ContainsFocus) + MyStepRTB.Focus(); + } + protected void ToggleSubScript() + { + MyStepPanel.MyStepTabPanel.MyStepTabRibbon.btnSubscript_Click(this, new EventArgs()); // click the Subscrpt button on the ribbon + if (!MyStepRTB.ContainsFocus) + MyStepRTB.Focus(); } protected void OpenAnnotations() {