Add shortcuts for extending

This commit is contained in:
Martijn van Berkel (Flitskikker) 2020-04-01 00:10:08 +02:00
parent a859083d0f
commit 3096103571
10 changed files with 442 additions and 51 deletions

View File

@ -1184,6 +1184,8 @@ Go to "Options -> Settings -> Tools" to enter your Google translate API ke
<MergeSelectedLinesAsDialog>Merge selected lines as dialog</MergeSelectedLinesAsDialog>
<MergeWithLineBefore>Merge with line before</MergeWithLineBefore>
<MergeWithLineAfter>Merge with line after</MergeWithLineAfter>
<ExtendToLineBefore>Extend to line before</ExtendToLineBefore>
<ExtendToLineAfter>Extend to line after</ExtendToLineAfter>
<RemoveFormatting>Remove formatting</RemoveFormatting>
<RemoveFormattingAll>Remove all formatting</RemoveFormattingAll>
<RemoveFormattingBold>Remove bold</RemoveFormattingBold>
@ -1988,6 +1990,10 @@ can edit in same subtitle file (collaboration)</Information>
<AdjustSetEndAndOffsetTheRest>Set end, offset the rest</AdjustSetEndAndOffsetTheRest>
<AdjustSetEndAndOffsetTheRestAndGoToNext>Set end, offset the rest and go to next</AdjustSetEndAndOffsetTheRestAndGoToNext>
<AdjustExtendCurrentSubtitle>Extend current line to next subtitle or max duration</AdjustExtendCurrentSubtitle>
<AdjustExtendToNextSceneChange>Extend selected lines to next scene change (or next subtitle)</AdjustExtendToNextSceneChange>
<AdjustExtendToPreviousSceneChange>Extend selected lines to previous scene change (or previous subtitle)</AdjustExtendToPreviousSceneChange>
<AdjustExtendToNextSubtitle>Extend selected lines to next subtitle</AdjustExtendToNextSubtitle>
<AdjustExtendToPreviousSubtitle>Extend selected lines to previous subtitle</AdjustExtendToPreviousSubtitle>
<RecalculateDurationOfCurrentSubtitle>Re-calculate duration of current subtitle</RecalculateDurationOfCurrentSubtitle>
<MainCreateStartDownEndUp>Insert new subtitle at key-down, set end time at key-up</MainCreateStartDownEndUp>
<MergeDialog>Merge dialog (insert dashes)</MergeDialog>
@ -2554,6 +2560,8 @@ Keep changes?</KeepChangesMessage>
<SplitAtCursor>Split at cursor</SplitAtCursor>
<MergeWithPrevious>Merge with previous</MergeWithPrevious>
<MergeWithNext>Merge with next</MergeWithNext>
<ExtendToPrevious>Extend to previous</ExtendToPrevious>
<ExtendToNext>Extend to next</ExtendToNext>
<PlaySelection>Play selection</PlaySelection>
<ShowWaveformAndSpectrogram>Show waveform and spectrogram</ShowWaveformAndSpectrogram>
<ShowWaveformOnly>Show waveform only</ShowWaveformOnly>

View File

@ -1698,6 +1698,8 @@ namespace Nikse.SubtitleEdit.Core
MergeSelectedLinesAsDialog = "Merge selected lines as dialog",
MergeWithLineBefore = "Merge with line before",
MergeWithLineAfter = "Merge with line after",
ExtendToLineBefore = "Extend to line before",
ExtendToLineAfter = "Extend to line after",
RemoveFormatting = "Remove formatting",
RemoveFormattingAll = "Remove all formatting",
RemoveFormattingItalic = "Remove italic",
@ -2282,6 +2284,10 @@ can edit in same subtitle file (collaboration)",
AdjustSetEndAndOffsetTheRest = "Set end, offset the rest",
AdjustSetEndAndOffsetTheRestAndGoToNext = "Set end, offset the rest and go to next",
AdjustExtendCurrentSubtitle = "Extend current line to next subtitle or max duration",
AdjustExtendToNextSceneChange = "Extend selected lines to next scene change (or next subtitle)",
AdjustExtendToPreviousSceneChange = "Extend selected lines to previous scene change (or previous subtitle)",
AdjustExtendToNextSubtitle = "Extend selected lines to next subtitle",
AdjustExtendToPreviousSubtitle = "Extend selected lines to previous subtitle",
RecalculateDurationOfCurrentSubtitle = "Re-calculate duration of current subtitle",
MainCreateStartDownEndUp = "Insert new subtitle at key-down, set end time at key-up",
MergeDialog = "Merge dialog (insert dashes)",
@ -2903,6 +2909,8 @@ Keep changes?",
SplitAtCursor = "Split at cursor",
MergeWithPrevious = "Merge with previous",
MergeWithNext = "Merge with next",
ExtendToPrevious = "Extend to previous",
ExtendToNext = "Extend to next",
PlaySelection = "Play selection",
ShowWaveformAndSpectrogram = "Show waveform and spectrogram",
ShowWaveformOnly = "Show waveform only",

View File

@ -3937,6 +3937,12 @@ namespace Nikse.SubtitleEdit.Core
case "Main/Menu/ContextMenu/MergeWithLineAfter":
language.Main.Menu.ContextMenu.MergeWithLineAfter = reader.Value;
break;
case "Main/Menu/ContextMenu/ExtendToLineBefore":
language.Main.Menu.ContextMenu.ExtendToLineBefore = reader.Value;
break;
case "Main/Menu/ContextMenu/ExtendToLineAfter":
language.Main.Menu.ContextMenu.ExtendToLineAfter = reader.Value;
break;
case "Main/Menu/ContextMenu/RemoveFormatting":
language.Main.Menu.ContextMenu.RemoveFormatting = reader.Value;
break;
@ -5386,6 +5392,18 @@ namespace Nikse.SubtitleEdit.Core
case "Settings/AdjustExtendCurrentSubtitle":
language.Settings.AdjustExtendCurrentSubtitle = reader.Value;
break;
case "Settings/AdjustExtendToNextSceneChange":
language.Settings.AdjustExtendToNextSceneChange = reader.Value;
break;
case "Settings/AdjustExtendToPreviousSceneChange":
language.Settings.AdjustExtendToPreviousSceneChange = reader.Value;
break;
case "Settings/AdjustExtendToNextSubtitle":
language.Settings.AdjustExtendToNextSubtitle = reader.Value;
break;
case "Settings/AdjustExtendToPreviousSubtitle":
language.Settings.AdjustExtendToPreviousSubtitle = reader.Value;
break;
case "Settings/RecalculateDurationOfCurrentSubtitle":
language.Settings.RecalculateDurationOfCurrentSubtitle = reader.Value;
break;
@ -6904,6 +6922,12 @@ namespace Nikse.SubtitleEdit.Core
case "Waveform/MergeWithNext":
language.Waveform.MergeWithNext = reader.Value;
break;
case "Waveform/ExtendToPrevious":
language.Waveform.ExtendToPrevious = reader.Value;
break;
case "Waveform/ExtendToNext":
language.Waveform.ExtendToNext = reader.Value;
break;
case "Waveform/PlaySelection":
language.Waveform.PlaySelection = reader.Value;
break;

View File

@ -1551,6 +1551,8 @@
public string MergeSelectedLinesAsDialog { get; set; }
public string MergeWithLineBefore { get; set; }
public string MergeWithLineAfter { get; set; }
public string ExtendToLineBefore { get; set; }
public string ExtendToLineAfter { get; set; }
public string RemoveFormatting { get; set; }
public string RemoveFormattingAll { get; set; }
public string RemoveFormattingBold { get; set; }
@ -2153,6 +2155,10 @@
public string AdjustSetEndAndOffsetTheRest { get; set; }
public string AdjustSetEndAndOffsetTheRestAndGoToNext { get; set; }
public string AdjustExtendCurrentSubtitle { get; set; }
public string AdjustExtendToNextSceneChange { get; set; }
public string AdjustExtendToPreviousSceneChange { get; set; }
public string AdjustExtendToNextSubtitle { get; set; }
public string AdjustExtendToPreviousSubtitle { get; set; }
public string RecalculateDurationOfCurrentSubtitle { get; set; }
public string MainCreateStartDownEndUp { get; set; }
public string MergeDialog { get; set; }
@ -2770,6 +2776,8 @@
public string SplitAtCursor { get; set; }
public string MergeWithPrevious { get; set; }
public string MergeWithNext { get; set; }
public string ExtendToPrevious { get; set; }
public string ExtendToNext { get; set; }
public string PlaySelection { get; set; }
public string ShowWaveformAndSpectrogram { get; set; }
public string ShowWaveformOnly { get; set; }

View File

@ -1555,6 +1555,10 @@ $HorzAlign = Center
public string MainAdjustStartXMsForward { get; set; }
public string MainAdjustEndXMsBack { get; set; }
public string MainAdjustEndXMsForward { get; set; }
public string MainAdjustExtendToNextSceneChange { get; set; }
public string MainAdjustExtendToPreviousSceneChange { get; set; }
public string MainAdjustExtendToNextSubtitle { get; set; }
public string MainAdjustExtendToPreviousSubtitle { get; set; }
public string MainInsertAfter { get; set; }
public string MainTextBoxAutoBreak { get; set; }
public string MainTextBoxBreakAtPosition { get; set; }
@ -1698,6 +1702,10 @@ $HorzAlign = Center
WaveformSearchSilenceForward = string.Empty;
WaveformSearchSilenceBack = string.Empty;
WaveformAddTextHere = "Return";
MainAdjustExtendToNextSceneChange = string.Empty;
MainAdjustExtendToPreviousSceneChange = string.Empty;
MainAdjustExtendToNextSubtitle = "Control+Shift+E";
MainAdjustExtendToPreviousSubtitle = "Alt+Shift+E";
}
}
@ -6125,6 +6133,30 @@ $HorzAlign = Center
settings.Shortcuts.MainAdjustEndXMsForward = subNode.InnerText;
}
subNode = node.SelectSingleNode("MainAdjustExtendToNextSceneChange");
if (subNode != null)
{
settings.Shortcuts.MainAdjustExtendToNextSceneChange = subNode.InnerText;
}
subNode = node.SelectSingleNode("MainAdjustExtendToPreviousSceneChange");
if (subNode != null)
{
settings.Shortcuts.MainAdjustExtendToPreviousSceneChange = subNode.InnerText;
}
subNode = node.SelectSingleNode("MainAdjustExtendToNextSubtitle");
if (subNode != null)
{
settings.Shortcuts.MainAdjustExtendToNextSubtitle = subNode.InnerText;
}
subNode = node.SelectSingleNode("MainAdjustExtendToPreviousSubtitle");
if (subNode != null)
{
settings.Shortcuts.MainAdjustExtendToPreviousSubtitle = subNode.InnerText;
}
subNode = node.SelectSingleNode("MainInsertAfter");
if (subNode != null)
{
@ -7279,6 +7311,10 @@ $HorzAlign = Center
textWriter.WriteElementString("MainAdjustStartXMsForward", settings.Shortcuts.MainAdjustStartXMsForward);
textWriter.WriteElementString("MainAdjustEndXMsBack", settings.Shortcuts.MainAdjustEndXMsBack);
textWriter.WriteElementString("MainAdjustEndXMsForward", settings.Shortcuts.MainAdjustEndXMsForward);
textWriter.WriteElementString("MainAdjustExtendToNextSceneChange", settings.Shortcuts.MainAdjustExtendToNextSceneChange);
textWriter.WriteElementString("MainAdjustExtendToPreviousSceneChange", settings.Shortcuts.MainAdjustExtendToPreviousSceneChange);
textWriter.WriteElementString("MainAdjustExtendToNextSubtitle", settings.Shortcuts.MainAdjustExtendToNextSubtitle);
textWriter.WriteElementString("MainAdjustExtendToPreviousSubtitle", settings.Shortcuts.MainAdjustExtendToPreviousSubtitle);
textWriter.WriteElementString("MainInsertAfter", settings.Shortcuts.MainInsertAfter);
textWriter.WriteElementString("MainTextBoxAutoBreak", settings.Shortcuts.MainTextBoxAutoBreak);
textWriter.WriteElementString("MainTextBoxBreakAtPosition", settings.Shortcuts.MainTextBoxBreakAtPosition);

View File

@ -431,6 +431,8 @@
this.SubtitleListview1 = new Nikse.SubtitleEdit.Controls.SubtitleListView();
this.imageListBookmarks = new System.Windows.Forms.ImageList(this.components);
this.groupBoxEdit = new System.Windows.Forms.GroupBox();
this.labelAlternateSingleLinePixels = new System.Windows.Forms.Label();
this.labelSingleLinePixels = new System.Windows.Forms.Label();
this.panelBookmark = new System.Windows.Forms.Panel();
this.labelBookmark = new System.Windows.Forms.Label();
this.pictureBoxBookmark = new System.Windows.Forms.PictureBox();
@ -509,8 +511,12 @@
this.imageListPlayRate = new System.Windows.Forms.ImageList(this.components);
this.timerTextUndo = new System.Windows.Forms.Timer(this.components);
this.timerAlternateTextUndo = new System.Windows.Forms.Timer(this.components);
this.labelSingleLinePixels = new System.Windows.Forms.Label();
this.labelAlternateSingleLinePixels = new System.Windows.Forms.Label();
this.toolStripSeparator4 = new System.Windows.Forms.ToolStripSeparator();
this.extendAfterToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.extendBeforeToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.toolStripSeparator6 = new System.Windows.Forms.ToolStripSeparator();
this.extendToNextToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.extendToPreviousToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.statusStrip1.SuspendLayout();
this.toolStrip1.SuspendLayout();
this.menuStrip1.SuspendLayout();
@ -2410,6 +2416,9 @@
this.toolStripMenuItemMergeDialog,
this.mergeBeforeToolStripMenuItem,
this.mergeAfterToolStripMenuItem,
this.toolStripSeparator4,
this.extendBeforeToolStripMenuItem,
this.extendAfterToolStripMenuItem,
this.toolStripSeparator8,
this.removeFormattinglToolStripMenuItem,
this.boldToolStripMenuItem,
@ -2436,7 +2445,7 @@
this.changeCasingForSelectedLinesToolStripMenuItem,
this.toolStripMenuItemSaveSelectedLines});
this.contextMenuStripListview.Name = "contextMenuStripListview";
this.contextMenuStripListview.Size = new System.Drawing.Size(285, 892);
this.contextMenuStripListview.Size = new System.Drawing.Size(285, 964);
this.contextMenuStripListview.Closed += new System.Windows.Forms.ToolStripDropDownClosedEventHandler(this.MenuClosed);
this.contextMenuStripListview.Opening += new System.ComponentModel.CancelEventHandler(this.ContextMenuStripListviewOpening);
this.contextMenuStripListview.Opened += new System.EventHandler(this.MenuOpened);
@ -3888,6 +3897,9 @@
this.mergeWithPreviousToolStripMenuItem,
this.mergeWithNextToolStripMenuItem,
this.toolStripSeparator11,
this.extendToPreviousToolStripMenuItem,
this.extendToNextToolStripMenuItem,
this.toolStripSeparator6,
this.toolStripMenuItemWaveformPlaySelection,
this.toolStripSeparator24,
this.showWaveformAndSpectrogramToolStripMenuItem,
@ -3900,7 +3912,7 @@
this.seekSilenceToolStripMenuItem,
this.insertSubtitleHereToolStripMenuItem});
this.contextMenuStripWaveform.Name = "contextMenuStripWaveform";
this.contextMenuStripWaveform.Size = new System.Drawing.Size(275, 396);
this.contextMenuStripWaveform.Size = new System.Drawing.Size(275, 446);
this.contextMenuStripWaveform.Closing += new System.Windows.Forms.ToolStripDropDownClosingEventHandler(this.contextMenuStripWaveform_Closing);
this.contextMenuStripWaveform.Opening += new System.ComponentModel.CancelEventHandler(this.ContextMenuStripWaveformOpening);
//
@ -4197,6 +4209,26 @@
this.groupBoxEdit.TabIndex = 1;
this.groupBoxEdit.TabStop = false;
//
// labelAlternateSingleLinePixels
//
this.labelAlternateSingleLinePixels.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.labelAlternateSingleLinePixels.AutoSize = true;
this.labelAlternateSingleLinePixels.Location = new System.Drawing.Point(870, 94);
this.labelAlternateSingleLinePixels.Name = "labelAlternateSingleLinePixels";
this.labelAlternateSingleLinePixels.Size = new System.Drawing.Size(62, 13);
this.labelAlternateSingleLinePixels.TabIndex = 43;
this.labelAlternateSingleLinePixels.Text = "AltSinLinPix";
//
// labelSingleLinePixels
//
this.labelSingleLinePixels.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.labelSingleLinePixels.AutoSize = true;
this.labelSingleLinePixels.Location = new System.Drawing.Point(427, 94);
this.labelSingleLinePixels.Name = "labelSingleLinePixels";
this.labelSingleLinePixels.Size = new System.Drawing.Size(105, 13);
this.labelSingleLinePixels.TabIndex = 42;
this.labelSingleLinePixels.Text = "labelSingleLinePixels";
//
// panelBookmark
//
this.panelBookmark.BackColor = System.Drawing.Color.LemonChiffon;
@ -4952,25 +4984,43 @@
this.timerAlternateTextUndo.Interval = 700;
this.timerAlternateTextUndo.Tick += new System.EventHandler(this.TimerAlternateTextUndoTick);
//
// labelSingleLinePixels
// toolStripSeparator4
//
this.labelSingleLinePixels.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.labelSingleLinePixels.AutoSize = true;
this.labelSingleLinePixels.Location = new System.Drawing.Point(427, 94);
this.labelSingleLinePixels.Name = "labelSingleLinePixels";
this.labelSingleLinePixels.Size = new System.Drawing.Size(105, 13);
this.labelSingleLinePixels.TabIndex = 42;
this.labelSingleLinePixels.Text = "labelSingleLinePixels";
this.toolStripSeparator4.Name = "toolStripSeparator4";
this.toolStripSeparator4.Size = new System.Drawing.Size(281, 6);
//
// labelAlternateSingleLinePixels
// extendAfterToolStripMenuItem
//
this.labelAlternateSingleLinePixels.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.labelAlternateSingleLinePixels.AutoSize = true;
this.labelAlternateSingleLinePixels.Location = new System.Drawing.Point(870, 94);
this.labelAlternateSingleLinePixels.Name = "labelAlternateSingleLinePixels";
this.labelAlternateSingleLinePixels.Size = new System.Drawing.Size(62, 13);
this.labelAlternateSingleLinePixels.TabIndex = 43;
this.labelAlternateSingleLinePixels.Text = "AltSinLinPix";
this.extendAfterToolStripMenuItem.Name = "extendAfterToolStripMenuItem";
this.extendAfterToolStripMenuItem.Size = new System.Drawing.Size(284, 22);
this.extendAfterToolStripMenuItem.Text = "Extend to line after";
this.extendAfterToolStripMenuItem.Click += new System.EventHandler(this.ExtendAfterToolStripMenuItemClick);
//
// extendBeforeToolStripMenuItem
//
this.extendBeforeToolStripMenuItem.Name = "extendBeforeToolStripMenuItem";
this.extendBeforeToolStripMenuItem.Size = new System.Drawing.Size(284, 22);
this.extendBeforeToolStripMenuItem.Text = "Extend to line before";
this.extendBeforeToolStripMenuItem.Click += new System.EventHandler(this.ExtendBeforeToolStripMenuItemClick);
//
// toolStripSeparator6
//
this.toolStripSeparator6.Name = "toolStripSeparator6";
this.toolStripSeparator6.Size = new System.Drawing.Size(271, 6);
//
// extendToNextToolStripMenuItem
//
this.extendToNextToolStripMenuItem.Name = "extendToNextToolStripMenuItem";
this.extendToNextToolStripMenuItem.Size = new System.Drawing.Size(274, 22);
this.extendToNextToolStripMenuItem.Text = "Extend to next";
this.extendToNextToolStripMenuItem.Click += new System.EventHandler(this.extendToNextToolStripMenuItem_Click);
//
// extendToPreviousToolStripMenuItem
//
this.extendToPreviousToolStripMenuItem.Name = "extendToPreviousToolStripMenuItem";
this.extendToPreviousToolStripMenuItem.Size = new System.Drawing.Size(274, 22);
this.extendToPreviousToolStripMenuItem.Text = "Extend to previous";
this.extendToPreviousToolStripMenuItem.Click += new System.EventHandler(this.extendToPreviousToolStripMenuItem_Click);
//
// Main
//
@ -5527,5 +5577,11 @@
private System.Windows.Forms.ToolStripMenuItem toolStripMenuItemRuby;
private System.Windows.Forms.Label labelSingleLinePixels;
private System.Windows.Forms.Label labelAlternateSingleLinePixels;
private System.Windows.Forms.ToolStripSeparator toolStripSeparator4;
private System.Windows.Forms.ToolStripMenuItem extendBeforeToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem extendAfterToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem extendToPreviousToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem extendToNextToolStripMenuItem;
private System.Windows.Forms.ToolStripSeparator toolStripSeparator6;
}
}

