- Timestamp:
- 11/30/10 13:32:25 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/de.ugoe.cs.swe.bnftools.ebnf.ui/src/de/ugoe/cs/swe/bnftools/ui/formatter/EbnfHtmlFormatterVisitor.java
r44 r45 65 65 char originalPosition = originalText.charAt(bufferPositionOriginalText); 66 66 67 String commentPrefix = "<span lang=EN-GB style='color:green;mso-no-proof:no'>"; 68 String commentSuffix = "<o:p></o:p></span>"; 69 67 70 if (formattedPositionNoWhitespaces != originalPosition) { 68 71 // if ((currentMetaText != null) && (bufferPositionFormattedTextNoWhitespaces == currentMetaText.getOffset())) { … … 85 88 if (newLinesCount > 0) { 86 89 if (scanBackNewlinesCount(result.toString(), result.toString().length()-1) == 0) { 87 result.append("\n\n"); 90 // result.append("\n\n"); 91 // result.append("<p>"); 88 92 } 89 90 result.append(currentComment.getText()); 91 result.append("\n"); 93 result.append("\n<br/><br/>"); 94 result.append(commentPrefix + currentComment.getText() + commentSuffix); 95 // result.append("\n"); 96 result.append("\n<br/>"); 97 // result.append("<p/>"); 92 98 } else { 93 99 String lastWhiteSpaces = scanBackWhitespaces(result.toString(), result.toString().length()-1); 94 100 result.delete(result.toString().length() - lastWhiteSpaces.length(), result.toString().length()); 95 result.append(" " + stripEndingNewline(currentComment.getText())); 101 // result.append(" " + stripEndingNewline(currentComment.getText())); 102 result.append(" " + commentPrefix + stripEndingNewline(currentComment.getText()) + commentSuffix); 96 103 result.append(lastWhiteSpaces); 97 104 } … … 101 108 result.delete(result.toString().length() - lastWhiteSpaces.length(), result.toString().length()); 102 109 if (newLinesCount > 0) { 103 result.append("\n\n" + stripEndingNewline(currentComment.getText())); 110 // result.append("\n\n" + stripEndingNewline(currentComment.getText())); 111 result.append("<br/><br/>" + commentPrefix + stripEndingNewline(currentComment.getText()) + commentSuffix); 104 112 } else { 105 result.append(" " + stripEndingNewline(currentComment.getText())); 113 // result.append(" " + stripEndingNewline(currentComment.getText())); 114 result.append(" " + commentPrefix + stripEndingNewline(currentComment.getText()) + commentSuffix); 106 115 } 107 116 result.append(lastWhiteSpaces);
Note: See TracChangeset
for help on using the changeset viewer.