• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Vector graphics in Flying Saucer / ERPDFWrapper
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Vector graphics in Flying Saucer / ERPDFWrapper


  • Subject: Vector graphics in Flying Saucer / ERPDFWrapper
  • From: Ricardo Parada <email@hidden>
  • Date: Tue, 17 Nov 2015 12:01:48 -0500
  • X_v_e_cd: 3c18fbd384f4e3a229990ecdf649fec1
  • X_v_r_cd: c43a1ef6df6be23e174dda3a2bf1f149

Hi all,

We use ERPDFWrapper to generate PDF from a WOComponent.  It comes out beautiful.  

One of our components includes a logo using the <img> html tag and the logo is usually a .gif or .jpg.  However, I would like to use vector graphics.  We took a .eps file and converted it to .pdf in Photoshop.  The resulting image scales beautifully to any size.  When I try to use the .pdf I get java.lang.ClassCastException: org.xhtmlrenderer.pdf.PDFAsImage cannot be cast to org.xhtmlrenderer.pdf.ITextFSImage.  

Has anybody been able to use vector graphics in ERPDFWrapper?

Thanks

The stack trace is below:

java.lang.ClassCastException: org.xhtmlrenderer.pdf.PDFAsImage cannot be cast to org.xhtmlrenderer.pdf.ITextFSImage

                at org.xhtmlrenderer.pdf.ITextUserAgent.getImageResource(ITextUserAgent.java:97)

                at org.xhtmlrenderer.pdf.ITextReplacedElementFactory.createReplacedElement(ITextReplacedElementFactory.java:57)

                at er.pdf.builder.ERPDFReplacedElementFactory.createReplacedElement(ERPDFReplacedElementFactory.java:50)

                at org.xhtmlrenderer.render.BlockBox.calcMinMaxWidth(BlockBox.java:1439)

                at org.xhtmlrenderer.render.BlockBox.calcMinMaxWidthInlineChildren(BlockBox.java:1584)

                at org.xhtmlrenderer.render.BlockBox.calcMinMaxWidth(BlockBox.java:1481)

                at org.xhtmlrenderer.newtable.TableBox$AutoTableLayout.recalcColumn(TableBox.java:1240)

                at org.xhtmlrenderer.newtable.TableBox$AutoTableLayout.fullRecalc(TableBox.java:1214)

                at org.xhtmlrenderer.newtable.TableBox$AutoTableLayout.calcMinMaxWidth(TableBox.java:1509)

                at org.xhtmlrenderer.newtable.TableBox.calcMinMaxWidth(TableBox.java:158)

                at org.xhtmlrenderer.newtable.TableBox.layout(TableBox.java:221)

                at org.xhtmlrenderer.layout.BlockBoxing.layoutBlockChild0(BlockBoxing.java:321)

                at org.xhtmlrenderer.layout.BlockBoxing.layoutBlockChild(BlockBoxing.java:299)

                at org.xhtmlrenderer.layout.BlockBoxing.layoutContent(BlockBoxing.java:90)

                at org.xhtmlrenderer.render.BlockBox.layoutChildren(BlockBox.java:926)

                at org.xhtmlrenderer.render.BlockBox.layout(BlockBox.java:806)

                at org.xhtmlrenderer.render.BlockBox.layout(BlockBox.java:735)

                at org.xhtmlrenderer.layout.BlockBoxing.layoutBlockChild0(BlockBoxing.java:321)

                at org.xhtmlrenderer.layout.BlockBoxing.layoutBlockChild(BlockBoxing.java:299)

                at org.xhtmlrenderer.layout.BlockBoxing.layoutContent(BlockBoxing.java:90)

                at org.xhtmlrenderer.render.BlockBox.layoutChildren(BlockBox.java:926)

                at org.xhtmlrenderer.render.BlockBox.layout(BlockBox.java:806)

                at org.xhtmlrenderer.render.BlockBox.layout(BlockBox.java:735)

                at org.xhtmlrenderer.pdf.ITextRenderer.layout(ITextRenderer.java:216)

                at er.pdf.builder.FlyingSaucerImpl.setSource(FlyingSaucerImpl.java:99)

                at er.pdf.ERPDFUtilities.htmlAsPdf(ERPDFUtilities.java:123)

                at er.pdf.ERPDFWrapper.responseAsPdf(ERPDFWrapper.java:75)

                at er.pdf.ERPDFWrapper.appendToResponse(ERPDFWrapper.java:60)

                at com.webobjects.appserver.WOComponent.appendToResponse(WOComponent.java:1122)

                at er.extensions.components.ERXComponent.appendToResponse(ERXComponent.java:117)

                at er.extensions.components.ERXNonSynchronizingComponent.appendToResponse(ERXNonSynchronizingComponent.java:73)

                at com.mpv.webcomponents.MPVWOComponent.appendToResponse(MPVWOComponent.java:67)

                at com.webobjects.appserver.WOSession.appendToResponse(WOSession.java:1385)

                at er.extensions.appserver.ERXSession.appendToResponse(ERXSession.java:552)

...

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Vector graphics in Flying Saucer / ERPDFWrapper
      • From: Timo Hoepfner <email@hidden>
    • Re: Vector graphics in Flying Saucer / ERPDFWrapper
      • From: Samuel Pelletier <email@hidden>
  • Prev by Date: Re: WOCompile cannot be found.
  • Next by Date: Re: Vector graphics in Flying Saucer / ERPDFWrapper
  • Previous by thread: Re: WOCompile cannot be found.
  • Next by thread: Re: Vector graphics in Flying Saucer / ERPDFWrapper
  • Index(es):
    • Date
    • Thread