mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-23 11:42:36 +01:00
More work on new format
This commit is contained in:
parent
c383604474
commit
c3be5fe291
68
src/Forms/Main.Designer.cs
generated
68
src/Forms/Main.Designer.cs
generated
@ -38,9 +38,9 @@
|
||||
{
|
||||
this.components = new System.ComponentModel.Container();
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Main));
|
||||
Nikse.SubtitleEdit.Core.TimeCode timeCode3 = new Nikse.SubtitleEdit.Core.TimeCode();
|
||||
Nikse.SubtitleEdit.Core.TimeCode timeCode1 = new Nikse.SubtitleEdit.Core.TimeCode();
|
||||
Nikse.SubtitleEdit.Core.TimeCode timeCode2 = new Nikse.SubtitleEdit.Core.TimeCode();
|
||||
Nikse.SubtitleEdit.Core.TimeCode timeCode7 = new Nikse.SubtitleEdit.Core.TimeCode();
|
||||
Nikse.SubtitleEdit.Core.TimeCode timeCode8 = new Nikse.SubtitleEdit.Core.TimeCode();
|
||||
Nikse.SubtitleEdit.Core.TimeCode timeCode9 = new Nikse.SubtitleEdit.Core.TimeCode();
|
||||
this.statusStrip1 = new System.Windows.Forms.StatusStrip();
|
||||
this.labelStatus = new System.Windows.Forms.ToolStripStatusLabel();
|
||||
this.toolStripSelected = new System.Windows.Forms.ToolStripStatusLabel();
|
||||
@ -508,6 +508,7 @@
|
||||
this.audioVisualizer = new Nikse.SubtitleEdit.Controls.AudioVisualizer();
|
||||
this.timeUpDownVideoPosition = new Nikse.SubtitleEdit.Controls.TimeUpDown();
|
||||
this.timeUpDownVideoPositionAdjust = new Nikse.SubtitleEdit.Controls.TimeUpDown();
|
||||
this.toolStripMenuItemRuby = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.statusStrip1.SuspendLayout();
|
||||
this.toolStrip1.SuspendLayout();
|
||||
this.menuStrip1.SuspendLayout();
|
||||
@ -3803,7 +3804,7 @@
|
||||
this.seekSilenceToolStripMenuItem,
|
||||
this.insertSubtitleHereToolStripMenuItem});
|
||||
this.contextMenuStripWaveform.Name = "contextMenuStripWaveform";
|
||||
this.contextMenuStripWaveform.Size = new System.Drawing.Size(275, 418);
|
||||
this.contextMenuStripWaveform.Size = new System.Drawing.Size(275, 396);
|
||||
this.contextMenuStripWaveform.Closing += new System.Windows.Forms.ToolStripDropDownClosingEventHandler(this.contextMenuStripWaveform_Closing);
|
||||
this.contextMenuStripWaveform.Opening += new System.ComponentModel.CancelEventHandler(this.ContextMenuStripWaveformOpening);
|
||||
//
|
||||
@ -4215,6 +4216,7 @@
|
||||
this.colorToolStripMenuItem1,
|
||||
this.toolStripMenuItemHorizontalDigits,
|
||||
this.toolStripMenuItemBouten,
|
||||
this.toolStripMenuItemRuby,
|
||||
this.fontNameToolStripMenuItem,
|
||||
this.toolStripSeparator26,
|
||||
this.toolStripMenuItemInsertUnicodeSymbol,
|
||||
@ -4222,7 +4224,7 @@
|
||||
this.superscriptToolStripMenuItem,
|
||||
this.subscriptToolStripMenuItem});
|
||||
this.contextMenuStripTextBoxListView.Name = "contextMenuStripTextBoxListView";
|
||||
this.contextMenuStripTextBoxListView.Size = new System.Drawing.Size(274, 468);
|
||||
this.contextMenuStripTextBoxListView.Size = new System.Drawing.Size(274, 512);
|
||||
this.contextMenuStripTextBoxListView.Closed += new System.Windows.Forms.ToolStripDropDownClosedEventHandler(this.MenuClosed);
|
||||
this.contextMenuStripTextBoxListView.Opening += new System.ComponentModel.CancelEventHandler(this.ContextMenuStripTextBoxListViewOpening);
|
||||
this.contextMenuStripTextBoxListView.Opened += new System.EventHandler(this.MenuOpened);
|
||||
@ -4798,14 +4800,14 @@
|
||||
this.timeUpDownStartTime.Name = "timeUpDownStartTime";
|
||||
this.timeUpDownStartTime.Size = new System.Drawing.Size(96, 27);
|
||||
this.timeUpDownStartTime.TabIndex = 0;
|
||||
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.timeUpDownStartTime.TimeCode = timeCode3;
|
||||
timeCode7.Hours = 0;
|
||||
timeCode7.Milliseconds = 0;
|
||||
timeCode7.Minutes = 0;
|
||||
timeCode7.Seconds = 0;
|
||||
timeCode7.TimeSpan = System.TimeSpan.Parse("00:00:00");
|
||||
timeCode7.TotalMilliseconds = 0D;
|
||||
timeCode7.TotalSeconds = 0D;
|
||||
this.timeUpDownStartTime.TimeCode = timeCode7;
|
||||
this.timeUpDownStartTime.UseVideoOffset = false;
|
||||
//
|
||||
// textBoxListViewText
|
||||
@ -4909,14 +4911,14 @@
|
||||
this.timeUpDownVideoPosition.Name = "timeUpDownVideoPosition";
|
||||
this.timeUpDownVideoPosition.Size = new System.Drawing.Size(96, 27);
|
||||
this.timeUpDownVideoPosition.TabIndex = 12;
|
||||
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.timeUpDownVideoPosition.TimeCode = timeCode1;
|
||||
timeCode8.Hours = 0;
|
||||
timeCode8.Milliseconds = 0;
|
||||
timeCode8.Minutes = 0;
|
||||
timeCode8.Seconds = 0;
|
||||
timeCode8.TimeSpan = System.TimeSpan.Parse("00:00:00");
|
||||
timeCode8.TotalMilliseconds = 0D;
|
||||
timeCode8.TotalSeconds = 0D;
|
||||
this.timeUpDownVideoPosition.TimeCode = timeCode8;
|
||||
this.timeUpDownVideoPosition.UseVideoOffset = false;
|
||||
//
|
||||
// timeUpDownVideoPositionAdjust
|
||||
@ -4929,16 +4931,23 @@
|
||||
this.timeUpDownVideoPositionAdjust.Name = "timeUpDownVideoPositionAdjust";
|
||||
this.timeUpDownVideoPositionAdjust.Size = new System.Drawing.Size(96, 27);
|
||||
this.timeUpDownVideoPositionAdjust.TabIndex = 13;
|
||||
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.timeUpDownVideoPositionAdjust.TimeCode = timeCode2;
|
||||
timeCode9.Hours = 0;
|
||||
timeCode9.Milliseconds = 0;
|
||||
timeCode9.Minutes = 0;
|
||||
timeCode9.Seconds = 0;
|
||||
timeCode9.TimeSpan = System.TimeSpan.Parse("00:00:00");
|
||||
timeCode9.TotalMilliseconds = 0D;
|
||||
timeCode9.TotalSeconds = 0D;
|
||||
this.timeUpDownVideoPositionAdjust.TimeCode = timeCode9;
|
||||
this.timeUpDownVideoPositionAdjust.UseVideoOffset = false;
|
||||
//
|
||||
// toolStripMenuItemRuby
|
||||
//
|
||||
this.toolStripMenuItemRuby.Name = "toolStripMenuItemRuby";
|
||||
this.toolStripMenuItemRuby.Size = new System.Drawing.Size(273, 22);
|
||||
this.toolStripMenuItemRuby.Text = "Ruby...";
|
||||
this.toolStripMenuItemRuby.Click += new System.EventHandler(this.toolStripMenuItemRuby_Click);
|
||||
//
|
||||
// Main
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
@ -5491,5 +5500,6 @@
|
||||
private System.Windows.Forms.ToolStripMenuItem boutenautoToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem toolStripMenuItemHorizontalDigits;
|
||||
private System.Windows.Forms.ToolStripMenuItem toolStripMenuItemSetParagraphAsSelection;
|
||||
private System.Windows.Forms.ToolStripMenuItem toolStripMenuItemRuby;
|
||||
}
|
||||
}
|
@ -22638,13 +22638,16 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
underlineToolStripMenuItem1.Visible = false;
|
||||
colorToolStripMenuItem1.Visible = false;
|
||||
fontNameToolStripMenuItem.Visible = false;
|
||||
toolStripMenuItemHorizontalDigits.Visible = true;
|
||||
if (tb.SelectionLength > 0)
|
||||
{
|
||||
toolStripMenuItemBouten.Visible = true;
|
||||
toolStripMenuItemRuby.Visible = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
toolStripMenuItemBouten.Visible = false;
|
||||
toolStripMenuItemRuby.Visible = true;
|
||||
}
|
||||
|
||||
if (tb.SelectionLength > 1 && tb.SelectionLength < 8)
|
||||
@ -22663,6 +22666,8 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
colorToolStripMenuItem1.Visible = true;
|
||||
fontNameToolStripMenuItem.Visible = true;
|
||||
toolStripMenuItemBouten.Visible = false;
|
||||
toolStripMenuItemRuby.Visible = false;
|
||||
toolStripMenuItemHorizontalDigits.Visible = false;
|
||||
}
|
||||
|
||||
if (tb.SelectionStart > 1 && tb.SelectionStart < tb.Text.Length - 1 && !string.IsNullOrEmpty(_videoFileName) && mediaPlayer != null &&
|
||||
@ -26517,5 +26522,54 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
audioVisualizer.NewSelectionParagraph = null;
|
||||
}
|
||||
}
|
||||
|
||||
private void toolStripMenuItemRuby_Click(object sender, EventArgs e)
|
||||
{
|
||||
var tb = GetFocusedTextBox();
|
||||
string before = string.Empty;
|
||||
string text = tb.SelectedText;
|
||||
string after = string.Empty;
|
||||
|
||||
int selectionStart = tb.SelectionStart;
|
||||
if (selectionStart > 0)
|
||||
{
|
||||
before = tb.Text.Substring(0, selectionStart);
|
||||
}
|
||||
|
||||
if (tb.Text.Length > selectionStart + text.Length)
|
||||
{
|
||||
after = tb.Text.Remove(0, selectionStart + text.Length);
|
||||
}
|
||||
|
||||
if (text.StartsWith(' '))
|
||||
{
|
||||
before += " ";
|
||||
text = text.TrimStart();
|
||||
}
|
||||
|
||||
if (text.EndsWith(' '))
|
||||
{
|
||||
after = " " + after;
|
||||
}
|
||||
|
||||
using (var form = new RubyJapanese(before, text, after))
|
||||
{
|
||||
if (form.ShowDialog(this) != DialogResult.OK)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
var rubyText = form.RubyText;
|
||||
if (form.RubyItalic)
|
||||
{
|
||||
rubyText = "<ruby-text-italic>" + rubyText + "</ruby-text-italic>";
|
||||
}
|
||||
else
|
||||
{
|
||||
rubyText = "<ruby-text>" + rubyText + "</ruby-text>";
|
||||
}
|
||||
tb.SelectedText = before + "<ruby-container><ruby-base>" + text + "</ruby-base>" + rubyText + "</ruby-container>" + after;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -463,18 +463,18 @@
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAALnSURBVFhHtZfPaxNBFMdHs7/GpNns7vQoeNWDZw969+Ld
|
||||
g3+AF+8ehB6tYkVQbMAWtBRbf7RJKIJiMXgqpQoKbSmtmGZ/CB7ES0XwR9f3wiRsZ1/BbLJf+J7mvX2f
|
||||
g3+AF+8ehB6tYkVUaMAWtBRbf7RJKIJiMXgqpQoKbSmtmGZ/CB7ES0XwR9f3wiRsZ1/BbLJf+J7mvX2f
|
||||
vNk3O2GHacNy44iLlNta5ZwMIdUw7JjyGGOaDPk/vTErJEBoegsyhBRVHN03wBIA7FheCmCdiz8t0z4h
|
||||
w1KiiqP7Bhgz7P1lg+5CwL0JGZYSVRydCWBOK8dtoguRKb6vM1aSoQdEFUdnAqjp5bhpOGkAsG+OXpGh
|
||||
B0QVR2cCwMTpQpkEiCxnGx56VIb3pBbuOjPAFGzDmkmPZGhULsjwntTCXWcGeALbMKPZJIBviWUZ3pNa
|
||||
uOvMAOibhZF4kziY7nOxH+iV0zKlo2TRpAcCmNRG4kWd7kJgeVMypaNk0aQHApiB9+AWdOEzNZLc/rnN
|
||||
SqMyLR8AHMdxAHh1yMEUWuKaTGPPIDZZuOuBANB3AOAuGAr+UgEi3f4CB5OBeQ+hW8m8rgcGwHHELgTc
|
||||
nUsBgAOrcgnz7kFMMq/rgQFwHDsAmnuGBDDFO8y7ATGLxDYMDIDGccS1yPBWKIi25pxFSHxp1dyhAOA4
|
||||
uOvMAOibhZF4kziY7nKxH+iV0zKlo2TRpAcCmNRG4kWd7kJgeVMypaNk0aQHApiB9+AWdOEzNZLc/rnN
|
||||
SqMyLR8AHMdxAHh1yMEUWuKaTGPPIDZZuOuBANB3AOAeGAr+UgEi3f4CB5OBeQ+hW8m8rgcGwHHELgTc
|
||||
nUsBgAOrcgnz7kNMMq/rgQFwHDsAmnuGBDDFO8y7ATGLxDYMDIDGccS1yPBWKIi25pxFSHxp1dyhAOA4
|
||||
4pqvi4sUANwVniMAxqm5QwHAX4ZrTXhYxD1fBcC7Ar4D2CmcnGTuUADwoXKZBZZzVQVAv4ZRxS7M5gGA
|
||||
lsvMZ2V3i5d+qAC7cFjhoVVVtmHoAKjIElUVAF3XK/EEQCTzcgFoGe5J/CCpAFvQBRzHx4ltyAUAFVre
|
||||
SxUAPQuf8AeJbcgNwD/mnKcA3sMl5nZiG3IDAB0JuNikIKowtvNyG/IEYCH3LlMAb+FCi98QzMsV4ANj
|
||||
Rbiqf1MBfHgZJ+U25AqACrkYVwHQL2Akn8I25A/AnOMtLn6rAJ+gC49gG3IHQMFftnkVAF2H+2TfAAtG
|
||||
ca9RKLYaur1a18tLNaM8XdPt63KZ1K7hnlo17JU1+NPyUXe+bvDi3g50pcnFXxqAsX+uGqzx31eaeQAA
|
||||
ca9RKLYaur1a18tLNaM8XdPt63KZ1K7hnlo17JU1+NPyUXe+bvDi3g50pcnFXxqAsX9tjqzp/6EPKAAA
|
||||
AABJRU5ErkJggg==
|
||||
</value>
|
||||
</data>
|
||||
@ -650,15 +650,9 @@
|
||||
<metadata name="colorDialog1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>813, 17</value>
|
||||
</metadata>
|
||||
<data name="audioVisualizer.SceneChanges" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>
|
||||
AAEAAAD/////AQAAAAAAAAAMAgAAAJoBbXNjb3JsaWIsIFZlcnNpb249NC4wLjAuMCwgQ3VsdHVyZT1u
|
||||
ZXV0cmFsLCBQdWJsaWNLZXlUb2tlbj1iNzdhNWM1NjE5MzRlMDg5XV0sIG1zY29ybGliLCBWZXJzaW9u
|
||||
PTQuMC4wLjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjc3YTVjNTYxOTM0ZTA4OQUB
|
||||
AAAAMFN5c3RlbS5Db2xsZWN0aW9ucy5HZW5lcmljLkxpc3RgMVtbU3lzdGVtLkRvdWJsZQMAAAAGX2l0
|
||||
ZW1zBV9zaXplCF92ZXJzaW9uBwAABggIAgAAAAkDAAAAAAAAAAAAAAAPAwAAAAAAAAAGCw==
|
||||
</value>
|
||||
</data>
|
||||
<metadata name="toolStripWaveControls.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>650, 56</value>
|
||||
</metadata>
|
||||
<metadata name="toolStripWaveControls.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>650, 56</value>
|
||||
</metadata>
|
||||
@ -771,7 +765,7 @@
|
||||
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
||||
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
||||
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAD2
|
||||
CAAAAk1TRnQBSQFMAgEBAgEAASABJgEgASYBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||
CAAAAk1TRnQBSQFMAgEBAgEAAUABJgFAASYBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||
AwABQAMAARADAAEBAQABCAYAAQQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
|
||||
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
|
||||
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
|
||||
@ -818,6 +812,15 @@
|
||||
<metadata name="timerAlternateTextUndo.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>916, 95</value>
|
||||
</metadata>
|
||||
<data name="audioVisualizer.SceneChanges" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>
|
||||
AAEAAAD/////AQAAAAAAAAAMAgAAAJoBbXNjb3JsaWIsIFZlcnNpb249NC4wLjAuMCwgQ3VsdHVyZT1u
|
||||
ZXV0cmFsLCBQdWJsaWNLZXlUb2tlbj1iNzdhNWM1NjE5MzRlMDg5XV0sIG1zY29ybGliLCBWZXJzaW9u
|
||||
PTQuMC4wLjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjc3YTVjNTYxOTM0ZTA4OQUB
|
||||
AAAAMFN5c3RlbS5Db2xsZWN0aW9ucy5HZW5lcmljLkxpc3RgMVtbU3lzdGVtLkRvdWJsZQMAAAAGX2l0
|
||||
ZW1zBV9zaXplCF92ZXJzaW9uBwAABggIAgAAAAkDAAAAAAAAAAAAAAAPAwAAAAAAAAAGCw==
|
||||
</value>
|
||||
</data>
|
||||
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>121</value>
|
||||
</metadata>
|
||||
|
149
src/Forms/RubyJapanese.Designer.cs
generated
Normal file
149
src/Forms/RubyJapanese.Designer.cs
generated
Normal file
@ -0,0 +1,149 @@
|
||||
namespace Nikse.SubtitleEdit.Forms
|
||||
{
|
||||
partial class RubyJapanese
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.buttonCancel = new System.Windows.Forms.Button();
|
||||
this.buttonOK = new System.Windows.Forms.Button();
|
||||
this.textBoxRubyText = new System.Windows.Forms.TextBox();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.label2 = new System.Windows.Forms.Label();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.checkBoxItalic = new System.Windows.Forms.CheckBox();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// buttonCancel
|
||||
//
|
||||
this.buttonCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.buttonCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.buttonCancel.ImeMode = System.Windows.Forms.ImeMode.NoControl;
|
||||
this.buttonCancel.Location = new System.Drawing.Point(323, 149);
|
||||
this.buttonCancel.Name = "buttonCancel";
|
||||
this.buttonCancel.Size = new System.Drawing.Size(75, 23);
|
||||
this.buttonCancel.TabIndex = 30;
|
||||
this.buttonCancel.Text = "C&ancel";
|
||||
this.buttonCancel.UseVisualStyleBackColor = true;
|
||||
this.buttonCancel.Click += new System.EventHandler(this.buttonCancel_Click);
|
||||
//
|
||||
// buttonOK
|
||||
//
|
||||
this.buttonOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.buttonOK.ImeMode = System.Windows.Forms.ImeMode.NoControl;
|
||||
this.buttonOK.Location = new System.Drawing.Point(242, 149);
|
||||
this.buttonOK.Name = "buttonOK";
|
||||
this.buttonOK.Size = new System.Drawing.Size(75, 23);
|
||||
this.buttonOK.TabIndex = 20;
|
||||
this.buttonOK.Text = "&OK";
|
||||
this.buttonOK.UseVisualStyleBackColor = true;
|
||||
this.buttonOK.Click += new System.EventHandler(this.buttonOK_Click);
|
||||
//
|
||||
// textBoxRubyText
|
||||
//
|
||||
this.textBoxRubyText.Location = new System.Drawing.Point(99, 42);
|
||||
this.textBoxRubyText.Name = "textBoxRubyText";
|
||||
this.textBoxRubyText.Size = new System.Drawing.Size(100, 20);
|
||||
this.textBoxRubyText.TabIndex = 0;
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label1.Location = new System.Drawing.Point(43, 65);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(51, 20);
|
||||
this.label1.TabIndex = 25;
|
||||
this.label1.Text = "label1";
|
||||
//
|
||||
// label2
|
||||
//
|
||||
this.label2.AutoSize = true;
|
||||
this.label2.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label2.Location = new System.Drawing.Point(96, 65);
|
||||
this.label2.Name = "label2";
|
||||
this.label2.Size = new System.Drawing.Size(51, 20);
|
||||
this.label2.TabIndex = 26;
|
||||
this.label2.Text = "label2";
|
||||
//
|
||||
// label3
|
||||
//
|
||||
this.label3.AutoSize = true;
|
||||
this.label3.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label3.Location = new System.Drawing.Point(152, 65);
|
||||
this.label3.Name = "label3";
|
||||
this.label3.Size = new System.Drawing.Size(51, 20);
|
||||
this.label3.TabIndex = 27;
|
||||
this.label3.Text = "label3";
|
||||
//
|
||||
// checkBoxItalic
|
||||
//
|
||||
this.checkBoxItalic.AutoSize = true;
|
||||
this.checkBoxItalic.Location = new System.Drawing.Point(205, 45);
|
||||
this.checkBoxItalic.Name = "checkBoxItalic";
|
||||
this.checkBoxItalic.Size = new System.Drawing.Size(48, 17);
|
||||
this.checkBoxItalic.TabIndex = 10;
|
||||
this.checkBoxItalic.Text = "Italic";
|
||||
this.checkBoxItalic.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// RubyJapanese
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(410, 184);
|
||||
this.Controls.Add(this.checkBoxItalic);
|
||||
this.Controls.Add(this.label3);
|
||||
this.Controls.Add(this.label2);
|
||||
this.Controls.Add(this.label1);
|
||||
this.Controls.Add(this.textBoxRubyText);
|
||||
this.Controls.Add(this.buttonCancel);
|
||||
this.Controls.Add(this.buttonOK);
|
||||
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
|
||||
this.MaximizeBox = false;
|
||||
this.MinimizeBox = false;
|
||||
this.Name = "RubyJapanese";
|
||||
this.ShowIcon = false;
|
||||
this.ShowInTaskbar = false;
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
||||
this.Text = "Ruby";
|
||||
this.Shown += new System.EventHandler(this.RubyJapanese_Shown);
|
||||
this.KeyDown += new System.Windows.Forms.KeyEventHandler(this.RubyJapanese_KeyDown);
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Button buttonCancel;
|
||||
private System.Windows.Forms.Button buttonOK;
|
||||
private System.Windows.Forms.TextBox textBoxRubyText;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.Label label2;
|
||||
private System.Windows.Forms.Label label3;
|
||||
private System.Windows.Forms.CheckBox checkBoxItalic;
|
||||
}
|
||||
}
|
55
src/Forms/RubyJapanese.cs
Normal file
55
src/Forms/RubyJapanese.cs
Normal file
@ -0,0 +1,55 @@
|
||||
using System.Windows.Forms;
|
||||
using Nikse.SubtitleEdit.Core;
|
||||
using Nikse.SubtitleEdit.Logic;
|
||||
|
||||
namespace Nikse.SubtitleEdit.Forms
|
||||
{
|
||||
public partial class RubyJapanese : Form
|
||||
{
|
||||
public string RubyText { get; private set; }
|
||||
public bool RubyItalic { get; private set; }
|
||||
|
||||
public RubyJapanese(string before, string text, string after)
|
||||
{
|
||||
UiUtil.PreInitialize(this);
|
||||
InitializeComponent();
|
||||
UiUtil.FixFonts(this);
|
||||
|
||||
buttonOK.Text = Configuration.Settings.Language.General.Ok;
|
||||
buttonCancel.Text = Configuration.Settings.Language.General.Cancel;
|
||||
|
||||
label1.Text = before;
|
||||
label2.Text = text;
|
||||
label3.Text = after;
|
||||
label2.Left = label1.Left + label1.Width + 5;
|
||||
label3.Left = label2.Left + label2.Width + 5;
|
||||
textBoxRubyText.Left = label2.Left;
|
||||
checkBoxItalic.Left = textBoxRubyText.Left + textBoxRubyText.Width + 5;
|
||||
}
|
||||
|
||||
private void buttonOK_Click(object sender, System.EventArgs e)
|
||||
{
|
||||
RubyText = textBoxRubyText.Text.Trim();
|
||||
RubyItalic = checkBoxItalic.Checked;
|
||||
DialogResult = DialogResult.OK;
|
||||
}
|
||||
|
||||
private void buttonCancel_Click(object sender, System.EventArgs e)
|
||||
{
|
||||
DialogResult = DialogResult.Cancel;
|
||||
}
|
||||
|
||||
private void RubyJapanese_KeyDown(object sender, KeyEventArgs e)
|
||||
{
|
||||
if (e.KeyCode == Keys.Escape)
|
||||
{
|
||||
DialogResult = DialogResult.Cancel;
|
||||
}
|
||||
}
|
||||
|
||||
private void RubyJapanese_Shown(object sender, System.EventArgs e)
|
||||
{
|
||||
textBoxRubyText.Focus();
|
||||
}
|
||||
}
|
||||
}
|
120
src/Forms/RubyJapanese.resx
Normal file
120
src/Forms/RubyJapanese.resx
Normal file
@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
@ -635,6 +635,12 @@
|
||||
<Compile Include="Forms\RestoreAutoBackup.Designer.cs">
|
||||
<DependentUpon>RestoreAutoBackup.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Forms\RubyJapanese.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Forms\RubyJapanese.Designer.cs">
|
||||
<DependentUpon>RubyJapanese.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Forms\SeekSilence.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
@ -1350,6 +1356,9 @@
|
||||
<EmbeddedResource Include="Forms\RestoreAutoBackup.resx">
|
||||
<DependentUpon>RestoreAutoBackup.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Forms\RubyJapanese.resx">
|
||||
<DependentUpon>RubyJapanese.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Forms\SeekSilence.resx">
|
||||
<DependentUpon>SeekSilence.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
|
Loading…
Reference in New Issue
Block a user