Loading ...
Sorry, an error occurred while loading the content.
 

Re: [XSL-FO] Help with fo

Expand Messages
  • Mike Ferrando
    Javier, When you are in the root template, you are technically NOT in an element yet, you cannot simply just ask for . [everything]. This is why the txt file
    Message 1 of 8 , Sep 22, 2005
      Javier,
      When you are in the root template, you are technically NOT in an
      element yet, you cannot simply just ask for "." [everything].

      This is why the txt file is empty.

      Try this for a xsl:value-of

      <xsl:template match="/">
      <xsl:value-of select="//K43PRINT"/>
      </xsl:template>


      Mike Ferrando
      Library Technician
      Library of Congress
      Washington, DC
      202-707-4454


      --- javier_azaola <javier_azaola@...> wrote:

      > Hi
      >
      > Xml:
      >
      > <K43PRINT>
      > <K43TABLE>
      > <K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
      > <K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
      > <K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
      > <K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
      > <K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
      > </K43TABLE>
      > </K43PRINT>
      >
      > Xsl:
      > <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
      > version="1.0">
      > <xsl:output method="text"/>
      > <xsl:template match="/" >
      > Element:<xsl:value-of select="."/>
      > </xsl:template>
      > </xsl:stylesheet>
      >
      > Execute:
      >
      > fop -xml ejemplo.xml -xsl ejemplo.xsl -txt ejemplo.txt
      >
      >
      > Ejemplo.txt is an emtpy file, what is the problem?
      >
      > Thanks!!!
      > Eskerrikasko!!!
      >
      >
      >
      >
      >
      >
      >
      >
      > ------------------------ Yahoo! Groups Sponsor
      > --------------------~-->
      > Get fast access to your favorite Yahoo! Groups. Make Yahoo! your
      > home page
      > http://us.click.yahoo.com/dpRU5A/wUILAA/yQLSAA/9rHolB/TM
      >
      --------------------------------------------------------------------~->
      >
      >
      >
      > Yahoo! Groups Links
      >
      >
      >
      >
      >
      >
      >
      >




      __________________________________
      Yahoo! Mail - PC Magazine Editors' Choice 2005
      http://mail.yahoo.com
    • javier_azaola
      Thanks Mike! I am trying it but the result is the same, i m using fop-0.20.5. to execute the action. Can fop execute this xsl file ? Goodbye! ...
      Message 2 of 8 , Sep 23, 2005
        Thanks Mike!

        I am trying it but the result is the same, i'm using fop-0.20.5. to
        execute the action. Can fop execute this xsl file ?

        Goodbye!

        --- In XSL-FO@yahoogroups.com, Mike Ferrando <mikeferrando@y...>
        wrote:
        > Javier,
        > When you are in the root template, you are technically NOT in an
        > element yet, you cannot simply just ask for "." [everything].
        >
        > This is why the txt file is empty.
        >
        > Try this for a xsl:value-of
        >
        > <xsl:template match="/">
        > <xsl:value-of select="//K43PRINT"/>
        > </xsl:template>
        >
        >
        > Mike Ferrando
        > Library Technician
        > Library of Congress
        > Washington, DC
        > 202-707-4454
        >
        >
        > --- javier_azaola <javier_azaola@y...> wrote:
        >
        > > Hi
        > >
        > > Xml:
        > >
        > > <K43PRINT>
        > > <K43TABLE>
        > > <K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
        > > <K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
        > > <K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
        > > <K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
        > > <K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
        > > </K43TABLE>
        > > </K43PRINT>
        > >
        > > Xsl:
        > > <xsl:stylesheet
        xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
        > > version="1.0">
        > > <xsl:output method="text"/>
        > > <xsl:template match="/" >
        > > Element:<xsl:value-of select="."/>
        > > </xsl:template>
        > > </xsl:stylesheet>
        > >
        > > Execute:
        > >
        > > fop -xml ejemplo.xml -xsl ejemplo.xsl -txt ejemplo.txt
        > >
        > >
        > > Ejemplo.txt is an emtpy file, what is the problem?
        > >
        > > Thanks!!!
        > > Eskerrikasko!!!
        > >
        > >
        > >
        > >
        > >
        > >
        > >
        > >
        > > ------------------------ Yahoo! Groups Sponsor
        > > --------------------~-->
        > > Get fast access to your favorite Yahoo! Groups. Make Yahoo! your
        > > home page
        > > http://us.click.yahoo.com/dpRU5A/wUILAA/yQLSAA/9rHolB/TM
        > >
        > -------------------------------------------------------------------
        -~->
        > >
        > >
        > >
        > > Yahoo! Groups Links
        > >
        > >
        > >
        > >
        > >
        > >
        > >
        > >
        >
        >
        >
        >
        > __________________________________
        > Yahoo! Mail - PC Magazine Editors' Choice 2005
        > http://mail.yahoo.com
      • Mike Trotman
        Your example XML + XSL work OK with any XSLT processor. However FOP is an XSL-FO processor. XSLT is just used as a way to help you prepare XSL-FO documents for
        Message 3 of 8 , Sep 24, 2005
          Your example XML + XSL work OK with any XSLT processor.

          However FOP is an XSL-FO processor.
          XSLT is just used as a way to help you prepare XSL-FO documents for FOP
          processing.

          Unless you output an XSL-FO document from your XSL
          FOP will not be able to produce any output.
          The '-txt' option says - Output my XSL-FO document as text.

          HTH

          Mike

          javier_azaola wrote:

          >Thanks Mike!
          >
          >I am trying it but the result is the same, i'm using fop-0.20.5. to
          >execute the action. Can fop execute this xsl file ?
          >
          >Goodbye!
          >
          >--- In XSL-FO@yahoogroups.com, Mike Ferrando <mikeferrando@y...>
          >wrote:
          >
          >
          >>Javier,
          >>When you are in the root template, you are technically NOT in an
          >>element yet, you cannot simply just ask for "." [everything].
          >>
          >>This is why the txt file is empty.
          >>
          >>Try this for a xsl:value-of
          >>
          >><xsl:template match="/">
          >> <xsl:value-of select="//K43PRINT"/>
          >></xsl:template>
          >>
          >>
          >>Mike Ferrando
          >>Library Technician
          >>Library of Congress
          >>Washington, DC
          >>202-707-4454
          >>
          >>
          >>--- javier_azaola <javier_azaola@y...> wrote:
          >>
          >>
          >>
          >>>Hi
          >>>
          >>>Xml:
          >>>
          >>><K43PRINT>
          >>><K43TABLE>
          >>><K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
          >>><K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
          >>><K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
          >>><K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
          >>><K43TR><K43TD>DE LA TORRE</K43TD></K43TR>
          >>></K43TABLE>
          >>></K43PRINT>
          >>>
          >>>Xsl:
          >>><xsl:stylesheet
          >>>
          >>>
          >xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
          >
          >
          >>>version="1.0">
          >>> <xsl:output method="text"/>
          >>> <xsl:template match="/" >
          >>> Element:<xsl:value-of select="."/>
          >>> </xsl:template>
          >>></xsl:stylesheet>
          >>>
          >>>Execute:
          >>>
          >>>fop -xml ejemplo.xml -xsl ejemplo.xsl -txt ejemplo.txt
          >>>
          >>>
          >>>Ejemplo.txt is an emtpy file, what is the problem?
          >>>
          >>>Thanks!!!
          >>>Eskerrikasko!!!
          >>>
          >>>
          >>>
          >>>
          >>>
          >>>
          >>>
          >>>
          >>>------------------------ Yahoo! Groups Sponsor
          >>>--------------------~-->
          >>>Get fast access to your favorite Yahoo! Groups. Make Yahoo! your
          >>>home page
          >>>http://us.click.yahoo.com/dpRU5A/wUILAA/yQLSAA/9rHolB/TM
          >>>
          >>>
          >>>
          >>-------------------------------------------------------------------
          >>
          >>
          >-~->
          >
          >
          >>>
          >>>Yahoo! Groups Links
          >>>
          >>>
          >>>
          >>>
          >>>
          >>>
          >>>
          >>>
          >>>
          >>>
          >>
          >>
          >>__________________________________
          >>Yahoo! Mail - PC Magazine Editors' Choice 2005
          >>http://mail.yahoo.com
          >>
          >>
          >
          >
          >
          >
          >
          >
          >
          >Yahoo! Groups Links
          >
          >
          >
          >
          >
          >
          >
          >Message Scanned by ClamAV on datalucid.com
          >
          >
          >

          --
          Datalucid Limited



          Message Scanned by ClamAV on datalucid.com
        • Prakash R
          I have the following fo: 123 xyz abc def
          Message 4 of 8 , Sep 27, 2005
            I have the following fo:

            <fo:block>123</fo:block>
            <fo:block>xyz</fo:block>
            <fo:block><fo:leader/></fo:block>
            <fo:block>abc</fo:block>
            <fo:block>def</fo:block>

            I want to put the leader only if it is not followed by
            a page break. Is there a way to determine if fo:leader
            is followed by page break?

            Thank you.
            Prakash

            __________________________________________________
            Do You Yahoo!?
            Tired of spam? Yahoo! Mail has the best spam protection around
            http://mail.yahoo.com
          • Victor Vishnyakov
            As far as I see you use the leader in the block to create a space between paragraphs. I would recommend you to use space-before and space-after attributes of
            Message 5 of 8 , Sep 27, 2005
              As far as I see you use the leader in the block to create a space between
              paragraphs. I would recommend you to use space-before and space-after
              attributes of the blocks to achieve the desired result.
              <space>.conditionality property controls if it should be discarded on the
              edge of the page.


              Best regards,
              Victor Vishnyakov
              http://xslfo-zone.com/



              > -----Original Message-----
              > From: XSL-FO@yahoogroups.com [mailto:XSL-FO@yahoogroups.com]
              > On Behalf Of Prakash R
              > Sent: Tuesday, September 27, 2005 12:09 PM
              > To: XSL-FO@yahoogroups.com
              > Subject: [XSL-FO] determine if fo:block is before page break
              >
              > I have the following fo:
              >
              > <fo:block>123</fo:block>
              > <fo:block>xyz</fo:block>
              > <fo:block><fo:leader/></fo:block>
              > <fo:block>abc</fo:block>
              > <fo:block>def</fo:block>
              >
              > I want to put the leader only if it is not followed by a page
              > break. Is there a way to determine if fo:leader is followed
              > by page break?
              >
              > Thank you.
              > Prakash
              >
              > __________________________________________________
              > Do You Yahoo!?
              > Tired of spam? Yahoo! Mail has the best spam protection
              > around http://mail.yahoo.com
              >
              >
              > ------------------------ Yahoo! Groups Sponsor
              > --------------------~-->
              > Get fast access to your favorite Yahoo! Groups. Make Yahoo!
              > your home page
              > http://us.click.yahoo.com/dpRU5A/wUILAA/yQLSAA/9rHolB/TM
              > --------------------------------------------------------------
              > ------~->
              >
              >
              > Yahoo! Groups Links
              >
              >
              >
              >
              >
              >
              >
            • Prakash R
              Actually I wanted a leader with rule i.e. not just some space. Prakash ...
              Message 6 of 8 , Sep 27, 2005
                Actually I wanted a leader with rule i.e.

                <fo:leader leader-pattern="rule"/>

                not just some space.

                Prakash

                --- Victor Vishnyakov <tch_@...> wrote:

                > As far as I see you use the leader in the block to
                > create a space between
                > paragraphs. I would recommend you to use
                > space-before and space-after
                > attributes of the blocks to achieve the desired
                > result.
                > <space>.conditionality property controls if it
                > should be discarded on the
                > edge of the page.
                >
                >
                > Best regards,
                > Victor Vishnyakov
                > http://xslfo-zone.com/
                >
                >
                >
                > > -----Original Message-----
                > > From: XSL-FO@yahoogroups.com
                > [mailto:XSL-FO@yahoogroups.com]
                > > On Behalf Of Prakash R
                > > Sent: Tuesday, September 27, 2005 12:09 PM
                > > To: XSL-FO@yahoogroups.com
                > > Subject: [XSL-FO] determine if fo:block is before
                > page break
                > >
                > > I have the following fo:
                > >
                > > <fo:block>123</fo:block>
                > > <fo:block>xyz</fo:block>
                > > <fo:block><fo:leader/></fo:block>
                > > <fo:block>abc</fo:block>
                > > <fo:block>def</fo:block>
                > >
                > > I want to put the leader only if it is not
                > followed by a page
                > > break. Is there a way to determine if fo:leader is
                > followed
                > > by page break?
                > >
                > > Thank you.
                > > Prakash
                > >
                > > __________________________________________________
                > > Do You Yahoo!?
                > > Tired of spam? Yahoo! Mail has the best spam
                > protection
                > > around http://mail.yahoo.com
                > >
                > >
                > > ------------------------ Yahoo! Groups Sponsor
                > > --------------------~-->
                > > Get fast access to your favorite Yahoo! Groups.
                > Make Yahoo!
                > > your home page
                > >
                >
                http://us.click.yahoo.com/dpRU5A/wUILAA/yQLSAA/9rHolB/TM
                > >
                >
                --------------------------------------------------------------
                > > ------~->
                > >
                > >
                > > Yahoo! Groups Links
                > >
                > >
                > >
                > >
                > >
                > >
                > >
                >
                >


                __________________________________________________
                Do You Yahoo!?
                Tired of spam? Yahoo! Mail has the best spam protection around
                http://mail.yahoo.com
              • J.Pietschmann
                ... Instead of a leader you should take advantage of the conditionality for borders. See the remarks regarding :
                Message 7 of 8 , Oct 1, 2005
                  Prakash R wrote:
                  > I have the following fo:
                  >
                  > <fo:block>123</fo:block>
                  > <fo:block>xyz</fo:block>
                  > <fo:block><fo:leader/></fo:block>
                  > <fo:block>abc</fo:block>
                  > <fo:block>def</fo:block>
                  >
                  > I want to put the leader only if it is not followed by
                  > a page break. Is there a way to determine if fo:leader
                  > is followed by page break?

                  Instead of a leader you should take advantage of the conditionality
                  for borders. See the remarks regarding <length-conditionality>:
                  http://www.w3.org/TR/xsl/slice7.html#border-before-width

                  J.Pietschmann
                Your message has been successfully submitted and would be delivered to recipients shortly.