diff --git a/src/Forms/Statistics.Designer.cs b/src/Forms/Statistics.Designer.cs
index ab5b8bc52..85dc7be90 100644
--- a/src/Forms/Statistics.Designer.cs
+++ b/src/Forms/Statistics.Designer.cs
@@ -75,7 +75,7 @@
this.textBoxGeneral.Name = "textBoxGeneral";
this.textBoxGeneral.ReadOnly = true;
this.textBoxGeneral.ScrollBars = System.Windows.Forms.ScrollBars.Both;
- this.textBoxGeneral.Size = new System.Drawing.Size(693, 351);
+ this.textBoxGeneral.Size = new System.Drawing.Size(694, 351);
this.textBoxGeneral.TabIndex = 0;
//
// groupBoxMostUsed
@@ -122,14 +122,14 @@
this.textBoxMostUsedLines.Name = "textBoxMostUsedLines";
this.textBoxMostUsedLines.ReadOnly = true;
this.textBoxMostUsedLines.ScrollBars = System.Windows.Forms.ScrollBars.Both;
- this.textBoxMostUsedLines.Size = new System.Drawing.Size(367, 183);
+ this.textBoxMostUsedLines.Size = new System.Drawing.Size(371, 183);
this.textBoxMostUsedLines.TabIndex = 3;
//
// textBoxMostUsedWords
//
this.textBoxMostUsedWords.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)));
- this.textBoxMostUsedWords.Location = new System.Drawing.Point(6, 43);
+ this.textBoxMostUsedWords.Location = new System.Drawing.Point(9, 43);
this.textBoxMostUsedWords.Multiline = true;
this.textBoxMostUsedWords.Name = "textBoxMostUsedWords";
this.textBoxMostUsedWords.ReadOnly = true;
@@ -139,9 +139,10 @@
//
// buttonExport
//
- this.buttonExport.Location = new System.Drawing.Point(534, 632);
+ this.buttonExport.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
+ this.buttonExport.Location = new System.Drawing.Point(532, 632);
this.buttonExport.Name = "buttonExport";
- this.buttonExport.Size = new System.Drawing.Size(102, 23);
+ this.buttonExport.Size = new System.Drawing.Size(104, 21);
this.buttonExport.TabIndex = 2;
this.buttonExport.Text = "Export";
this.buttonExport.UseVisualStyleBackColor = true;
diff --git a/src/Forms/Statistics.cs b/src/Forms/Statistics.cs
index a7ae72583..935a21445 100644
--- a/src/Forms/Statistics.cs
+++ b/src/Forms/Statistics.cs
@@ -192,11 +192,11 @@ https://github.com/SubtitleEdit/subtitleedit
lastLine = lastLine.Replace("", "");
lastLine = lastLine.Replace("", ".");
- var idx = lastLine.IndexOf("= 0)
{
- var endIdx = lastLine.IndexOf('>', idx + 6);
+ var endIdx = lastLine.IndexOf('>', idx + 5);
if (endIdx < idx)
{
error = !error;
@@ -204,7 +204,7 @@ https://github.com/SubtitleEdit/subtitleedit
}
endIdx++;
lastLine = lastLine.Remove(idx, (endIdx - idx));
- idx = lastLine.IndexOf("", ".");
@@ -249,8 +249,7 @@ https://github.com/SubtitleEdit/subtitleedit
lastLine = lastLine.Replace("...", ".");
lastLine = lastLine.Replace("..", ".");
lastLine = lastLine.Replace("-", " ");
- lastLine = lastLine.Replace(" ", " ");
- lastLine = lastLine.Replace(" ", " ");
+ lastLine = lastLine.FixExtraSpaces();
string[] lines = lastLine.Split('.');
foreach (string line in lines)
@@ -263,12 +262,9 @@ https://github.com/SubtitleEdit/subtitleedit
hits++;
hashtable[s] = hits.ToString(CultureInfo.InvariantCulture);
}
- else if (s.Length > 0)
+ else if (s.Length > 0 && s.Contains(' '))
{
- if (s.Contains(' '))
- {
- hashtable.Add(s, "1");
- }
+ hashtable.Add(s, "1");
}
}
}