diff --git a/ShareX.HistoryLib/Forms/HistoryForm.cs b/ShareX.HistoryLib/Forms/HistoryForm.cs index eddaaf1d4..31d52a99d 100644 --- a/ShareX.HistoryLib/Forms/HistoryForm.cs +++ b/ShareX.HistoryLib/Forms/HistoryForm.cs @@ -74,6 +74,8 @@ public HistoryForm(string historyPath, HistorySettings settings, Action scHistoryItemInfo.SplitterWidth = 7; // Because of bug must be assigned here again scHistoryItemInfo.Panel2Collapsed = true; + tstbSearch.TextBox.HandleCreated += (sender, e) => tstbSearch.TextBox.SetWatermark(Resources.HistoryForm_Search_Watermark, true); + if (Settings.RememberSearchText) { tstbSearch.Text = Settings.SearchText; diff --git a/ShareX.HistoryLib/Forms/ImageHistoryForm.cs b/ShareX.HistoryLib/Forms/ImageHistoryForm.cs index 2a359febe..051d63c11 100644 --- a/ShareX.HistoryLib/Forms/ImageHistoryForm.cs +++ b/ShareX.HistoryLib/Forms/ImageHistoryForm.cs @@ -25,6 +25,7 @@ You should have received a copy of the GNU General Public License using Manina.Windows.Forms; using ShareX.HelpersLib; +using ShareX.HistoryLib.Properties; using System; using System.Collections.Generic; using System.Drawing; @@ -75,6 +76,8 @@ public ImageHistoryForm(string historyPath, ImageHistorySettings settings, Actio defaultTitle = Text; + tstbSearch.TextBox.HandleCreated += (sender, e) => tstbSearch.TextBox.SetWatermark(Resources.HistoryForm_Search_Watermark, true); + if (Settings.RememberSearchText) { tstbSearch.Text = Settings.SearchText; diff --git a/ShareX.HistoryLib/Properties/Resources.Designer.cs b/ShareX.HistoryLib/Properties/Resources.Designer.cs index 2727813ea..c47356036 100644 --- a/ShareX.HistoryLib/Properties/Resources.Designer.cs +++ b/ShareX.HistoryLib/Properties/Resources.Designer.cs @@ -109,6 +109,15 @@ internal static System.Drawing.Bitmap globe { } } + /// + /// Looks up a localized string similar to File name, window title, process name etc.. + /// + internal static string HistoryForm_Search_Watermark { + get { + return ResourceManager.GetString("HistoryForm_Search_Watermark", resourceCulture); + } + } + /// /// Looks up a localized string similar to Filtered: {0}. /// diff --git a/ShareX.HistoryLib/Properties/Resources.resx b/ShareX.HistoryLib/Properties/Resources.resx index cddcc3235..cc6731dc1 100644 --- a/ShareX.HistoryLib/Properties/Resources.resx +++ b/ShareX.HistoryLib/Properties/Resources.resx @@ -250,4 +250,7 @@ ..\Resources\layout-header-3-mix.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + File name, window title, process name etc. + \ No newline at end of file