fix loosed formatting to endnotes and footnotes in Word-to-HTML and Word-to-FO converters
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1149022 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
3f0760921f
commit
b4ae01ff14
@ -284,7 +284,17 @@ public class WordToFoConverter extends AbstractWordConverter
|
|||||||
backwardLink.appendChild( createNoteInline( textIndex + " " ) );
|
backwardLink.appendChild( createNoteInline( textIndex + " " ) );
|
||||||
backwardLink.setAttribute( "id", forwardLinkName );
|
backwardLink.setAttribute( "id", forwardLinkName );
|
||||||
endnote.appendChild( backwardLink );
|
endnote.appendChild( backwardLink );
|
||||||
processCharacters( doc, Integer.MIN_VALUE, endnoteTextRange, endnote );
|
|
||||||
|
blocksProperies.push( new BlockProperies( "", -1, false, false ) );
|
||||||
|
try
|
||||||
|
{
|
||||||
|
processCharacters( doc, Integer.MIN_VALUE, endnoteTextRange,
|
||||||
|
endnote );
|
||||||
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
blocksProperies.pop();
|
||||||
|
}
|
||||||
this.endnotes.add( endnote );
|
this.endnotes.add( endnote );
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -317,9 +327,17 @@ public class WordToFoConverter extends AbstractWordConverter
|
|||||||
footnoteBody.appendChild( footnoteBlock );
|
footnoteBody.appendChild( footnoteBlock );
|
||||||
footNote.appendChild( footnoteBody );
|
footNote.appendChild( footnoteBody );
|
||||||
|
|
||||||
|
blocksProperies.push( new BlockProperies( "", -1, false, false ) );
|
||||||
|
try
|
||||||
|
{
|
||||||
processCharacters( doc, Integer.MIN_VALUE, footnoteTextRange,
|
processCharacters( doc, Integer.MIN_VALUE, footnoteTextRange,
|
||||||
footnoteBlock );
|
footnoteBlock );
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
blocksProperies.pop();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
protected void processHyperlink( HWPFDocumentCore wordDocument,
|
protected void processHyperlink( HWPFDocumentCore wordDocument,
|
||||||
Element currentBlock, Range textRange, int currentTableLevel,
|
Element currentBlock, Range textRange, int currentTableLevel,
|
||||||
|
@ -437,8 +437,16 @@ public class WordToHtmlConverter extends AbstractWordConverter
|
|||||||
span.setAttribute( "class", type + "notetext" );
|
span.setAttribute( "class", type + "notetext" );
|
||||||
note.appendChild( span );
|
note.appendChild( span );
|
||||||
|
|
||||||
|
this.blocksProperies.add( new BlockProperies( "", -1 ) );
|
||||||
|
try
|
||||||
|
{
|
||||||
processCharacters( doc, Integer.MIN_VALUE, noteTextRange, span );
|
processCharacters( doc, Integer.MIN_VALUE, noteTextRange, span );
|
||||||
}
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
this.blocksProperies.pop();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
protected void processPageref( HWPFDocumentCore hwpfDocument,
|
protected void processPageref( HWPFDocumentCore hwpfDocument,
|
||||||
Element currentBlock, Range textRange, int currentTableLevel,
|
Element currentBlock, Range textRange, int currentTableLevel,
|
||||||
@ -658,6 +666,12 @@ public class WordToHtmlConverter extends AbstractWordConverter
|
|||||||
}
|
}
|
||||||
|
|
||||||
final Element tableElement = htmlDocumentFacade.createTable();
|
final Element tableElement = htmlDocumentFacade.createTable();
|
||||||
|
tableElement
|
||||||
|
.setAttribute(
|
||||||
|
"class",
|
||||||
|
htmlDocumentFacade.getOrCreateCssClass(
|
||||||
|
tableElement.getTagName(), "t",
|
||||||
|
"table-layout:fixed;border-collapse:collapse;border-spacing:0;" ) );
|
||||||
if ( tableHeader.hasChildNodes() )
|
if ( tableHeader.hasChildNodes() )
|
||||||
{
|
{
|
||||||
tableElement.appendChild( tableHeader );
|
tableElement.appendChild( tableHeader );
|
||||||
|
Loading…
Reference in New Issue
Block a user