Fix casing - start with uppercase after music symbol - but only if next line does not start with music symbol

git-svn-id: https://subtitleedit.googlecode.com/svn/trunk@97 99eadd0c-20b8-1223-b5c4-2a2b2df33de2
This commit is contained in:
niksedk 2010-10-27 08:47:15 +00:00
parent ab0c6d0a23
commit bc1f678df6

View File

@ -20,7 +20,7 @@ namespace Nikse.SubtitleEdit.Logic
}
public StripableText(string text)
: this(text, " >-\"['`´¶(♪¿¡.", " -\"]'`´¶)♪.!?:")
: this(text, " >-\"”“['`´¶(♪¿¡.", " -\"”“]'`´¶)♪.!?:")
{
}
@ -171,6 +171,13 @@ namespace Nikse.SubtitleEdit.Logic
s.EndsWith(")") ||
s.EndsWith(":");
// start with uppercase after music symbol - but only if next line not starts with music symbol
if (!startWithUppercase && (s.EndsWith("♪") || s.EndsWith("♫")))
{
if (!Pre.Contains("♪") && !Pre.Contains("♫"))
startWithUppercase = true;
}
if (startWithUppercase && StrippedText.Length > 0)
{
StrippedText = StrippedText.Remove(0, 1).Insert(0, StrippedText[0].ToString().ToUpper());