/**
* {@inheritDoc}
*/
+ @Override
public void setUserAgent(FOUserAgent agent) {
super.setUserAgent(agent);
}
/** {@inheritDoc} */
+ @Override
public void setupFontInfo(FontInfo inFontInfo) throws FOPException {
if (mimic != null) {
mimic.setupFontInfo(inFontInfo);
//TODO Remove the following line (makes changes in the test checks necessary)
addAttribute(name, bkg.toString());
if (bkg.getColor() != null) {
- addAttribute("bkg-color", bkg.getColor().toString());
+ addAttribute("bkg-color", ColorUtil.colorToString(bkg.getColor()));
}
if (bkg.getURL() != null) {
addAttribute("bkg-img", bkg.getURL());
}
/** {@inheritDoc} */
+ @Override
public void processOffDocumentItem(OffDocumentItem oDI) {
if (oDI instanceof BookmarkData) {
renderBookmarkTree((BookmarkData) oDI);
* Renders a BookmarkTree object
* @param bookmarkRoot the BookmarkData object representing the top of the tree
*/
+ @Override
protected void renderBookmarkTree(BookmarkData bookmarkRoot) {
if (bookmarkRoot.getWhenToProcess() == OffDocumentItem.END_OF_DOC) {
endPageSequence();
}
/** {@inheritDoc} */
+ @Override
public void startRenderer(OutputStream outputStream)
throws IOException {
log.debug("Rendering areas to Area Tree XML");
}
/** {@inheritDoc} */
+ @Override
public void stopRenderer() throws IOException {
endPageSequence();
endElement("areaTree");
}
/** {@inheritDoc} */
+ @Override
public void renderPage(PageViewport page) throws IOException, FOPException {
atts.clear();
addAttribute("bounds", page.getViewArea());
}
/** {@inheritDoc} */
+ @Override
protected void handleExtensionAttachments(List attachments) {
if (attachments != null && attachments.size() > 0) {
startElement("extension-attachments");
}
/** {@inheritDoc} */
+ @Override
public void startPageSequence(PageSequence pageSequence) {
handleDocumentExtensionAttachments();
endPageSequence(); // move this before handleDocumentExtensionAttachments() ?
/**
* {@inheritDoc}
*/
+ @Override
protected void renderRegionViewport(RegionViewport port) {
if (port != null) {
atts.clear();
}
/** {@inheritDoc} */
+ @Override
protected void startVParea(CTM ctm, Rectangle2D clippingRect) {
//only necessary for graphical output
}
/** {@inheritDoc} */
+ @Override
protected void endVParea() {
//only necessary for graphical output
}
* {@inheritDoc}
* org.apache.fop.area.inline.InlineArea)
*/
+ @Override
protected void renderInlineAreaBackAndBorders(InlineArea area) {
//only necessary for graphical output
}
/**
* {@inheritDoc}
*/
+ @Override
protected void renderBeforeFloat(BeforeFloat bf) {
startElement("beforeFloat");
super.renderBeforeFloat(bf);
/**
* {@inheritDoc}
*/
+ @Override
protected void renderFootnote(Footnote footnote) {
atts.clear();
addAttribute("top-offset", footnote.getTop());
/**
* {@inheritDoc}
*/
+ @Override
protected void renderMainReference(MainReference mr) {
atts.clear();
addAreaAttributes(mr);
addTraitAttributes(span);
startElement("span", atts);
for (int c = 0; c < span.getColumnCount(); c++) {
- NormalFlow flow = (NormalFlow) span.getNormalFlow(c);
+ NormalFlow flow = span.getNormalFlow(c);
renderFlow(flow);
}
/**
* {@inheritDoc}
*/
+ @Override
protected void renderFlow(NormalFlow flow) {
// the normal flow reference area contains stacked blocks
atts.clear();
}
/** {@inheritDoc} */
+ @Override
protected void renderReferenceArea(Block block) {
handleBlockTraits(block);
}
/** {@inheritDoc} */
+ @Override
protected void renderBlock(Block block) {
atts.clear();
addAreaAttributes(block);
/**
* {@inheritDoc}
*/
+ @Override
protected void renderLineArea(LineArea line) {
atts.clear();
addAreaAttributes(line);
/**
* {@inheritDoc}
*/
+ @Override
protected void renderInlineArea(InlineArea inlineArea) {
atts.clear();
if (inlineArea.getClass() == InlineArea.class) {
/**
* {@inheritDoc}
*/
+ @Override
protected void renderViewport(Viewport viewport) {
atts.clear();
addAreaAttributes(viewport);
/**
* {@inheritDoc}
*/
+ @Override
public void renderImage(Image image, Rectangle2D pos) {
atts.clear();
addAreaAttributes(image);
/**
* {@inheritDoc}
*/
+ @Override
public void renderContainer(Container cont) {
startElement("container");
super.renderContainer(cont);
* @param pos the position of the foreign object
* @see org.apache.fop.render.AbstractRenderer#renderForeignObject(ForeignObject, Rectangle2D)
*/
+ @Override
public void renderForeignObject(ForeignObject fo, Rectangle2D pos) {
atts.clear();
addAreaAttributes(fo);
/**
* {@inheritDoc}
*/
+ @Override
protected void renderInlineSpace(Space space) {
atts.clear();
addAreaAttributes(space);
/**
* {@inheritDoc}
*/
+ @Override
protected void renderText(TextArea text) {
atts.clear();
if (text.getTextWordSpaceAdjust() != 0) {
/**
* {@inheritDoc}
*/
+ @Override
protected void renderWord(WordArea word) {
atts.clear();
addAttribute("offset", word.getOffset());
/**
* {@inheritDoc}
*/
+ @Override
protected void renderSpace(SpaceArea space) {
atts.clear();
addAttribute("offset", space.getOffset());
/**
* {@inheritDoc}
*/
+ @Override
protected void renderInlineParent(InlineParent ip) {
atts.clear();
addAreaAttributes(ip);
/**
* {@inheritDoc}
*/
+ @Override
protected void renderInlineBlockParent(InlineBlockParent ibp) {
atts.clear();
addAreaAttributes(ibp);
/**
* {@inheritDoc}
*/
+ @Override
protected void renderLeader(Leader area) {
atts.clear();
addAreaAttributes(area);