Uploaded image for project: 'FOP'
  1. FOP
  2. FOP-1791

setting svg attributes with xsl only works if intermediate fo is created

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Resolution: Cannot Reproduce
    • 0.95
    • None
    • renderer/svg
    • None
    • Operating System: Windows XP
      Platform: PC
    • 49055

    Description

      When trying to set svg path attributes via a stylesheet, the resulting shape is only displayed when the pdf is created from the intermediate fo file.
      If I skip the fo part and create the pdf directly the shape is not displayed. Same goes for the internal (-awt) viewer.

      In the stylesheet the following lines causing the problem are:

      <fo:instream-foreign-object>
      <svg xmlns="http://www.w3.org/2000/svg" width="1.5cm" height="1.5cm">
      <polygon style="fill: #cccccc;">
      <xsl:attribute name="points"><xsl:value-of select="points"/></xsl:attribute>
      </polygon>
      </svg>
      </fo:instream-foreign-object>

      In short (files are attached):

      $ fop -xml in.xml -xsl test.xsl -pdf out.pdf

      Does not create correct output (but no warning/errors are given)

      $ fop -xml in.xml -xsl test.xsl -foout out.fo
      $ fop out.fo -pdf out.pdf

      does work.

      Attachments

        1. fop-bug.zip
          10 kB
          sven
        2. fop-bug2.zip
          11 kB
          sven

        Activity

          People

            fop-dev@xmlgraphics.apache.org fop-dev
            sven_victoria@deltalloyd.nl sven
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: