mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-22 03:02:35 +01:00
SUP editor: Add option 'Select unforced lines' - thx manuelrn :)
Fix #7510
This commit is contained in:
parent
577a626236
commit
74a19bb4d8
@ -489,6 +489,7 @@ We leverage the intrinsic rhythm of the image.</CreateSimpleChainingToolTip>
|
||||
<BottomAlignSelectedLines>Bottom align selected lines (keep horizontal position)</BottomAlignSelectedLines>
|
||||
<ToggleForcedSelectedLines>Toggle "Forced" for selected lines</ToggleForcedSelectedLines>
|
||||
<SelectForcedLines>Select forced lines</SelectForcedLines>
|
||||
<SelectNonForcedLines>Select non-forced lines</SelectNonForcedLines>
|
||||
<SizeXY>Size: {0}x{1}</SizeXY>
|
||||
<SetAspectRatio11>Set aspect ratio 1:1</SetAspectRatio11>
|
||||
<ChangeBrightnessTitle>Adjust brightness</ChangeBrightnessTitle>
|
||||
|
55
src/ui/Forms/BinaryEdit/BinEdit.Designer.cs
generated
55
src/ui/Forms/BinaryEdit/BinEdit.Designer.cs
generated
@ -30,8 +30,8 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.components = new System.ComponentModel.Container();
|
||||
Nikse.SubtitleEdit.Core.Common.TimeCode timeCode1 = new Nikse.SubtitleEdit.Core.Common.TimeCode();
|
||||
Nikse.SubtitleEdit.Core.Common.TimeCode timeCode2 = new Nikse.SubtitleEdit.Core.Common.TimeCode();
|
||||
Nikse.SubtitleEdit.Core.Common.TimeCode timeCode3 = new Nikse.SubtitleEdit.Core.Common.TimeCode();
|
||||
Nikse.SubtitleEdit.Core.Common.TimeCode timeCode4 = new Nikse.SubtitleEdit.Core.Common.TimeCode();
|
||||
this.groupBoxCurrent = new System.Windows.Forms.GroupBox();
|
||||
this.labelSyntaxError = new Nikse.SubtitleEdit.Controls.NikseLabel();
|
||||
this.buttonSetText = new System.Windows.Forms.Button();
|
||||
@ -131,6 +131,7 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
this.columnHeaderDuration = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.columnHeaderText = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.timerSyntaxColor = new System.Windows.Forms.Timer(this.components);
|
||||
this.toolStripMenuItemSelectNonForced = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.groupBoxCurrent.SuspendLayout();
|
||||
this.groupBoxVideoInfo.SuspendLayout();
|
||||
this.contextMenuStripListView.SuspendLayout();
|
||||
@ -350,14 +351,14 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
this.timeUpDownEndTime.Size = new System.Drawing.Size(111, 23);
|
||||
this.timeUpDownEndTime.TabIndex = 3;
|
||||
this.timeUpDownEndTime.TabStop = false;
|
||||
timeCode1.Hours = 0;
|
||||
timeCode1.Milliseconds = 0;
|
||||
timeCode1.Minutes = 0;
|
||||
timeCode1.Seconds = 0;
|
||||
timeCode1.TimeSpan = System.TimeSpan.Parse("00:00:00");
|
||||
timeCode1.TotalMilliseconds = 0D;
|
||||
timeCode1.TotalSeconds = 0D;
|
||||
this.timeUpDownEndTime.TimeCode = timeCode1;
|
||||
timeCode3.Hours = 0;
|
||||
timeCode3.Milliseconds = 0;
|
||||
timeCode3.Minutes = 0;
|
||||
timeCode3.Seconds = 0;
|
||||
timeCode3.TimeSpan = System.TimeSpan.Parse("00:00:00");
|
||||
timeCode3.TotalMilliseconds = 0D;
|
||||
timeCode3.TotalSeconds = 0D;
|
||||
this.timeUpDownEndTime.TimeCode = timeCode3;
|
||||
this.timeUpDownEndTime.UseVideoOffset = false;
|
||||
//
|
||||
// timeUpDownStartTime
|
||||
@ -382,14 +383,14 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
this.timeUpDownStartTime.Size = new System.Drawing.Size(111, 23);
|
||||
this.timeUpDownStartTime.TabIndex = 1;
|
||||
this.timeUpDownStartTime.TabStop = false;
|
||||
timeCode2.Hours = 0;
|
||||
timeCode2.Milliseconds = 0;
|
||||
timeCode2.Minutes = 0;
|
||||
timeCode2.Seconds = 0;
|
||||
timeCode2.TimeSpan = System.TimeSpan.Parse("00:00:00");
|
||||
timeCode2.TotalMilliseconds = 0D;
|
||||
timeCode2.TotalSeconds = 0D;
|
||||
this.timeUpDownStartTime.TimeCode = timeCode2;
|
||||
timeCode4.Hours = 0;
|
||||
timeCode4.Milliseconds = 0;
|
||||
timeCode4.Minutes = 0;
|
||||
timeCode4.Seconds = 0;
|
||||
timeCode4.TimeSpan = System.TimeSpan.Parse("00:00:00");
|
||||
timeCode4.TotalMilliseconds = 0D;
|
||||
timeCode4.TotalSeconds = 0D;
|
||||
this.timeUpDownStartTime.TimeCode = timeCode4;
|
||||
this.timeUpDownStartTime.UseVideoOffset = false;
|
||||
//
|
||||
// label1
|
||||
@ -447,6 +448,7 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
this.comboBoxFrameRate.Size = new System.Drawing.Size(74, 21);
|
||||
this.comboBoxFrameRate.TabIndex = 5;
|
||||
this.comboBoxFrameRate.TabStop = false;
|
||||
this.comboBoxFrameRate.UsePopupWindow = false;
|
||||
this.comboBoxFrameRate.SelectedIndexChanged += new System.EventHandler(this.comboBoxFrameRate_SelectedIndexChanged);
|
||||
this.comboBoxFrameRate.SelectedValueChanged += new System.EventHandler(this.comboBoxFrameRate_SelectedValueChanged);
|
||||
//
|
||||
@ -557,6 +559,7 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
this.bottomAlignSelectedLinesToolStripMenuItem,
|
||||
this.toolStripSeparator9,
|
||||
this.toggleforcedForSelectedLinesToolStripMenuItem,
|
||||
this.toolStripMenuItemSelectNonForced,
|
||||
this.selectOnlyForcedLinesToolStripMenuItem,
|
||||
this.toolStripSeparator7,
|
||||
this.resizeImagesForSelectedLinesToolStripMenuItem,
|
||||
@ -570,7 +573,7 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
this.toolStripSeparatorInsertSub,
|
||||
this.insertSubtitleAfterThisLineToolStripMenuItem});
|
||||
this.contextMenuStripListView.Name = "contextMenuStripListView";
|
||||
this.contextMenuStripListView.Size = new System.Drawing.Size(377, 408);
|
||||
this.contextMenuStripListView.Size = new System.Drawing.Size(377, 452);
|
||||
this.contextMenuStripListView.Opening += new System.ComponentModel.CancelEventHandler(this.contextMenuStripListView_Opening);
|
||||
//
|
||||
// deleteToolStripMenuItem
|
||||
@ -924,21 +927,21 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
// adjustAllTimesToolStripMenuItem
|
||||
//
|
||||
this.adjustAllTimesToolStripMenuItem.Name = "adjustAllTimesToolStripMenuItem";
|
||||
this.adjustAllTimesToolStripMenuItem.Size = new System.Drawing.Size(172, 22);
|
||||
this.adjustAllTimesToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
this.adjustAllTimesToolStripMenuItem.Text = "Adjust all times";
|
||||
this.adjustAllTimesToolStripMenuItem.Click += new System.EventHandler(this.adjustAllTimesToolStripMenuItem_Click);
|
||||
//
|
||||
// changeFrameRateToolStripMenuItem
|
||||
//
|
||||
this.changeFrameRateToolStripMenuItem.Name = "changeFrameRateToolStripMenuItem";
|
||||
this.changeFrameRateToolStripMenuItem.Size = new System.Drawing.Size(172, 22);
|
||||
this.changeFrameRateToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
this.changeFrameRateToolStripMenuItem.Text = "Change frame rate";
|
||||
this.changeFrameRateToolStripMenuItem.Click += new System.EventHandler(this.changeFrameRateToolStripMenuItem_Click);
|
||||
//
|
||||
// changeSpeedToolStripMenuItem
|
||||
//
|
||||
this.changeSpeedToolStripMenuItem.Name = "changeSpeedToolStripMenuItem";
|
||||
this.changeSpeedToolStripMenuItem.Size = new System.Drawing.Size(172, 22);
|
||||
this.changeSpeedToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
this.changeSpeedToolStripMenuItem.Text = "Change speed";
|
||||
this.changeSpeedToolStripMenuItem.Click += new System.EventHandler(this.changeSpeedToolStripMenuItem_Click);
|
||||
//
|
||||
@ -1136,6 +1139,13 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
this.timerSyntaxColor.Interval = 250;
|
||||
this.timerSyntaxColor.Tick += new System.EventHandler(this.timerSyntaxColor_Tick);
|
||||
//
|
||||
// toolStripMenuItemSelectNonForced
|
||||
//
|
||||
this.toolStripMenuItemSelectNonForced.Name = "toolStripMenuItemSelectNonForced";
|
||||
this.toolStripMenuItemSelectNonForced.Size = new System.Drawing.Size(376, 22);
|
||||
this.toolStripMenuItemSelectNonForced.Text = "Select only non-forced lines";
|
||||
this.toolStripMenuItemSelectNonForced.Click += new System.EventHandler(this.toolStripMenuItemSelectNonForced_Click);
|
||||
//
|
||||
// BinEdit
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
@ -1277,5 +1287,6 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
private Nikse.SubtitleEdit.Controls.NikseLabel labelSyntaxError;
|
||||
private System.Windows.Forms.ToolStripSeparator toolStripSeparator11;
|
||||
private System.Windows.Forms.ToolStripMenuItem saveImageAsToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem toolStripMenuItemSelectNonForced;
|
||||
}
|
||||
}
|
@ -325,6 +325,7 @@ namespace Nikse.SubtitleEdit.Forms.BinaryEdit
|
||||
bottomAlignSelectedLinesToolStripMenuItem.Text = LanguageSettings.Current.BinEdit.BottomAlignSelectedLines;
|
||||
toggleforcedForSelectedLinesToolStripMenuItem.Text = LanguageSettings.Current.BinEdit.ToggleForcedSelectedLines;
|
||||
selectOnlyForcedLinesToolStripMenuItem.Text = LanguageSettings.Current.BinEdit.SelectForcedLines;
|
||||
toolStripMenuItemSelectNonForced.Text = LanguageSettings.Current.BinEdit.SelectNonForcedLines;
|
||||
resizeImagesForSelectedLinesToolStripMenuItem.Text = LanguageSettings.Current.BinEdit.ResizeBitmapsForSelectedLines;
|
||||
colorSelectedLinesToolStripMenuItem.Text = LanguageSettings.Current.BinEdit.ChangeColorForSelectedLines;
|
||||
changeBrightnessForSelectedLinesToolStripMenuItem.Text = LanguageSettings.Current.BinEdit.ChangeBrightnessForSelectedLines;
|
||||
@ -2655,6 +2656,7 @@ $DROP=[DROPVALUE]" + Environment.NewLine + Environment.NewLine +
|
||||
insertSubtitleAfterThisLineToolStripMenuItem.Visible = selectedCount == 1 && subtitleListView1.SelectedItems[0].Index == subtitleListView1.Items.Count - 1;
|
||||
|
||||
selectOnlyForcedLinesToolStripMenuItem.Visible = _extra.Any(p => p.IsForced);
|
||||
toolStripMenuItemSelectNonForced.Visible = _extra.Any(p => p.IsForced);
|
||||
|
||||
quickOCRTextsforOverviewOnlyToolStripMenuItem.Visible = File.Exists(_nOcrFileName);
|
||||
}
|
||||
@ -3949,8 +3951,8 @@ $DROP=[DROPVALUE]" + Environment.NewLine + Environment.NewLine +
|
||||
subtitleListView1.SelectedIndexChanged -= subtitleListView1_SelectedIndexChanged;
|
||||
subtitleListView1.SelectedIndices.Clear();
|
||||
System.Collections.IList list = subtitleListView1.Items;
|
||||
bool first = true;
|
||||
for (int i = 0; i < list.Count; i++)
|
||||
var first = true;
|
||||
for (var i = 0; i < list.Count; i++)
|
||||
{
|
||||
var item = (ListViewItem)list[i];
|
||||
if (_extra[i].IsForced)
|
||||
@ -4113,5 +4115,30 @@ $DROP=[DROPVALUE]" + Environment.NewLine + Environment.NewLine +
|
||||
bmp.Dispose();
|
||||
}
|
||||
}
|
||||
|
||||
private void toolStripMenuItemSelectNonForced_Click(object sender, EventArgs e)
|
||||
{
|
||||
subtitleListView1.BeginUpdate();
|
||||
subtitleListView1.SelectedIndexChanged -= subtitleListView1_SelectedIndexChanged;
|
||||
subtitleListView1.SelectedIndices.Clear();
|
||||
System.Collections.IList list = subtitleListView1.Items;
|
||||
var first = true;
|
||||
for (var i = 0; i < list.Count; i++)
|
||||
{
|
||||
var item = (ListViewItem)list[i];
|
||||
if (!_extra[i].IsForced)
|
||||
{
|
||||
item.Selected = true;
|
||||
if (first)
|
||||
{
|
||||
SelectIndexAndEnsureVisible(i);
|
||||
first = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
subtitleListView1.SelectedIndexChanged += subtitleListView1_SelectedIndexChanged;
|
||||
subtitleListView1.EndUpdate();
|
||||
subtitleListView1_SelectedIndexChanged(null, null);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -679,6 +679,7 @@ namespace Nikse.SubtitleEdit.Logic
|
||||
BottomAlignSelectedLines = "Bottom align selected lines (keep horizontal position)",
|
||||
ToggleForcedSelectedLines = "Toggle \"Forced\" for selected lines",
|
||||
SelectForcedLines = "Select forced lines",
|
||||
SelectNonForcedLines = "Select non-forced lines",
|
||||
SizeXY = "Size: {0}x{1}",
|
||||
SetAspectRatio11 = "Set aspect ratio 1:1",
|
||||
ChangeBrightnessTitle = "Adjust brightness",
|
||||
|
@ -1297,6 +1297,9 @@ namespace Nikse.SubtitleEdit.Logic
|
||||
case "BinEdit/SelectForcedLines":
|
||||
language.BinEdit.SelectForcedLines = reader.Value;
|
||||
break;
|
||||
case "BinEdit/SelectNonForcedLines":
|
||||
language.BinEdit.SelectNonForcedLines = reader.Value;
|
||||
break;
|
||||
case "BinEdit/SizeXY":
|
||||
language.BinEdit.SizeXY = reader.Value;
|
||||
break;
|
||||
|
@ -502,6 +502,7 @@
|
||||
public string BottomAlignSelectedLines { get; set; }
|
||||
public string ToggleForcedSelectedLines { get; set; }
|
||||
public string SelectForcedLines { get; set; }
|
||||
public string SelectNonForcedLines { get; set; }
|
||||
public string SizeXY { get; set; }
|
||||
public string SetAspectRatio11 { get; set; }
|
||||
public string ChangeBrightnessTitle { get; set; }
|
||||
|
Loading…
Reference in New Issue
Block a user