small changes
authoraxelcl <axelcl>
Fri, 18 Feb 2005 21:26:18 +0000 (21:26 +0000)
committeraxelcl <axelcl>
Fri, 18 Feb 2005 21:26:18 +0000 (21:26 +0000)
archive/org.plog4u.wiki/src/org/plog4u/wiki/filter/WikipediaParser.java

index f0a4790..08a0e3b 100644 (file)
@@ -700,21 +700,21 @@ public class WikipediaParser {
             copyWhite(fWhiteStart, fWhiteStartPosition, 1);
             fWhiteStart = false;
 
-            int startHeadPosition = fCurrentPosition;
+            int startHeadPosition = fCurrentPosition-1;
             if (readUntilEOL()) {
               // TODO not correct - improve this
               String head = new String(fSource, startHeadPosition, fCurrentPosition - startHeadPosition);
-              int index = head.indexOf(": ");
+              int index = head.indexOf(" : ");
               if (index > 0) {
                 fResultBuffer.append("<dl><dt>");
                 fResultBuffer.append(head.substring(0, index));
-                fResultBuffer.append("</dt><dd>");
+                fResultBuffer.append("&nbsp;</dt><dd>");
                 fResultBuffer.append(head.substring(index + 2));
                 fResultBuffer.append("</dd></dl>");
               } else {
                 fResultBuffer.append("<dl><dt>");
                 fResultBuffer.append(head);
-                fResultBuffer.append("</dt></dl>");
+                fResultBuffer.append("&nbsp;</dt></dl>");
               }
               continue;
             }