|
|
|
@ -244,8 +244,7 @@ public class HTMLWorker implements SimpleXMLDocHandler, DocListener {
|
|
|
|
|
} |
|
|
|
|
if (tag.equals(HtmlTags.NEWLINE)) { |
|
|
|
|
if (currentParagraph == null) { |
|
|
|
|
currentParagraph = FactoryProperties |
|
|
|
|
.createParagraph(cprops); |
|
|
|
|
currentParagraph = new Paragraph(); |
|
|
|
|
} |
|
|
|
|
currentParagraph.add(factoryProperties |
|
|
|
|
.createChunk("\n", cprops)); |
|
|
|
@ -258,8 +257,7 @@ public class HTMLWorker implements SimpleXMLDocHandler, DocListener {
|
|
|
|
|
// end with a break, but a trailing break is always inserted.
|
|
|
|
|
boolean addLeadingBreak = true; |
|
|
|
|
if (currentParagraph == null) { |
|
|
|
|
currentParagraph = FactoryProperties |
|
|
|
|
.createParagraph(cprops); |
|
|
|
|
currentParagraph = new Paragraph(); |
|
|
|
|
addLeadingBreak = false; |
|
|
|
|
} |
|
|
|
|
if (addLeadingBreak) { // Not a new paragraph
|
|
|
|
|