Do not create ODF Section div in case creating Greenstone sections to split document later.
This commit is contained in:
parent
bf765cac21
commit
512850e280
1 changed files with 24 additions and 17 deletions
|
@ -474,7 +474,9 @@ public class TextConverter extends ConverterHelper {
|
|||
String sName = Misc.getAttribute(onode,XMLString.TEXT_NAME);
|
||||
String sStyleName = Misc.getAttribute(onode,XMLString.TEXT_STYLE_NAME);
|
||||
////closePageSection
|
||||
Element div = converter.createElement("div");
|
||||
Element div = (Element) hnode;
|
||||
if (headingTags == null) {
|
||||
div = converter.createElement("div");
|
||||
// close page before enter
|
||||
hnode = GreenstoneTags.closePage(hnode);
|
||||
|
||||
|
@ -486,15 +488,20 @@ public class TextConverter extends ConverterHelper {
|
|||
sections.push(onode);
|
||||
//open page after enter
|
||||
div = (Element) GreenstoneTags.openPage(div, pageNum);
|
||||
}
|
||||
|
||||
Node newhnode = traverseBlockText(onode, div);
|
||||
Node result = null;
|
||||
if (headingTags == null) {
|
||||
//close page before exit
|
||||
newhnode = GreenstoneTags.closePage(newhnode);
|
||||
|
||||
Node result = newhnode.getParentNode();
|
||||
result = newhnode.getParentNode();
|
||||
//Open page after exit
|
||||
result = (Element) GreenstoneTags.openPage(result, pageNum);
|
||||
|
||||
sections.pop();
|
||||
} else {
|
||||
result = newhnode;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue