mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-26 13:12:39 +01:00
[ExportPngXml] - Clean/Refact.
This commit is contained in:
parent
7952b4e6b8
commit
f7e1e048ce
@ -3656,16 +3656,9 @@ $DROP=[DROPVALUE]" + Environment.NewLine + Environment.NewLine +
|
|||||||
|
|
||||||
private void comboBox3D_SelectedIndexChanged(object sender, EventArgs e)
|
private void comboBox3D_SelectedIndexChanged(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
if (comboBox3D.SelectedIndex == 0)
|
bool enable = comboBox3D.SelectedIndex > 0;
|
||||||
{
|
labelDepth.Enabled = enable;
|
||||||
labelDepth.Enabled = false;
|
numericUpDownDepth3D.Enabled = enable;
|
||||||
numericUpDownDepth3D.Enabled = false;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
labelDepth.Enabled = true;
|
|
||||||
numericUpDownDepth3D.Enabled = true;
|
|
||||||
}
|
|
||||||
subtitleListView1_SelectedIndexChanged(null, null);
|
subtitleListView1_SelectedIndexChanged(null, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3849,7 +3842,7 @@ $DROP=[DROPVALUE]" + Environment.NewLine + Environment.NewLine +
|
|||||||
p.Text = p.Text.Replace("<" + BoxMultiLineText + ">", string.Empty).Replace("</" + BoxMultiLineText + ">", string.Empty);
|
p.Text = p.Text.Replace("<" + BoxMultiLineText + ">", string.Empty).Replace("</" + BoxMultiLineText + ">", string.Empty);
|
||||||
|
|
||||||
if (isSsa)
|
if (isSsa)
|
||||||
p.Text = RemoveSsaStyle(p.Text);
|
p.Text = Utilities.RemoveSsaTags(p.Text);
|
||||||
SubtitleListView1SetText(item.Index, p.Text);
|
SubtitleListView1SetText(item.Index, p.Text);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -3857,18 +3850,6 @@ $DROP=[DROPVALUE]" + Environment.NewLine + Environment.NewLine +
|
|||||||
subtitleListView1_SelectedIndexChanged(null, null);
|
subtitleListView1_SelectedIndexChanged(null, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static string RemoveSsaStyle(string text)
|
|
||||||
{
|
|
||||||
int indexOfBegin = text.IndexOf('{');
|
|
||||||
while (indexOfBegin >= 0 && text.IndexOf('}') > indexOfBegin)
|
|
||||||
{
|
|
||||||
int indexOfEnd = text.IndexOf('}');
|
|
||||||
text = text.Remove(indexOfBegin, (indexOfEnd - indexOfBegin) + 1);
|
|
||||||
indexOfBegin = text.IndexOf('{');
|
|
||||||
}
|
|
||||||
return text;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void subtitleListView1_KeyDown(object sender, KeyEventArgs e)
|
private void subtitleListView1_KeyDown(object sender, KeyEventArgs e)
|
||||||
{
|
{
|
||||||
var italicShortCut = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainTextBoxItalic);
|
var italicShortCut = UiUtil.GetKeys(Configuration.Settings.Shortcuts.MainTextBoxItalic);
|
||||||
|
Loading…
Reference in New Issue
Block a user