mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-22 03:02:35 +01:00
Fix "Merge short lines" in "Batch Conv" to use UI settings - thx maharaj12 :)
Fix #5936
This commit is contained in:
parent
3c41bd034f
commit
a25cbe5843
@ -42,6 +42,7 @@
|
||||
* Do not reapeat colors in color picker - thx SDH Marven
|
||||
* Fix cmd line convert issue with ebu stl headerfile - thx Rumczeis
|
||||
* Fix image export missing error for last two lines - th Antoine
|
||||
* Fix "Merge short lines" in "Batch Conv" to use UI settings - thx maharaj12
|
||||
|
||||
|
||||
3.6.5 (19th March 2022)
|
||||
|
@ -529,7 +529,7 @@ namespace Nikse.SubtitleEdit.Core.Common
|
||||
ApplyMinimumDurationLimit = true;
|
||||
ApplyMaximumDurationLimit = true;
|
||||
MergeShortLinesMaxGap = 250;
|
||||
MergeShortLinesMaxChars = 50;
|
||||
MergeShortLinesMaxChars = 55;
|
||||
MergeShortLinesOnlyContinuous = true;
|
||||
ColumnPasteColumn = "all";
|
||||
ColumnPasteOverwriteMode = "overwrite";
|
||||
|
@ -374,17 +374,18 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
labelMaxCharacters.Text = LanguageSettings.Current.MergedShortLines.MaximumCharacters;
|
||||
labelMaxMillisecondsBetweenLines.Text = LanguageSettings.Current.MergedShortLines.MaximumMillisecondsBetween;
|
||||
checkBoxOnlyContinuationLines.Text = LanguageSettings.Current.MergedShortLines.OnlyMergeContinuationLines;
|
||||
if (Configuration.Settings.General.SubtitleLineMaximumLength > numericUpDownMaxCharacters.Maximum)
|
||||
|
||||
if (Configuration.Settings.Tools.MergeShortLinesMaxChars > numericUpDownMaxCharacters.Maximum)
|
||||
{
|
||||
numericUpDownMaxCharacters.Value = numericUpDownMaxCharacters.Maximum;
|
||||
}
|
||||
else if (Configuration.Settings.General.SubtitleLineMaximumLength < numericUpDownMaxCharacters.Minimum)
|
||||
else if (Configuration.Settings.Tools.MergeShortLinesMaxChars < numericUpDownMaxCharacters.Minimum)
|
||||
{
|
||||
numericUpDownMaxCharacters.Value = numericUpDownMaxCharacters.Minimum;
|
||||
}
|
||||
else
|
||||
{
|
||||
numericUpDownMaxCharacters.Value = Configuration.Settings.General.SubtitleLineMaximumLength;
|
||||
numericUpDownMaxCharacters.Value = Configuration.Settings.Tools.MergeShortLinesMaxChars;
|
||||
}
|
||||
|
||||
if (Configuration.Settings.Tools.MergeShortLinesMaxGap >= numericUpDownMaxMillisecondsBetweenLines.Minimum &&
|
||||
@ -1635,7 +1636,7 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
|
||||
if (IsActionEnabled(CommandLineConverter.BatchAction.MergeShortLines))
|
||||
{
|
||||
var mergedShortLinesSub = MergeShortLinesUtils.MergeShortLinesInSubtitle(sub, Configuration.Settings.Tools.MergeShortLinesMaxGap, Configuration.Settings.General.SubtitleLineMaximumLength, Configuration.Settings.Tools.MergeShortLinesOnlyContinuous);
|
||||
var mergedShortLinesSub = MergeShortLinesUtils.MergeShortLinesInSubtitle(sub, (int)numericUpDownMaxMillisecondsBetweenLines.Value, (int)numericUpDownMaxCharacters.Value, checkBoxOnlyContinuationLines.Checked);
|
||||
if (mergedShortLinesSub.Paragraphs.Count != sub.Paragraphs.Count)
|
||||
{
|
||||
sub.Paragraphs.Clear();
|
||||
|
Loading…
Reference in New Issue
Block a user