diff --git a/Crypto Notepad/App.config b/Crypto Notepad/App.config
index 5b81458..e31a2d9 100644
--- a/Crypto Notepad/App.config
+++ b/Crypto Notepad/App.config
@@ -156,6 +156,9 @@
False
+
+ None
+
diff --git a/Crypto Notepad/ChangeKeyForm.Designer.cs b/Crypto Notepad/ChangeKeyForm.Designer.cs
index b023ecb..4f2193a 100644
--- a/Crypto Notepad/ChangeKeyForm.Designer.cs
+++ b/Crypto Notepad/ChangeKeyForm.Designer.cs
@@ -1,4 +1,4 @@
-namespace Crypto_Notepad
+namespace Crypto_Notepad
{
partial class ChangeKeyForm
{
diff --git a/Crypto Notepad/ChangeKeyForm.cs b/Crypto Notepad/ChangeKeyForm.cs
index 4b8f47c..a527746 100644
--- a/Crypto Notepad/ChangeKeyForm.cs
+++ b/Crypto Notepad/ChangeKeyForm.cs
@@ -1,4 +1,4 @@
-using System;
+using System;
using System.Drawing;
using System.Media;
using System.Threading.Tasks;
diff --git a/Crypto Notepad/EnterKeyForm.cs b/Crypto Notepad/EnterKeyForm.cs
index b3f3f42..60d4922 100644
--- a/Crypto Notepad/EnterKeyForm.cs
+++ b/Crypto Notepad/EnterKeyForm.cs
@@ -1,4 +1,4 @@
-using System;
+using System;
using System.Windows.Forms;
namespace Crypto_Notepad
diff --git a/Crypto Notepad/MainForm.Designer.cs b/Crypto Notepad/MainForm.Designer.cs
index 74d9ed3..47c1825 100644
--- a/Crypto Notepad/MainForm.Designer.cs
+++ b/Crypto Notepad/MainForm.Designer.cs
@@ -124,6 +124,7 @@ public void InitializeComponent()
this.toolTip = new System.Windows.Forms.ToolTip(this.components);
this.richTextBox = new Crypto_Notepad.ExRichTextBox();
this.lineNumbers = new LineNumbers.LineNumbers();
+ this.richTextBoxPanel = new System.Windows.Forms.Panel();
this.mainMenu.SuspendLayout();
this.contextMenu.SuspendLayout();
this.searchPanel.SuspendLayout();
@@ -146,6 +147,7 @@ public void InitializeComponent()
this.trayMenu.SuspendLayout();
this.fileLockedPanel.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.fileLockedShowKey)).BeginInit();
+ this.richTextBoxPanel.SuspendLayout();
this.SuspendLayout();
//
// mainMenu
@@ -1026,19 +1028,19 @@ public void InitializeComponent()
this.showTrayMenu,
this.exitTrayMenu});
this.trayMenu.Name = "mnuTray";
- this.trayMenu.Size = new System.Drawing.Size(181, 70);
+ this.trayMenu.Size = new System.Drawing.Size(104, 48);
//
// showTrayMenu
//
this.showTrayMenu.Name = "showTrayMenu";
- this.showTrayMenu.Size = new System.Drawing.Size(180, 22);
+ this.showTrayMenu.Size = new System.Drawing.Size(103, 22);
this.showTrayMenu.Text = "Show";
this.showTrayMenu.Click += new System.EventHandler(this.ShowTrayMenu_Click);
//
// exitTrayMenu
//
this.exitTrayMenu.Name = "exitTrayMenu";
- this.exitTrayMenu.Size = new System.Drawing.Size(180, 22);
+ this.exitTrayMenu.Size = new System.Drawing.Size(103, 22);
this.exitTrayMenu.Text = "Exit";
this.exitTrayMenu.Click += new System.EventHandler(this.ExitTrayMenu_Click);
//
@@ -1055,7 +1057,7 @@ public void InitializeComponent()
this.fileLockedPanel.Controls.Add(this.fileLockedLabel);
this.fileLockedPanel.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204)));
this.fileLockedPanel.ForeColor = System.Drawing.Color.Azure;
- this.fileLockedPanel.Location = new System.Drawing.Point(103, 84);
+ this.fileLockedPanel.Location = new System.Drawing.Point(106, 28);
this.fileLockedPanel.Name = "fileLockedPanel";
this.fileLockedPanel.Size = new System.Drawing.Size(261, 91);
this.fileLockedPanel.TabIndex = 20;
@@ -1068,7 +1070,7 @@ public void InitializeComponent()
this.encryptionKeyPlaceholder.BackColor = System.Drawing.SystemColors.Window;
this.encryptionKeyPlaceholder.Cursor = System.Windows.Forms.Cursors.IBeam;
this.encryptionKeyPlaceholder.ForeColor = System.Drawing.Color.DarkGray;
- this.encryptionKeyPlaceholder.Location = new System.Drawing.Point(10, 37);
+ this.encryptionKeyPlaceholder.Location = new System.Drawing.Point(11, 37);
this.encryptionKeyPlaceholder.Name = "encryptionKeyPlaceholder";
this.encryptionKeyPlaceholder.Size = new System.Drawing.Size(82, 13);
this.encryptionKeyPlaceholder.TabIndex = 12;
@@ -1087,6 +1089,7 @@ public void InitializeComponent()
this.fileLockedCloseButton.Name = "fileLockedCloseButton";
this.fileLockedCloseButton.Size = new System.Drawing.Size(23, 23);
this.fileLockedCloseButton.TabIndex = 11;
+ this.fileLockedCloseButton.TabStop = false;
this.fileLockedCloseButton.Text = "X";
this.fileLockedCloseButton.UseVisualStyleBackColor = true;
this.fileLockedCloseButton.MouseClick += new System.Windows.Forms.MouseEventHandler(this.FileLockedCloseButton_MouseClick);
@@ -1143,15 +1146,15 @@ public void InitializeComponent()
// richTextBox
//
this.richTextBox.AcceptsTab = true;
- this.richTextBox.BackColor = System.Drawing.Color.White;
+ this.richTextBox.BackColor = System.Drawing.Color.Gainsboro;
this.richTextBox.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.richTextBox.ContextMenuStrip = this.contextMenu;
this.richTextBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.richTextBox.Font = new System.Drawing.Font("Microsoft Sans Serif", 10F);
this.richTextBox.ForeColor = System.Drawing.Color.Black;
- this.richTextBox.Location = new System.Drawing.Point(22, 48);
+ this.richTextBox.Location = new System.Drawing.Point(0, 0);
this.richTextBox.Name = "richTextBox";
- this.richTextBox.Size = new System.Drawing.Size(462, 163);
+ this.richTextBox.Size = new System.Drawing.Size(460, 161);
this.richTextBox.TabIndex = 16;
this.richTextBox.Text = "";
this.richTextBox.CursorPositionChanged += new System.EventHandler(this.RichTextBox_CursorPositionChanged);
@@ -1202,14 +1205,24 @@ public void InitializeComponent()
this.lineNumbers.Size = new System.Drawing.Size(22, 163);
this.lineNumbers.TabIndex = 19;
//
+ // richTextBoxPanel
+ //
+ this.richTextBoxPanel.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
+ this.richTextBoxPanel.Controls.Add(this.fileLockedPanel);
+ this.richTextBoxPanel.Controls.Add(this.richTextBox);
+ this.richTextBoxPanel.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.richTextBoxPanel.Location = new System.Drawing.Point(22, 48);
+ this.richTextBoxPanel.Name = "richTextBoxPanel";
+ this.richTextBoxPanel.Size = new System.Drawing.Size(462, 163);
+ this.richTextBoxPanel.TabIndex = 21;
+ //
// MainForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackColor = System.Drawing.Color.White;
this.ClientSize = new System.Drawing.Size(484, 261);
- this.Controls.Add(this.fileLockedPanel);
- this.Controls.Add(this.richTextBox);
+ this.Controls.Add(this.richTextBoxPanel);
this.Controls.Add(this.lineNumbers);
this.Controls.Add(this.searchPanel);
this.Controls.Add(this.toolbarPanel);
@@ -1255,6 +1268,7 @@ public void InitializeComponent()
this.fileLockedPanel.ResumeLayout(false);
this.fileLockedPanel.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.fileLockedShowKey)).EndInit();
+ this.richTextBoxPanel.ResumeLayout(false);
this.ResumeLayout(false);
this.PerformLayout();
@@ -1344,7 +1358,6 @@ public void InitializeComponent()
protected internal System.Windows.Forms.NotifyIcon trayIcon;
private System.Windows.Forms.Panel fileLockedPanel;
private System.Windows.Forms.Label fileLockedLabel;
- public System.Windows.Forms.TextBox fileLockedKeyTextBox;
private System.Windows.Forms.PictureBox fileLockedShowKey;
private System.Windows.Forms.Button fileLockedOkButton;
private System.Windows.Forms.Button fileLockedCloseButton;
@@ -1355,5 +1368,7 @@ public void InitializeComponent()
private System.Windows.Forms.ToolStripMenuItem showTrayMenu;
private System.Windows.Forms.ToolStripMenuItem exitTrayMenu;
private System.Windows.Forms.Label encryptionKeyPlaceholder;
+ protected internal System.Windows.Forms.TextBox fileLockedKeyTextBox;
+ protected internal System.Windows.Forms.Panel richTextBoxPanel;
}
}
diff --git a/Crypto Notepad/MainForm.cs b/Crypto Notepad/MainForm.cs
index 03dd1b5..0eb8f27 100644
--- a/Crypto Notepad/MainForm.cs
+++ b/Crypto Notepad/MainForm.cs
@@ -530,6 +530,7 @@ private void LoadSettings()
{
trayIcon.Visible = true;
}
+ richTextBoxPanel.BorderStyle = (BorderStyle)Enum.Parse(typeof(BorderStyle), settings.editorBorder);
wordWrapMainMenu.Checked = settings.editorWrap;
toolbarPanel.BackColor = settings.toolbarBackColor;
toolbarPanel.Visible = settings.toolbarVisible;
diff --git a/Crypto Notepad/Properties/Settings.Designer.cs b/Crypto Notepad/Properties/Settings.Designer.cs
index 7073055..4d204c0 100644
--- a/Crypto Notepad/Properties/Settings.Designer.cs
+++ b/Crypto Notepad/Properties/Settings.Designer.cs
@@ -647,5 +647,18 @@ public bool alwaysOnTop {
this["alwaysOnTop"] = value;
}
}
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Configuration.SettingsProviderAttribute(typeof(PortableSettingsProvider))]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("None")]
+ public string editorBorder {
+ get {
+ return ((string)(this["editorBorder"]));
+ }
+ set {
+ this["editorBorder"] = value;
+ }
+ }
}
}
diff --git a/Crypto Notepad/Properties/Settings.settings b/Crypto Notepad/Properties/Settings.settings
index cf48e62..ef6050e 100644
--- a/Crypto Notepad/Properties/Settings.settings
+++ b/Crypto Notepad/Properties/Settings.settings
@@ -146,5 +146,8 @@
False
+
+ None
+
\ No newline at end of file
diff --git a/Crypto Notepad/SettingsForm.Designer.cs b/Crypto Notepad/SettingsForm.Designer.cs
index 094a2c8..4505354 100644
--- a/Crypto Notepad/SettingsForm.Designer.cs
+++ b/Crypto Notepad/SettingsForm.Designer.cs
@@ -111,6 +111,8 @@ private void InitializeComponent()
this.searchBackColorLabel = new System.Windows.Forms.Label();
this.settingsNavigation = new System.Windows.Forms.ListBox();
this.fontDialog = new System.Windows.Forms.FontDialog();
+ this.editorBorderComboBox = new System.Windows.Forms.ComboBox();
+ this.editorBorderLabel = new System.Windows.Forms.Label();
this.settingsTabControl.SuspendLayout();
this.editorTabPage.SuspendLayout();
this.applicationTabPage.SuspendLayout();
@@ -164,6 +166,8 @@ private void InitializeComponent()
this.editorTabPage.AutoScroll = true;
this.editorTabPage.BackColor = System.Drawing.SystemColors.Window;
this.editorTabPage.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
+ this.editorTabPage.Controls.Add(this.editorBorderLabel);
+ this.editorTabPage.Controls.Add(this.editorBorderComboBox);
this.editorTabPage.Controls.Add(this.editorOpenLinksWithComboBox);
this.editorTabPage.Controls.Add(this.editorOpenLinksWithLabel);
this.editorTabPage.Controls.Add(this.editorFontButton);
@@ -207,7 +211,7 @@ private void InitializeComponent()
//
// editorFontButton
//
- this.editorFontButton.Location = new System.Drawing.Point(9, 142);
+ this.editorFontButton.Location = new System.Drawing.Point(9, 171);
this.editorFontButton.Name = "editorFontButton";
this.editorFontButton.Size = new System.Drawing.Size(223, 23);
this.editorFontButton.TabIndex = 17;
@@ -894,7 +898,7 @@ private void InitializeComponent()
// statusPanelVisibleCheckBox
//
this.statusPanelVisibleCheckBox.AutoSize = true;
- this.statusPanelVisibleCheckBox.Location = new System.Drawing.Point(6, 55);
+ this.statusPanelVisibleCheckBox.Location = new System.Drawing.Point(9, 66);
this.statusPanelVisibleCheckBox.Name = "statusPanelVisibleCheckBox";
this.statusPanelVisibleCheckBox.Size = new System.Drawing.Size(60, 19);
this.statusPanelVisibleCheckBox.TabIndex = 2;
@@ -972,7 +976,7 @@ private void InitializeComponent()
// toolbarBorderCheckBox
//
this.toolbarBorderCheckBox.AutoSize = true;
- this.toolbarBorderCheckBox.Location = new System.Drawing.Point(9, 41);
+ this.toolbarBorderCheckBox.Location = new System.Drawing.Point(9, 66);
this.toolbarBorderCheckBox.Name = "toolbarBorderCheckBox";
this.toolbarBorderCheckBox.Size = new System.Drawing.Size(61, 19);
this.toolbarBorderCheckBox.TabIndex = 12;
@@ -1003,7 +1007,7 @@ private void InitializeComponent()
// toolbarVisibleCheckBox
//
this.toolbarVisibleCheckBox.AutoSize = true;
- this.toolbarVisibleCheckBox.Location = new System.Drawing.Point(9, 66);
+ this.toolbarVisibleCheckBox.Location = new System.Drawing.Point(9, 41);
this.toolbarVisibleCheckBox.Name = "toolbarVisibleCheckBox";
this.toolbarVisibleCheckBox.Size = new System.Drawing.Size(60, 19);
this.toolbarVisibleCheckBox.TabIndex = 2;
@@ -1100,6 +1104,29 @@ private void InitializeComponent()
this.fontDialog.ShowEffects = false;
this.fontDialog.Apply += new System.EventHandler(this.FontDialog_Apply);
//
+ // editorBorderComboBox
+ //
+ this.editorBorderComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+ this.editorBorderComboBox.FormattingEnabled = true;
+ this.editorBorderComboBox.Items.AddRange(new object[] {
+ "None",
+ "FixedSingle",
+ "Fixed3D"});
+ this.editorBorderComboBox.Location = new System.Drawing.Point(132, 142);
+ this.editorBorderComboBox.Name = "editorBorderComboBox";
+ this.editorBorderComboBox.Size = new System.Drawing.Size(100, 23);
+ this.editorBorderComboBox.TabIndex = 20;
+ this.editorBorderComboBox.DropDownClosed += new System.EventHandler(this.EditorBorderComboBox_DropDownClosed);
+ //
+ // editorBorderLabel
+ //
+ this.editorBorderLabel.AutoSize = true;
+ this.editorBorderLabel.Location = new System.Drawing.Point(6, 145);
+ this.editorBorderLabel.Name = "editorBorderLabel";
+ this.editorBorderLabel.Size = new System.Drawing.Size(42, 15);
+ this.editorBorderLabel.TabIndex = 21;
+ this.editorBorderLabel.Text = "Border";
+ //
// SettingsForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
@@ -1228,5 +1255,7 @@ private void InitializeComponent()
private System.Windows.Forms.GroupBox borderLinesGroupBox;
private System.Windows.Forms.CheckBox closeToTrayCheckBox;
private System.Windows.Forms.CheckBox minimizeToTrayCheckBox;
+ private System.Windows.Forms.ComboBox editorBorderComboBox;
+ private System.Windows.Forms.Label editorBorderLabel;
}
}
\ No newline at end of file
diff --git a/Crypto Notepad/SettingsForm.cs b/Crypto Notepad/SettingsForm.cs
index 48166e6..8c9487b 100644
--- a/Crypto Notepad/SettingsForm.cs
+++ b/Crypto Notepad/SettingsForm.cs
@@ -27,6 +27,7 @@ private void LoadSettings()
editorInsertKeyComboBox.Text = settings.insertKey;
editorPaddingLeftTextBox.Text = settings.editorPaddingLeft;
editorOpenLinksWithComboBox.Text = settings.openLinks;
+ editorBorderComboBox.Text = settings.editorBorder;
fontDialog.Font = settings.editorFont;
autoLockOnMinimizeCheckBox.Checked = settings.autoLock;
@@ -813,6 +814,13 @@ private void CloseToTrayCheckBox_Click(object sender, EventArgs e)
settings.closeToTray = closeToTrayCheckBox.Checked;
}
+ private void EditorBorderComboBox_DropDownClosed(object sender, EventArgs e)
+ {
+ MainForm main = Owner as MainForm;
+ main.richTextBoxPanel.BorderStyle = (BorderStyle)Enum.Parse(typeof(BorderStyle), editorBorderComboBox.Text);
+ settings.editorBorder = editorBorderComboBox.Text;
+ }
+
/*Settings Section*/