spirit avatar spirit committed 1990386

ParamTwoLinesException

Comments (0)

Files changed (1)

     "0 = Off\n" +
     "1 = Detect for incomplete sentences (default)\n" +
     "2 = Detect for all lines" },
+  ParamTwoLinesException : {
+    Value : "\bsous-titres.eu\b",
+    Unit : "regular expression",
+    Description :
+    "Don't trigger a \"no need for two lines\" error " +
+    "if the subtitle matches this expression." },
   ParamDetectBadSplits : { Value : 0, Unit : "(0/1)", Description :
     "Detect line splits that are possibly bad.\n" +
     "0 = Off (default)\n" +
         var result = NoNeedForTwoLines[this.ParamMode.Value](
             strippedOneLineText);
 
-        if (result) {
+        if (result && (!this.ParamTwoLinesException.Value.length ||
+                CurrentSub.StrippedText.search(
+                this.ParamTwoLinesException.Value) < 0)) {
             return Common.formatMessage(this.NoNeedForNLinesMessage,
                 {num: Common.getNumberText(numLines),
                 value: result.value, unit: result.unit});
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.