mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-10-27 06:22:38 +01:00
Added spell check option about one-letter-words to Options -> Settings -> Tools UI
git-svn-id: https://subtitleedit.googlecode.com/svn/trunk@2175 99eadd0c-20b8-1223-b5c4-2a2b2df33de2
This commit is contained in:
parent
21e923e4e3
commit
be0f7fcb33
@ -6168,7 +6168,7 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
else if (prev != null)
|
||||
{
|
||||
newParagraph.StartTime.TotalMilliseconds = prev.EndTime.TotalMilliseconds + addMilliseconds;
|
||||
newParagraph.EndTime.TotalMilliseconds = newParagraph.StartTime.TotalMilliseconds + 2000;
|
||||
newParagraph.EndTime.TotalMilliseconds = newParagraph.StartTime.TotalMilliseconds + Configuration.Settings.General.NewEmptyDefaultMs;
|
||||
if (next != null && newParagraph.EndTime.TotalMilliseconds > next.StartTime.TotalMilliseconds)
|
||||
newParagraph.EndTime.TotalMilliseconds = next.StartTime.TotalMilliseconds - 1;
|
||||
if (newParagraph.StartTime.TotalMilliseconds > newParagraph.EndTime.TotalMilliseconds)
|
||||
@ -6264,7 +6264,7 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
addMilliseconds = 1;
|
||||
|
||||
newParagraph.StartTime.TotalMilliseconds = prev.EndTime.TotalMilliseconds + addMilliseconds;
|
||||
newParagraph.EndTime.TotalMilliseconds = newParagraph.StartTime.TotalMilliseconds + 2000;
|
||||
newParagraph.EndTime.TotalMilliseconds = newParagraph.StartTime.TotalMilliseconds + Configuration.Settings.General.NewEmptyDefaultMs;
|
||||
if (next != null && newParagraph.EndTime.TotalMilliseconds > next.StartTime.TotalMilliseconds)
|
||||
newParagraph.EndTime.TotalMilliseconds = next.StartTime.TotalMilliseconds - 1;
|
||||
if (newParagraph.StartTime.TotalMilliseconds > newParagraph.EndTime.TotalMilliseconds)
|
||||
@ -12859,7 +12859,7 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
}
|
||||
|
||||
// create and insert
|
||||
var newParagraph = new Paragraph("", totalMilliseconds, totalMilliseconds + 2000);
|
||||
var newParagraph = new Paragraph("", totalMilliseconds, totalMilliseconds + Configuration.Settings.General.NewEmptyDefaultMs);
|
||||
if (GetCurrentSubtitleFormat().IsFrameBased)
|
||||
{
|
||||
newParagraph.CalculateFrameNumbersFromTimeCodes(CurrentFrameRate);
|
||||
|
13
src/Forms/Settings.Designer.cs
generated
13
src/Forms/Settings.Designer.cs
generated
@ -258,6 +258,7 @@
|
||||
this.colorDialogSSAStyle = new System.Windows.Forms.ColorDialog();
|
||||
this.fontDialogSSAStyle = new System.Windows.Forms.FontDialog();
|
||||
this.labelStatus = new System.Windows.Forms.Label();
|
||||
this.checkBoxSpellCheckOneLetterWords = new System.Windows.Forms.CheckBox();
|
||||
this.tabControlSettings.SuspendLayout();
|
||||
this.tabPageGenerel.SuspendLayout();
|
||||
this.groupBoxMiscellaneous.SuspendLayout();
|
||||
@ -1982,6 +1983,7 @@
|
||||
//
|
||||
// groupBoxSpellCheck
|
||||
//
|
||||
this.groupBoxSpellCheck.Controls.Add(this.checkBoxSpellCheckOneLetterWords);
|
||||
this.groupBoxSpellCheck.Controls.Add(this.checkBoxSpellCheckAutoChangeNames);
|
||||
this.groupBoxSpellCheck.Location = new System.Drawing.Point(6, 283);
|
||||
this.groupBoxSpellCheck.Name = "groupBoxSpellCheck";
|
||||
@ -2998,6 +3000,16 @@
|
||||
this.labelStatus.TabIndex = 3;
|
||||
this.labelStatus.Text = "labelStatus";
|
||||
//
|
||||
// checkBoxSpellCheckOneLetterWords
|
||||
//
|
||||
this.checkBoxSpellCheckOneLetterWords.AutoSize = true;
|
||||
this.checkBoxSpellCheckOneLetterWords.Location = new System.Drawing.Point(16, 43);
|
||||
this.checkBoxSpellCheckOneLetterWords.Name = "checkBoxSpellCheckOneLetterWords";
|
||||
this.checkBoxSpellCheckOneLetterWords.Size = new System.Drawing.Size(205, 17);
|
||||
this.checkBoxSpellCheckOneLetterWords.TabIndex = 1;
|
||||
this.checkBoxSpellCheckOneLetterWords.Text = "Prompt for unknown one letter words";
|
||||
this.checkBoxSpellCheckOneLetterWords.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// Settings
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
@ -3329,5 +3341,6 @@
|
||||
private System.Windows.Forms.GroupBox groupBoxPreview;
|
||||
private System.Windows.Forms.PictureBox pictureBoxPreview;
|
||||
private System.Windows.Forms.CheckBox checkBoxSsaOpaqueBox;
|
||||
private System.Windows.Forms.CheckBox checkBoxSpellCheckOneLetterWords;
|
||||
}
|
||||
}
|
@ -373,6 +373,9 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
checkBoxFixCommonOcrErrorsUsingHardcodedRules.Text = language.FixCommonOcrErrorsUseHardcodedRules;
|
||||
groupBoxSpellCheck.Text = language.SpellCheck;
|
||||
checkBoxSpellCheckAutoChangeNames.Text = Configuration.Settings.Language.SpellCheck.AutoFixNames;
|
||||
checkBoxSpellCheckOneLetterWords.Text = Configuration.Settings.Language.SpellCheck.CheckOneLetterWords;
|
||||
if (string.IsNullOrEmpty(Configuration.Settings.Language.SpellCheck.CheckOneLetterWords))
|
||||
checkBoxSpellCheckOneLetterWords.Visible = false;
|
||||
|
||||
comboBoxListViewDoubleClickEvent.Items.Clear();
|
||||
comboBoxListViewDoubleClickEvent.Items.Add(language.MainListViewNothing);
|
||||
@ -486,7 +489,7 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
textBoxMusicSymbolsToReplace.Text = toolsSettings.MusicSymbolToReplace;
|
||||
checkBoxFixCommonOcrErrorsUsingHardcodedRules.Checked = toolsSettings.OcrFixUseHardcodedRules;
|
||||
checkBoxSpellCheckAutoChangeNames.Checked = toolsSettings.SpellCheckAutoChangeNames;
|
||||
|
||||
checkBoxSpellCheckOneLetterWords.Checked = toolsSettings.SpellCheckOneLetterWords;
|
||||
|
||||
buttonOK.Text = Configuration.Settings.Language.General.OK;
|
||||
buttonCancel.Text = Configuration.Settings.Language.General.Cancel;
|
||||
@ -984,6 +987,7 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
toolsSettings.MusicSymbol = comboBoxToolsMusicSymbol.SelectedItem.ToString();
|
||||
toolsSettings.MusicSymbolToReplace = textBoxMusicSymbolsToReplace.Text;
|
||||
toolsSettings.SpellCheckAutoChangeNames = checkBoxSpellCheckAutoChangeNames.Checked;
|
||||
toolsSettings.SpellCheckOneLetterWords = checkBoxSpellCheckOneLetterWords.Checked;
|
||||
toolsSettings.OcrFixUseHardcodedRules = checkBoxFixCommonOcrErrorsUsingHardcodedRules.Checked;
|
||||
|
||||
WordListSettings wordListSettings = Configuration.Settings.WordLists;
|
||||
|
@ -1838,6 +1838,7 @@ can edit in same subtitle file (collaboration)",
|
||||
EditWordOnly = "Edit word only",
|
||||
AddXToNamesEtc = "Add '{0}' to names/etc list",
|
||||
AutoFixNames = "Auto fix names where only casing differ",
|
||||
CheckOneLetterWords = "Prompt for unknown one letter words",
|
||||
ImageText = "Image text",
|
||||
SpellCheckCompleted ="Spell check completed.",
|
||||
SpellCheckAborted = "Spell check aborted",
|
||||
|
@ -1736,6 +1736,7 @@
|
||||
public string EditWordOnly { get; set; }
|
||||
public string AddXToNamesEtc { get; set; }
|
||||
public string AutoFixNames { get; set; }
|
||||
public string CheckOneLetterWords { get; set; }
|
||||
public string ImageText { get; set; }
|
||||
public string SpellCheckCompleted { get; set; }
|
||||
public string SpellCheckAborted { get; set; }
|
||||
|
@ -456,6 +456,7 @@ namespace Nikse.SubtitleEdit.Logic
|
||||
public string Company { get; set; }
|
||||
public bool MoveVideo100Or500MsPlaySmallSample { get; set; }
|
||||
public bool DisableVideoAutoLoading { get; set; }
|
||||
public int NewEmptyDefaultMs { get; set; }
|
||||
public bool ShowBetaStuff { get; set; }
|
||||
|
||||
public GeneralSettings()
|
||||
@ -534,6 +535,7 @@ namespace Nikse.SubtitleEdit.Logic
|
||||
MoveVideo100Or500MsPlaySmallSample = false;
|
||||
DisableVideoAutoLoading = false;
|
||||
ShowBetaStuff = false;
|
||||
NewEmptyDefaultMs = 2000;
|
||||
}
|
||||
|
||||
}
|
||||
@ -1314,6 +1316,9 @@ namespace Nikse.SubtitleEdit.Logic
|
||||
subNode = node.SelectSingleNode("ShowBetaStuff");
|
||||
if (subNode != null)
|
||||
settings.General.ShowBetaStuff = Convert.ToBoolean(subNode.InnerText.Trim());
|
||||
subNode = node.SelectSingleNode("NewEmptyDefaultMs");
|
||||
if (subNode != null)
|
||||
settings.General.NewEmptyDefaultMs = Convert.ToInt32(subNode.InnerText.Trim());
|
||||
subNode = node.SelectSingleNode("MoveVideo100Or500MsPlaySmallSample");
|
||||
if (subNode != null)
|
||||
settings.General.MoveVideo100Or500MsPlaySmallSample = Convert.ToBoolean(subNode.InnerText.Trim());
|
||||
@ -2373,6 +2378,7 @@ namespace Nikse.SubtitleEdit.Logic
|
||||
textWriter.WriteElementString("MoveVideo100Or500MsPlaySmallSample", settings.General.MoveVideo100Or500MsPlaySmallSample.ToString());
|
||||
textWriter.WriteElementString("DisableVideoAutoLoading", settings.General.DisableVideoAutoLoading.ToString());
|
||||
textWriter.WriteElementString("ShowBetaStuff", settings.General.ShowBetaStuff.ToString());
|
||||
textWriter.WriteElementString("NewEmptyDefaultMs", settings.General.NewEmptyDefaultMs.ToString(CultureInfo.InvariantCulture));
|
||||
|
||||
|
||||
textWriter.WriteEndElement();
|
||||
|
Loading…
Reference in New Issue
Block a user