mirror of
https://github.com/Crypto-Notepad/Crypto-Notepad.git
synced 2026-03-11 08:55:25 +00:00
Added search panel border setting
This commit is contained in:
parent
89e1e69f1a
commit
cf2de9bc0e
6 changed files with 57 additions and 1 deletions
|
|
@ -159,6 +159,9 @@
|
||||||
<setting name="editorBorder" serializeAs="String">
|
<setting name="editorBorder" serializeAs="String">
|
||||||
<value>None</value>
|
<value>None</value>
|
||||||
</setting>
|
</setting>
|
||||||
|
<setting name="searchPanelBorder" serializeAs="String">
|
||||||
|
<value>Single</value>
|
||||||
|
</setting>
|
||||||
</Crypto_Notepad.Properties.Settings>
|
</Crypto_Notepad.Properties.Settings>
|
||||||
</userSettings>
|
</userSettings>
|
||||||
</configuration>
|
</configuration>
|
||||||
|
|
|
||||||
|
|
@ -555,6 +555,7 @@ private void LoadSettings()
|
||||||
searchWholeWordCheckBox.ForeColor = settings.searchPanelForeColor;
|
searchWholeWordCheckBox.ForeColor = settings.searchPanelForeColor;
|
||||||
searchFindNextButton.ForeColor = settings.searchPanelForeColor;
|
searchFindNextButton.ForeColor = settings.searchPanelForeColor;
|
||||||
searchCloseButton.ForeColor = settings.searchPanelForeColor;
|
searchCloseButton.ForeColor = settings.searchPanelForeColor;
|
||||||
|
searchPanel.CellBorderStyle = (TableLayoutPanelCellBorderStyle)Enum.Parse(typeof(TableLayoutPanelCellBorderStyle), settings.searchPanelBorder);
|
||||||
lineNumbers.Visible = bool.Parse(settings.lineNumbersVisible);
|
lineNumbers.Visible = bool.Parse(settings.lineNumbersVisible);
|
||||||
lineNumbers.Show_BorderLines = bool.Parse(settings.borderLinesVisible);
|
lineNumbers.Show_BorderLines = bool.Parse(settings.borderLinesVisible);
|
||||||
lineNumbers.Show_GridLines = bool.Parse(settings.gridLinesVisible);
|
lineNumbers.Show_GridLines = bool.Parse(settings.gridLinesVisible);
|
||||||
|
|
@ -753,7 +754,6 @@ private void MainForm_Shown(object sender, EventArgs e)
|
||||||
private void MainWindow_Load(object sender, EventArgs e)
|
private void MainWindow_Load(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
Visible = false;
|
Visible = false;
|
||||||
searchPanel.CellBorderStyle = TableLayoutPanelCellBorderStyle.Single;
|
|
||||||
LoadSettings();
|
LoadSettings();
|
||||||
DeleteUpdateFiles();
|
DeleteUpdateFiles();
|
||||||
MenuIcons(settings.menuIcons);
|
MenuIcons(settings.menuIcons);
|
||||||
|
|
|
||||||
13
Crypto Notepad/Properties/Settings.Designer.cs
generated
13
Crypto Notepad/Properties/Settings.Designer.cs
generated
|
|
@ -660,5 +660,18 @@ public string editorBorder {
|
||||||
this["editorBorder"] = value;
|
this["editorBorder"] = value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[global::System.Configuration.UserScopedSettingAttribute()]
|
||||||
|
[global::System.Configuration.SettingsProviderAttribute(typeof(PortableSettingsProvider))]
|
||||||
|
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||||
|
[global::System.Configuration.DefaultSettingValueAttribute("Single")]
|
||||||
|
public string searchPanelBorder {
|
||||||
|
get {
|
||||||
|
return ((string)(this["searchPanelBorder"]));
|
||||||
|
}
|
||||||
|
set {
|
||||||
|
this["searchPanelBorder"] = value;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -149,5 +149,8 @@
|
||||||
<Setting Name="editorBorder" Provider="PortableSettingsProvider" Type="System.String" Scope="User">
|
<Setting Name="editorBorder" Provider="PortableSettingsProvider" Type="System.String" Scope="User">
|
||||||
<Value Profile="(Default)">None</Value>
|
<Value Profile="(Default)">None</Value>
|
||||||
</Setting>
|
</Setting>
|
||||||
|
<Setting Name="searchPanelBorder" Provider="PortableSettingsProvider" Type="System.String" Scope="User">
|
||||||
|
<Value Profile="(Default)">Single</Value>
|
||||||
|
</Setting>
|
||||||
</Settings>
|
</Settings>
|
||||||
</SettingsFile>
|
</SettingsFile>
|
||||||
29
Crypto Notepad/SettingsForm.Designer.cs
generated
29
Crypto Notepad/SettingsForm.Designer.cs
generated
|
|
@ -113,6 +113,8 @@ private void InitializeComponent()
|
||||||
this.searchBackColorLabel = new System.Windows.Forms.Label();
|
this.searchBackColorLabel = new System.Windows.Forms.Label();
|
||||||
this.settingsNavigation = new System.Windows.Forms.ListBox();
|
this.settingsNavigation = new System.Windows.Forms.ListBox();
|
||||||
this.fontDialog = new System.Windows.Forms.FontDialog();
|
this.fontDialog = new System.Windows.Forms.FontDialog();
|
||||||
|
this.searchBorderLabel = new System.Windows.Forms.Label();
|
||||||
|
this.searchBorderComboBox = new System.Windows.Forms.ComboBox();
|
||||||
this.settingsTabControl.SuspendLayout();
|
this.settingsTabControl.SuspendLayout();
|
||||||
this.editorTabPage.SuspendLayout();
|
this.editorTabPage.SuspendLayout();
|
||||||
this.applicationTabPage.SuspendLayout();
|
this.applicationTabPage.SuspendLayout();
|
||||||
|
|
@ -1042,6 +1044,8 @@ private void InitializeComponent()
|
||||||
//
|
//
|
||||||
this.searchPanelTabPage.BackColor = System.Drawing.SystemColors.Window;
|
this.searchPanelTabPage.BackColor = System.Drawing.SystemColors.Window;
|
||||||
this.searchPanelTabPage.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
|
this.searchPanelTabPage.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
|
||||||
|
this.searchPanelTabPage.Controls.Add(this.searchBorderComboBox);
|
||||||
|
this.searchPanelTabPage.Controls.Add(this.searchBorderLabel);
|
||||||
this.searchPanelTabPage.Controls.Add(this.searchFontColor);
|
this.searchPanelTabPage.Controls.Add(this.searchFontColor);
|
||||||
this.searchPanelTabPage.Controls.Add(this.searchBackColor);
|
this.searchPanelTabPage.Controls.Add(this.searchBackColor);
|
||||||
this.searchPanelTabPage.Controls.Add(this.searchFontColorLabel);
|
this.searchPanelTabPage.Controls.Add(this.searchFontColorLabel);
|
||||||
|
|
@ -1128,6 +1132,28 @@ private void InitializeComponent()
|
||||||
this.fontDialog.ShowEffects = false;
|
this.fontDialog.ShowEffects = false;
|
||||||
this.fontDialog.Apply += new System.EventHandler(this.FontDialog_Apply);
|
this.fontDialog.Apply += new System.EventHandler(this.FontDialog_Apply);
|
||||||
//
|
//
|
||||||
|
// searchBorderLabel
|
||||||
|
//
|
||||||
|
this.searchBorderLabel.AutoSize = true;
|
||||||
|
this.searchBorderLabel.Location = new System.Drawing.Point(6, 61);
|
||||||
|
this.searchBorderLabel.Name = "searchBorderLabel";
|
||||||
|
this.searchBorderLabel.Size = new System.Drawing.Size(42, 15);
|
||||||
|
this.searchBorderLabel.TabIndex = 4;
|
||||||
|
this.searchBorderLabel.Text = "Border";
|
||||||
|
//
|
||||||
|
// searchBorderComboBox
|
||||||
|
//
|
||||||
|
this.searchBorderComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
|
this.searchBorderComboBox.FormattingEnabled = true;
|
||||||
|
this.searchBorderComboBox.Items.AddRange(new object[] {
|
||||||
|
"None",
|
||||||
|
"Single"});
|
||||||
|
this.searchBorderComboBox.Location = new System.Drawing.Point(132, 58);
|
||||||
|
this.searchBorderComboBox.Name = "searchBorderComboBox";
|
||||||
|
this.searchBorderComboBox.Size = new System.Drawing.Size(100, 23);
|
||||||
|
this.searchBorderComboBox.TabIndex = 5;
|
||||||
|
this.searchBorderComboBox.DropDownClosed += new System.EventHandler(this.SearchBorderComboBox_DropDownClosed);
|
||||||
|
//
|
||||||
// SettingsForm
|
// SettingsForm
|
||||||
//
|
//
|
||||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||||
|
|
@ -1168,6 +1194,7 @@ private void InitializeComponent()
|
||||||
this.toolbarTabPage.ResumeLayout(false);
|
this.toolbarTabPage.ResumeLayout(false);
|
||||||
this.toolbarTabPage.PerformLayout();
|
this.toolbarTabPage.PerformLayout();
|
||||||
this.searchPanelTabPage.ResumeLayout(false);
|
this.searchPanelTabPage.ResumeLayout(false);
|
||||||
|
this.searchPanelTabPage.PerformLayout();
|
||||||
this.ResumeLayout(false);
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -1258,5 +1285,7 @@ private void InitializeComponent()
|
||||||
private System.Windows.Forms.CheckBox minimizeToTrayCheckBox;
|
private System.Windows.Forms.CheckBox minimizeToTrayCheckBox;
|
||||||
private System.Windows.Forms.ComboBox editorBorderComboBox;
|
private System.Windows.Forms.ComboBox editorBorderComboBox;
|
||||||
private System.Windows.Forms.Label editorBorderLabel;
|
private System.Windows.Forms.Label editorBorderLabel;
|
||||||
|
private System.Windows.Forms.ComboBox searchBorderComboBox;
|
||||||
|
private System.Windows.Forms.Label searchBorderLabel;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -47,6 +47,7 @@ private void LoadSettings()
|
||||||
|
|
||||||
searchBackColor.BackColor = settings.searchPanelBackColor;
|
searchBackColor.BackColor = settings.searchPanelBackColor;
|
||||||
searchFontColor.BackColor = settings.searchPanelForeColor;
|
searchFontColor.BackColor = settings.searchPanelForeColor;
|
||||||
|
searchBorderComboBox.Text = settings.searchPanelBorder;
|
||||||
|
|
||||||
toolbarBackColor.BackColor = settings.toolbarBackColor;
|
toolbarBackColor.BackColor = settings.toolbarBackColor;
|
||||||
toolbarBorderCheckBox.Checked = settings.toolbarBorder;
|
toolbarBorderCheckBox.Checked = settings.toolbarBorder;
|
||||||
|
|
@ -822,6 +823,13 @@ private void EditorBorderComboBox_DropDownClosed(object sender, EventArgs e)
|
||||||
settings.editorBorder = editorBorderComboBox.Text;
|
settings.editorBorder = editorBorderComboBox.Text;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void SearchBorderComboBox_DropDownClosed(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
MainForm main = Owner as MainForm;
|
||||||
|
main.searchPanel.CellBorderStyle = (TableLayoutPanelCellBorderStyle)Enum.Parse(typeof(TableLayoutPanelCellBorderStyle), searchBorderComboBox.Text);
|
||||||
|
settings.searchPanelBorder = searchBorderComboBox.Text;
|
||||||
|
}
|
||||||
|
|
||||||
/*Settings Section*/
|
/*Settings Section*/
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue