diff --git a/Crypto Notepad/Crypto Notepad.csproj b/Crypto Notepad/Crypto Notepad.csproj
index 6f0aff7..137bae0 100644
--- a/Crypto Notepad/Crypto Notepad.csproj
+++ b/Crypto Notepad/Crypto Notepad.csproj
@@ -199,6 +199,8 @@
+
+
diff --git a/Crypto Notepad/Forms/MainForm.Designer.cs b/Crypto Notepad/Forms/MainForm.Designer.cs
index 53e2944..d4f5450 100644
--- a/Crypto Notepad/Forms/MainForm.Designer.cs
+++ b/Crypto Notepad/Forms/MainForm.Designer.cs
@@ -59,6 +59,7 @@ public void InitializeComponent()
this.clearClipboardMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.wordWrapMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.readOnlyMainMenu = new System.Windows.Forms.ToolStripMenuItem();
+ this.insertDateTimeMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.mainMenuSeparator7 = new System.Windows.Forms.ToolStripSeparator();
this.clearMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.toolsMainMenu = new System.Windows.Forms.ToolStripMenuItem();
@@ -314,6 +315,7 @@ public void InitializeComponent()
this.clearClipboardMainMenu,
this.wordWrapMainMenu,
this.readOnlyMainMenu,
+ this.insertDateTimeMainMenu,
this.mainMenuSeparator7,
this.clearMainMenu});
this.editMainMenu.ForeColor = System.Drawing.SystemColors.ControlText;
@@ -434,6 +436,14 @@ public void InitializeComponent()
this.readOnlyMainMenu.Text = "Readonly";
this.readOnlyMainMenu.Click += new System.EventHandler(this.ReadOnlyMainMenu_Click);
//
+ // insertDateTimeMainMenu
+ //
+ this.insertDateTimeMainMenu.Name = "insertDateTimeMainMenu";
+ this.insertDateTimeMainMenu.ShortcutKeys = System.Windows.Forms.Keys.F5;
+ this.insertDateTimeMainMenu.Size = new System.Drawing.Size(198, 22);
+ this.insertDateTimeMainMenu.Text = "Insert Date Time";
+ this.insertDateTimeMainMenu.Click += new System.EventHandler(this.InsertDateTimeMainMenu_Click);
+ //
// mainMenuSeparator7
//
this.mainMenuSeparator7.Name = "mainMenuSeparator7";
@@ -1548,5 +1558,6 @@ public void InitializeComponent()
private System.Windows.Forms.ToolStripMenuItem pasteBoardMainMenu;
private System.Windows.Forms.Timer pasteBoardTimer;
protected internal System.Windows.Forms.ToolStripStatusLabel statusPanelPasteboardLabel;
+ private System.Windows.Forms.ToolStripMenuItem insertDateTimeMainMenu;
}
}
diff --git a/Crypto Notepad/Forms/MainForm.cs b/Crypto Notepad/Forms/MainForm.cs
index 5c86b5f..b04fd0f 100644
--- a/Crypto Notepad/Forms/MainForm.cs
+++ b/Crypto Notepad/Forms/MainForm.cs
@@ -681,6 +681,7 @@ public void MenuIcons(bool menuIcons)
clearClipboardMainMenu.Image = Resources.clipboard_minus;
wordWrapMainMenu.Image = Resources.wrap_option;
readOnlyMainMenu.Image = Resources.document_pencil;
+ insertDateTimeMainMenu.Image = Resources.clock_plus;
clearMainMenu.Image = Resources.document;
changePasswordMainMenu.Image = Resources.key;
lockMainMenu.Image = Resources.lock_warning;
@@ -788,6 +789,7 @@ public void ToolbarIcons(bool oldIcons)
pasteToolbarButton.Image = Resources.old_paste_plain;
changePasswordToolbarButton.Image = Resources.old_page_white_key;
lockToolbarButton.Image = Resources.old_lock;
+ insertDateTimeMainMenu.Image = Resources.old_clock_add;
tryToDecryptToolbarButton.Image = Resources.old_lock_edit;
settingsToolbarButton.Image = Resources.old_setting_tools;
alwaysOnTopToolbarButton.Image = Resources.old_application_double;
@@ -804,6 +806,7 @@ public void ToolbarIcons(bool oldIcons)
pasteToolbarButton.Image = Resources.clipboard;
changePasswordToolbarButton.Image = Resources.key;
lockToolbarButton.Image = Resources.lock_warning;
+ insertDateTimeMainMenu.Image = Resources.clock_plus;
tryToDecryptToolbarButton.Image = Resources.lock_pencil;
settingsToolbarButton.Image = Resources.gear;
alwaysOnTopToolbarButton.Image = Resources.applications_blue;
@@ -836,6 +839,18 @@ private void RichTextBox_ModifiedChanged(object sender, EventArgs e)
Text = Text.Replace("*", string.Empty);
}
}
+ //if (richTextBox.Modified == true)
+ //{
+ // if (!Text.Contains("*"))
+ // {
+ // Text = Text.Insert(0, "*");
+ // if (string.IsNullOrEmpty(PublicVar.openFileName) & richTextBox.TextLength > 0)
+ // {
+ // Text = "Unnamed.cnp" + " – " + PublicVar.appName;
+ // Text = Text.Insert(0, "*");
+ // }
+ // }
+ //}
}
private void StatusPanel_VisibleChanged(object sender, EventArgs e)
{
@@ -1144,7 +1159,7 @@ private void RichTextBox_DragDrop(object sender, DragEventArgs e)
private void RichTextBox_TextChanged(object sender, EventArgs e)
{
- statusPanelTimer.Start();
+ statusPanelTimer.Start();
if (richTextBox.Modified)
{
if (!Text.Contains("*"))
@@ -1610,6 +1625,24 @@ private void ReadOnlyMainMenu_Click(object sender, EventArgs e)
statusPanelReadonlyLabel.Text = "Readonly: " + readOnlyMainMenu.Checked.ToString();
}
+ private void InsertDateTimeMainMenu_Click(object sender, EventArgs e)
+ {
+ DateTime now = DateTime.Now;
+ richTextBox.Text += now.ToString();
+ richTextBox.SelectionStart = richTextBox.Text.Length;
+ richTextBox.ScrollToCaret();
+ richTextBox.Modified = true;
+ if (!Text.Contains("*"))
+ {
+ Text = Text.Insert(0, "*");
+ if (string.IsNullOrEmpty(PublicVar.openFileName) & richTextBox.TextLength > 0)
+ {
+ Text = "Unnamed.cnp" + " – " + PublicVar.appName;
+ Text = Text.Insert(0, "*");
+ }
+ }
+ }
+
private void WordWrapMainMenu_Click(object sender, EventArgs e)
{
richTextBox.WordWrap = wordWrapMainMenu.Checked;
@@ -2292,10 +2325,10 @@ private void VariablesMainMenu_Click(object sender, EventArgs e)
+
+
+
#endregion
-
-
-
}
}
\ No newline at end of file
diff --git a/Crypto Notepad/Properties/Resources.Designer.cs b/Crypto Notepad/Properties/Resources.Designer.cs
index 9d42889..81df502 100644
--- a/Crypto Notepad/Properties/Resources.Designer.cs
+++ b/Crypto Notepad/Properties/Resources.Designer.cs
@@ -19,7 +19,7 @@ namespace Crypto_Notepad.Properties {
// class via a tool like ResGen or Visual Studio.
// To add or remove a member, edit your .ResX file then rerun ResGen
// with the /str option, or rebuild your VS project.
- [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources {
@@ -160,6 +160,16 @@ internal static System.Drawing.Bitmap clipboard_text {
}
}
+ ///
+ /// Looks up a localized resource of type System.Drawing.Bitmap.
+ ///
+ internal static System.Drawing.Bitmap clock_plus {
+ get {
+ object obj = ResourceManager.GetObject("clock_plus", resourceCulture);
+ return ((System.Drawing.Bitmap)(obj));
+ }
+ }
+
///
/// Looks up a localized resource of type System.Drawing.Bitmap.
///
@@ -420,6 +430,16 @@ internal static System.Drawing.Bitmap old_application_double {
}
}
+ ///
+ /// Looks up a localized resource of type System.Drawing.Bitmap.
+ ///
+ internal static System.Drawing.Bitmap old_clock_add {
+ get {
+ object obj = ResourceManager.GetObject("old_clock_add", resourceCulture);
+ return ((System.Drawing.Bitmap)(obj));
+ }
+ }
+
///
/// Looks up a localized resource of type System.Drawing.Bitmap.
///
diff --git a/Crypto Notepad/Properties/Resources.resx b/Crypto Notepad/Properties/Resources.resx
index c1ae435..0e197c7 100644
--- a/Crypto Notepad/Properties/Resources.resx
+++ b/Crypto Notepad/Properties/Resources.resx
@@ -827,7 +827,7 @@
XTesb3QPLh88M+QwdP6m681Lt7xuXbu94vbgcOjwnZHokdE77DtTd1PuvriXeW/h/sYH6AdFD6UeVjxS
fNTws+7PbaOWo6fHXMf6Hwc/vj/OGn/2S8Yv7ycKnpCfVEyqTDZPmU2dmnafvvF05dOJZ+nPFmYKf5X+
tfa5zvMffnP8rX82YnbiBf/Fp99LXsq/PPRq2aueuYC5R69TXy/MF72Rf3P4LeNt37vwd5MLWe+x7ys/
- 6H7o/ujz8cGn1E+f/gUDmPP8usTo0wAAAAlwSFlzAAALEwAACxMBAJqcGAAALoFJREFUeF7t3X3o7Vd1
+ 6H7o/ujz8cGn1E+f/gUDmPP8usTo0wAAAAlwSFlzAAALEgAACxIB0t1+/AAALoFJREFUeF7t3X3o7Vd1
53FBEAIFoSAUAoLgXwUf8nSdTOzMoNQRUiyVDmFSBgYEO/EpNU18aDSJSWgkbaY6qTJ2Ok2JWELFpo5W
+zBRR8fU0IzWmNZMklGTjq0mmsbEufGa3/l9Z6277k3vPfdz9v2e81tnf8/e3/eCF5XV3LPO75y9v9/P
73E/axgGAAAwM7IJAAD6JpsAAKBvsgkAAPommwAAoG+yCQAA+iabAACgb7IJAAD6JpsAAKBvsgkAAPom
@@ -1126,4 +1126,10 @@
..\Resources\clipboard-text.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+ ..\Resources\clock--plus.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\clock_add.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
\ No newline at end of file
diff --git a/Crypto Notepad/Resources/clock--plus.png b/Crypto Notepad/Resources/clock--plus.png
new file mode 100644
index 0000000..9e64118
Binary files /dev/null and b/Crypto Notepad/Resources/clock--plus.png differ
diff --git a/Crypto Notepad/Resources/clock_add.png b/Crypto Notepad/Resources/clock_add.png
new file mode 100644
index 0000000..5e637a4
Binary files /dev/null and b/Crypto Notepad/Resources/clock_add.png differ