View File

@ -776,6 +776,9 @@ namespace Nikse.SubtitleEdit.Forms
mergeWithPreviousToolStripMenuItem.Visible = false;
mergeWithNextToolStripMenuItem.Visible = false;
toolStripSeparator11.Visible = false;
extendToPreviousToolStripMenuItem.Visible = false;
extendToNextToolStripMenuItem.Visible = false;
toolStripSeparator6.Visible = false;
toolStripMenuItemWaveformPlaySelection.Visible = false;
toolStripSeparator24.Visible = false;
if (audioVisualizer.GetSceneChangeIndex(e.Seconds) >= 0)
@ -904,6 +907,9 @@ namespace Nikse.SubtitleEdit.Forms
mergeWithPreviousToolStripMenuItem.Visible = true;
mergeWithNextToolStripMenuItem.Visible = true;
toolStripSeparator11.Visible = true;
extendToPreviousToolStripMenuItem.Visible = true;
extendToNextToolStripMenuItem.Visible = true;
toolStripSeparator6.Visible = true;
toolStripMenuItemWaveformPlaySelection.Visible = true;
toolStripSeparator24.Visible = true;
if (audioVisualizer.GetSceneChangeIndex(e.Seconds) >= 0)
@ -975,6 +981,9 @@ namespace Nikse.SubtitleEdit.Forms
splitToolStripMenuItem1.Visible = false;
mergeWithPreviousToolStripMenuItem.Visible = false;
mergeWithNextToolStripMenuItem.Visible = false;
extendToPreviousToolStripMenuItem.Visible = false;
extendToNextToolStripMenuItem.Visible = false;
toolStripSeparator6.Visible = false;
contextMenuStripWaveform.Show(MousePosition.X, MousePosition.Y);
}
@ -1538,6 +1547,8 @@ namespace Nikse.SubtitleEdit.Forms
toolStripMenuItemMergeDialog.Text = _language.Menu.ContextMenu.MergeSelectedLinesAsDialog;
mergeBeforeToolStripMenuItem.Text = _language.Menu.ContextMenu.MergeWithLineBefore;
mergeAfterToolStripMenuItem.Text = _language.Menu.ContextMenu.MergeWithLineAfter;
extendBeforeToolStripMenuItem.Text = _language.Menu.ContextMenu.ExtendToLineBefore;
extendAfterToolStripMenuItem.Text = _language.Menu.ContextMenu.ExtendToLineAfter;
removeFormattinglToolStripMenuItem.Text = _language.Menu.ContextMenu.RemoveFormatting;
removeAllFormattingsToolStripMenuItem.Text = _language.Menu.ContextMenu.RemoveFormattingAll;
removeBoldToolStripMenuItem.Text = _language.Menu.ContextMenu.RemoveFormattingBold;
@ -1674,6 +1685,8 @@ namespace Nikse.SubtitleEdit.Forms
splitToolStripMenuItem1.Text = languageWaveform.Split;
mergeWithPreviousToolStripMenuItem.Text = languageWaveform.MergeWithPrevious;
mergeWithNextToolStripMenuItem.Text = languageWaveform.MergeWithNext;
extendToPreviousToolStripMenuItem.Text = languageWaveform.ExtendToPrevious;
extendToNextToolStripMenuItem.Text = languageWaveform.ExtendToNext;
toolStripMenuItemWaveformPlaySelection.Text = languageWaveform.PlaySelection;
showWaveformAndSpectrogramToolStripMenuItem.Text = languageWaveform.ShowWaveformAndSpectrogram;
showOnlyWaveformToolStripMenuItem.Text = languageWaveform.ShowWaveformOnly;
@ -10263,6 +10276,16 @@ namespace Nikse.SubtitleEdit.Forms
}
}
private void ExtendBeforeToolStripMenuItemClick(object sender, EventArgs e)
{
}
private void ExtendAfterToolStripMenuItemClick(object sender, EventArgs e)
{
}
private static string ChangeAllLinesTagsToSingleTag(string text, string tag)
{
if (!text.Contains("<" + tag + ">"))
@ -14423,6 +14446,26 @@ namespace Nikse.SubtitleEdit.Forms
FindPrevious();
e.SuppressKeyPress = true;
}
else if (_shortcuts.MainAdjustExtendToNextSubtitle == e.KeyData)
{
ExtendSelectedLinesToNextLine();
e.SuppressKeyPress = true;
}
else if (_shortcuts.MainAdjustExtendToPreviousSubtitle == e.KeyData)
{
ExtendSelectedLinesToPreviousLine();
e.SuppressKeyPress = true;
}
else if (_shortcuts.MainAdjustExtendToNextSceneChange == e.KeyData)
{
ExtendSelectedLinesToNextSceneChange();
e.SuppressKeyPress = true;
}
else if (_shortcuts.MainAdjustExtendToPreviousSceneChange == e.KeyData)
{
ExtendSelectedLinesToPreviousSceneChange();
e.SuppressKeyPress = true;
}
//TABS: Create / adjust / translate
@ -14634,6 +14677,178 @@ namespace Nikse.SubtitleEdit.Forms
// put new entries above tabs
}
private void ExtendSelectedLinesToNextLine()
{
var historyAdded = false;
foreach (ListViewItem selectedItem in SubtitleListview1.SelectedItems)
{
var idx = selectedItem.Index;
var p = _subtitle.Paragraphs[idx];
var next = _subtitle.GetParagraphOrDefault(idx + 1);
if (next != null)
{
if (!historyAdded)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendToNextSubtitle));
historyAdded = true;
}
p.EndTime.TotalMilliseconds = next.StartTime.TotalMilliseconds - Configuration.Settings.General.MinimumMillisecondsBetweenLines;
}
if (_subtitleAlternate != null && Configuration.Settings.General.AllowEditOfOriginalSubtitle)
{
var original = Utilities.GetOriginalParagraph(idx, p, _subtitleAlternate.Paragraphs);
if (original != null)
{
var originalNext = _subtitleAlternate.GetParagraphOrDefault(_subtitleAlternate.GetIndex(original) + 1);
if (originalNext != null)
{
if (!historyAdded)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendToNextSubtitle));
historyAdded = true;
}
original.EndTime.TotalMilliseconds = originalNext.StartTime.TotalMilliseconds - Configuration.Settings.General.MinimumMillisecondsBetweenLines;
}
}
}
RefreshSelectedParagraph();
}
}
private void ExtendSelectedLinesToPreviousLine()
{
var historyAdded = false;
foreach (ListViewItem selectedItem in SubtitleListview1.SelectedItems)
{
var idx = selectedItem.Index;
var p = _subtitle.Paragraphs[idx];
var previous = _subtitle.GetParagraphOrDefault(idx - 1);
if (previous != null)
{
if (!historyAdded)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendToPreviousSubtitle));
historyAdded = true;
}
p.StartTime.TotalMilliseconds = previous.EndTime.TotalMilliseconds + Configuration.Settings.General.MinimumMillisecondsBetweenLines;
}
if (_subtitleAlternate != null)
{
var original = Utilities.GetOriginalParagraph(idx, p, _subtitleAlternate.Paragraphs);
if (original != null)
{
var originalPrevious = _subtitleAlternate.GetParagraphOrDefault(_subtitleAlternate.GetIndex(original) - 1);
if (originalPrevious != null)
{
if (!historyAdded)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendToPreviousSubtitle));
historyAdded = true;
}
original.StartTime.TotalMilliseconds = originalPrevious.EndTime.TotalMilliseconds + Configuration.Settings.General.MinimumMillisecondsBetweenLines;
}
}
}
RefreshSelectedParagraph();
}
}
private void ExtendSelectedLinesToNextSceneChange()
{
var historyAdded = false;
foreach (ListViewItem selectedItem in SubtitleListview1.SelectedItems)
{
var idx = selectedItem.Index;
var p = _subtitle.Paragraphs[idx];
List<double> nextSceneChanges = audioVisualizer.SceneChanges.Count > 0 ? audioVisualizer.SceneChanges.Where(x => x > p.EndTime.TotalSeconds + 0.01).ToList() : new List<double>();
if (nextSceneChanges.Count > 0)
{
var next = _subtitle.GetParagraphOrDefault(idx + 1);
double nearestSceneChange = nextSceneChanges.Aggregate((x, y) => Math.Abs(x - p.EndTime.TotalSeconds) < Math.Abs(y - p.EndTime.TotalSeconds) ? x : y);
double nearestStartTimeWithGap = next != null ? next.StartTime.TotalMilliseconds - Configuration.Settings.General.MinimumMillisecondsBetweenLines : Double.MaxValue;
if (!historyAdded)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendToNextSceneChange));
historyAdded = true;
}
p.EndTime.TotalMilliseconds = Math.Min(nearestSceneChange * 1000, nearestStartTimeWithGap);
if (_subtitleAlternate != null && Configuration.Settings.General.AllowEditOfOriginalSubtitle)
{
var original = Utilities.GetOriginalParagraph(idx, p, _subtitleAlternate.Paragraphs);
if (original != null)
{
var originalNext = _subtitleAlternate.GetParagraphOrDefault(_subtitleAlternate.GetIndex(original) + 1);
double nearestOriginalStartTimeWithGap = originalNext != null ? originalNext.StartTime.TotalMilliseconds - Configuration.Settings.General.MinimumMillisecondsBetweenLines : Double.MaxValue;
if (!historyAdded)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendToNextSceneChange));
historyAdded = true;
}
original.EndTime.TotalMilliseconds = Math.Min(nearestSceneChange * 1000, nearestOriginalStartTimeWithGap);
}
}
}
RefreshSelectedParagraph();
}
}
private void ExtendSelectedLinesToPreviousSceneChange()
{
var historyAdded = false;
foreach (ListViewItem selectedItem in SubtitleListview1.SelectedItems)
{
var idx = selectedItem.Index;
var p = _subtitle.Paragraphs[idx];
List<double> previousSceneChanges = audioVisualizer.SceneChanges.Count > 0 ? audioVisualizer.SceneChanges.Where(x => x < p.StartTime.TotalSeconds - 0.01).ToList() : new List<double>();
if (previousSceneChanges.Count > 0)
{
var previous = _subtitle.GetParagraphOrDefault(idx - 1);
double nearestSceneChange = previousSceneChanges.Aggregate((x, y) => Math.Abs(x - p.StartTime.TotalSeconds) < Math.Abs(y - p.StartTime.TotalSeconds) ? x : y);
double nearestEndTimeWithGap = previous != null ? previous.EndTime.TotalMilliseconds + Configuration.Settings.General.MinimumMillisecondsBetweenLines : -9999;
if (!historyAdded)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendToPreviousSceneChange));
historyAdded = true;
}
p.StartTime.TotalMilliseconds = Math.Max(nearestSceneChange * 1000, nearestEndTimeWithGap);
if (_subtitleAlternate != null && Configuration.Settings.General.AllowEditOfOriginalSubtitle)
{
var original = Utilities.GetOriginalParagraph(idx, p, _subtitleAlternate.Paragraphs);
if (original != null)
{
var originalPrevious = _subtitleAlternate.GetParagraphOrDefault(_subtitleAlternate.GetIndex(original) - 1);
double nearestOriginalEndTimeWithGap = originalPrevious != null ? originalPrevious.EndTime.TotalMilliseconds + Configuration.Settings.General.MinimumMillisecondsBetweenLines : -9999;
if (!historyAdded)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendToPreviousSceneChange));
historyAdded = true;
}
original.StartTime.TotalMilliseconds = Math.Max(nearestSceneChange * 1000, nearestOriginalEndTimeWithGap);
}
}
}
RefreshSelectedParagraph();
}
}
private void AutoGuessStartTime(int index)
{
var p = _subtitle.GetParagraphOrDefault(index);
@ -20476,6 +20691,30 @@ namespace Nikse.SubtitleEdit.Forms
audioVisualizer.Invalidate();
}
private void extendToPreviousToolStripMenuItem_Click(object sender, EventArgs e)
{
int index = _subtitle.GetIndex(audioVisualizer.RightClickedParagraph);
if (index >= 0)
{
SubtitleListview1.SelectIndexAndEnsureVisible(index, true);
ExtendSelectedLinesToPreviousLine();
}
audioVisualizer.Invalidate();
}
private void extendToNextToolStripMenuItem_Click(object sender, EventArgs e)
{
int index = _subtitle.GetIndex(audioVisualizer.RightClickedParagraph);
if (index >= 0)
{
SubtitleListview1.SelectIndexAndEnsureVisible(index, true);
ExtendSelectedLinesToNextLine();
}
audioVisualizer.Invalidate();
}
private void buttonWaveformZoomIn_Click(object sender, EventArgs e)
{
if (audioVisualizer.WavePeaks != null && audioVisualizer.Visible)

View File

@ -338,36 +338,36 @@
<data name="toolStripButtonFixCommonErrors.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAavSURBVFhHvVfrT1NZEDf+D5s06f/QpInf3JVdeakovuMD
5VUQ8YXGxxrM6oIoUXYTPoBudhHxgcqbllJLW2grpVpKb7nQQltEarnsjYp+Ub+YnMzOHFoQBaGG7CQ3
TXvPOb/fzG9mznRVzC5durS6sbFRUVxcrLx9+7aCvkdffZcBwGqfz6dwOr1Kp9OpdLlcCvot+nq+EVhd
XZ2qtvaucO7cOenmzb+E6upq1feQIJCJiQmF3x9SDw0NCW63W7LbXZJbGHS7XD5FdNmcEUhlZbWqvLxc
LC0tY/n5BVBQcJhVVPwhVlZWxkWCwCcnJ1Xj4bAQDAZlj8fLhn0jYLVa2ejoqOBDYtGlc1ZVVaW4du1P
ISEhgZWUlMGFC79BdnYu5OUdYuXl8ZGYmHiliESmBJ/PzyIRCUZGgxzc7/eLgcC4akEJCgp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, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
@ -705,7 +705,7 @@
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAD2
CAAAAk1TRnQBSQFMAgEBAgEAATgBJwE4AScBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
CAAAAk1TRnQBSQFMAgEBAgEAAVABJwFQAScBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
AwABQAMAARADAAEBAQABCAYAAQQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA

View File

@ -1268,6 +1268,10 @@ namespace Nikse.SubtitleEdit.Forms
AddNode(createAndAdjustNode, string.Format(language.AdjustEndXMsBack, Configuration.Settings.Tools.MoveStartEndMs), nameof(Configuration.Settings.Shortcuts.MainAdjustEndXMsBack));
AddNode(createAndAdjustNode, string.Format(language.AdjustEndXMsForward, Configuration.Settings.Tools.MoveStartEndMs), nameof(Configuration.Settings.Shortcuts.MainAdjustEndXMsForward));
AddNode(createAndAdjustNode, language.RecalculateDurationOfCurrentSubtitle, nameof(Configuration.Settings.Shortcuts.GeneralAutoCalcCurrentDuration));
AddNode(createAndAdjustNode, language.AdjustExtendToNextSceneChange, nameof(Configuration.Settings.Shortcuts.MainAdjustExtendToNextSceneChange));
AddNode(createAndAdjustNode, language.AdjustExtendToPreviousSceneChange, nameof(Configuration.Settings.Shortcuts.MainAdjustExtendToPreviousSceneChange));
AddNode(createAndAdjustNode, language.AdjustExtendToNextSubtitle, nameof(Configuration.Settings.Shortcuts.MainAdjustExtendToNextSubtitle));
AddNode(createAndAdjustNode, language.AdjustExtendToPreviousSubtitle, nameof(Configuration.Settings.Shortcuts.MainAdjustExtendToPreviousSubtitle));
if (createAndAdjustNode.Nodes.Count > 0)
{
_shortcuts.Nodes.Add(createAndAdjustNode);

View File

@ -97,6 +97,10 @@ namespace Nikse.SubtitleEdit.Logic
public Keys MainAdjustAdjustStartXMsForward { get; set; }
public Keys MainAdjustAdjustEndXMsBack { get; set; }
public Keys MainAdjustAdjustEndXMsForward { get; set; }
public Keys MainAdjustExtendToNextSceneChange { get; set; }
public Keys MainAdjustExtendToPreviousSceneChange { get; set; }
public Keys MainAdjustExtendToNextSubtitle { get; set; }
public Keys MainAdjustExtendToPreviousSubtitle { get; set; }
public Keys MainInsertAfter { get; set; }
public Keys MainInsertBefore { get; set; }
public Keys MainTextBoxAutoBreak { get; set; }
@ -258,6 +262,10 @@ namespace Nikse.SubtitleEdit.Logic
MainAdjustAdjustStartXMsForward = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainAdjustStartXMsForward);
MainAdjustAdjustEndXMsBack = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainAdjustEndXMsBack);
MainAdjustAdjustEndXMsForward = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainAdjustEndXMsForward);
MainAdjustExtendToNextSceneChange = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainAdjustExtendToNextSceneChange);
MainAdjustExtendToPreviousSceneChange = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainAdjustExtendToPreviousSceneChange);
MainAdjustExtendToNextSubtitle = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainAdjustExtendToNextSubtitle);
MainAdjustExtendToPreviousSubtitle = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainAdjustExtendToPreviousSubtitle);
MainInsertAfter = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainInsertAfter);
MainInsertBefore = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainInsertBefore);
MainTextBoxAutoBreak = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainTextBoxAutoBreak);