diff --git a/LanguageMaster.xml b/LanguageMaster.xml
index 3445605d6..98f2900a2 100644
--- a/LanguageMaster.xml
+++ b/LanguageMaster.xml
@@ -2384,6 +2384,8 @@ Continue?
Treat word ending " in' " as " ing " (English only)
Remember "Use always" list
Live spell check
+ Live spell check - Working with language [{0}]
+ Live spell check - You don't have dictionaries for this language [{0}]
Image text
Spell check completed
Spell check aborted
diff --git a/src/libse/Common/Settings.cs b/src/libse/Common/Settings.cs
index afec315e2..c78c8a1ba 100644
--- a/src/libse/Common/Settings.cs
+++ b/src/libse/Common/Settings.cs
@@ -1811,6 +1811,7 @@ $HorzAlign = Center
public string GeneralDuplicateLine { get; set; }
public string GeneralToggleView { get; set; }
public string GeneralToggleMode { get; set; }
+ public string GeneralTogglePreviewOnVideo { get; set; }
public string GeneralHelp { get; set; }
public string MainFileNew { get; set; }
public string MainFileOpen { get; set; }
@@ -6386,6 +6387,12 @@ $HorzAlign = Center
shortcuts.GeneralToggleMode = subNode.InnerText;
}
+ subNode = node.SelectSingleNode("GeneralTogglePreviewOnVideo");
+ if (subNode != null)
+ {
+ shortcuts.GeneralTogglePreviewOnVideo = subNode.InnerText;
+ }
+
subNode = node.SelectSingleNode("GeneralHelp");
if (subNode != null)
{
@@ -8551,6 +8558,7 @@ $HorzAlign = Center
textWriter.WriteElementString("GeneralDuplicateLine", shortcuts.GeneralDuplicateLine);
textWriter.WriteElementString("GeneralToggleView", shortcuts.GeneralToggleView);
textWriter.WriteElementString("GeneralToggleMode", shortcuts.GeneralToggleMode);
+ textWriter.WriteElementString("GeneralTogglePreviewOnVideo", shortcuts.GeneralTogglePreviewOnVideo);
textWriter.WriteElementString("GeneralHelp", shortcuts.GeneralHelp);
textWriter.WriteElementString("MainFileNew", shortcuts.MainFileNew);
textWriter.WriteElementString("MainFileOpen", shortcuts.MainFileOpen);
diff --git a/src/ui/Forms/Main.cs b/src/ui/Forms/Main.cs
index f5bf308d1..160936a25 100644
--- a/src/ui/Forms/Main.cs
+++ b/src/ui/Forms/Main.cs
@@ -14464,6 +14464,22 @@ namespace Nikse.SubtitleEdit.Forms
e.SuppressKeyPress = true;
}
+ else if (_shortcuts.MainGeneralTogglePreviewOnVideo == e.KeyData)
+ {
+ Configuration.Settings.General.MpvHandlesPreviewText = !Configuration.Settings.General.MpvHandlesPreviewText;
+ if (mediaPlayer.VideoPlayer is LibMpvDynamic libMpv)
+ {
+ if (!Configuration.Settings.General.MpvHandlesPreviewText)
+ {
+ libMpv.RemoveSubtitle();
+ }
+ mediaPlayer.VideoPlayer = mediaPlayer.VideoPlayer;
+ mediaPlayer.SetSubtitleText(string.Empty, null, _subtitle);
+ ShowSubtitle();
+ }
+
+ e.SuppressKeyPress = true;
+ }
else if (_shortcuts.MainGeneralFileSaveAll == e.KeyData)
{
SaveAll();
diff --git a/src/ui/Forms/Options/Settings.cs b/src/ui/Forms/Options/Settings.cs
index dad0b2c26..92cbd4b38 100644
--- a/src/ui/Forms/Options/Settings.cs
+++ b/src/ui/Forms/Options/Settings.cs
@@ -1,8 +1,7 @@
-using Nikse.SubtitleEdit.Core;
-using Nikse.SubtitleEdit.Core.Common;
+using Nikse.SubtitleEdit.Core.Common;
using Nikse.SubtitleEdit.Core.Dictionaries;
using Nikse.SubtitleEdit.Core.Enums;
-using Nikse.SubtitleEdit.Core.Translate;
+using Nikse.SubtitleEdit.Core.Translate.Service;
using Nikse.SubtitleEdit.Logic;
using Nikse.SubtitleEdit.Logic.VideoPlayers;
using System;
@@ -17,7 +16,6 @@ using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Xml;
-using Nikse.SubtitleEdit.Core.Translate.Service;
namespace Nikse.SubtitleEdit.Forms.Options
{
@@ -1169,6 +1167,7 @@ namespace Nikse.SubtitleEdit.Forms.Options
AddNode(generalNode, language.DuplicateLine, nameof(Configuration.Settings.Shortcuts.GeneralDuplicateLine));
AddNode(generalNode, language.ToggleView, nameof(Configuration.Settings.Shortcuts.GeneralToggleView));
AddNode(generalNode, language.ToggleMode, nameof(Configuration.Settings.Shortcuts.GeneralToggleMode));
+ AddNode(generalNode, language.TogglePreviewOnVideo, nameof(Configuration.Settings.Shortcuts.GeneralTogglePreviewOnVideo));
AddNode(generalNode, language.Help, nameof(Configuration.Settings.Shortcuts.GeneralHelp), true);
if (generalNode.Nodes.Count > 0)
{
diff --git a/src/ui/Logic/Language.cs b/src/ui/Logic/Language.cs
index 6ed036f68..b98a9f525 100644
--- a/src/ui/Logic/Language.cs
+++ b/src/ui/Logic/Language.cs
@@ -2231,6 +2231,7 @@ can edit in same subtitle file (collaboration)",
ChooseProfile = "Choose profile",
DuplicateLine = "Duplicate line",
ToggleView = "Toggle list/source view",
+ TogglePreviewOnVideo = "Toogle preview on video",
ToggleMode = "Toggle translate/create/adjust mode",
Help = "Help",
FontInUi = "UI Font",
diff --git a/src/ui/Logic/LanguageDeserializer.cs b/src/ui/Logic/LanguageDeserializer.cs
index f0790508e..e1afd5b29 100644
--- a/src/ui/Logic/LanguageDeserializer.cs
+++ b/src/ui/Logic/LanguageDeserializer.cs
@@ -6523,6 +6523,12 @@ namespace Nikse.SubtitleEdit.Logic
case "SpellCheck/LiveSpellCheck":
language.SpellCheck.LiveSpellCheck = reader.Value;
break;
+ case "SpellCheck/LiveSpellCheckLanguage":
+ language.SpellCheck.LiveSpellCheckLanguage = reader.Value;
+ break;
+ case "SpellCheck/NoDictionaryForLiveSpellCheck":
+ language.SpellCheck.NoDictionaryForLiveSpellCheck = reader.Value;
+ break;
case "SpellCheck/ImageText":
language.SpellCheck.ImageText = reader.Value;
break;
diff --git a/src/ui/Logic/LanguageStructure.cs b/src/ui/Logic/LanguageStructure.cs
index 38438c969..71e2166e0 100644
--- a/src/ui/Logic/LanguageStructure.cs
+++ b/src/ui/Logic/LanguageStructure.cs
@@ -2088,6 +2088,7 @@
public string DuplicateLine { get; set; }
public string ToggleView { get; set; }
public string ToggleMode { get; set; }
+ public string TogglePreviewOnVideo { get; set; }
public string Help { get; set; }
public string FontInUi { get; set; }
public string ShowFrameRate { get; set; }
diff --git a/src/ui/Logic/MainShortcuts.cs b/src/ui/Logic/MainShortcuts.cs
index 63788a91f..544f983e0 100644
--- a/src/ui/Logic/MainShortcuts.cs
+++ b/src/ui/Logic/MainShortcuts.cs
@@ -78,6 +78,7 @@ namespace Nikse.SubtitleEdit.Logic
public Keys MainGeneralDuplicateLine { get; set; }
public Keys MainGeneralToggleView { get; set; }
public Keys MainGeneralToggleMode { get; set; }
+ public Keys MainGeneralTogglePreviewOnVideo { get; set; }
public Keys MainTextBoxSplitAtCursor { get; set; }
public Keys MainTextBoxSplitAtCursorAndVideoPos { get; set; }
public Keys MainTextBoxSplitSelectedLineBilingual { get; set; }
@@ -260,6 +261,7 @@ namespace Nikse.SubtitleEdit.Logic
MainGeneralDuplicateLine = UiUtil.GetKeys(Configuration.Settings.Shortcuts.GeneralDuplicateLine);
MainGeneralToggleView = UiUtil.GetKeys(Configuration.Settings.Shortcuts.GeneralToggleView);
MainGeneralToggleMode = UiUtil.GetKeys(Configuration.Settings.Shortcuts.GeneralToggleMode);
+ MainGeneralTogglePreviewOnVideo = UiUtil.GetKeys(Configuration.Settings.Shortcuts.GeneralTogglePreviewOnVideo);
MainVideoFullscreen = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainVideoFullscreen);
MainVideoSlower = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainVideoSlower);
MainVideoFaster = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainVideoFaster);