Dynamic Header in Page Sequence [region-before]

2002-02-12 Thread Sharan, Dharmendra
Hi XSL FOP Developers,

  I want to ask if it is possible to have a dynamic Header implemented
in a Page-Sequence.

  something like ...


  fo:static-content flow-name=xsl-region-start
 fo:block font-size=16pt font-weight=bold
font-family=sans-serif
   xsl:text From: /xsl:text
   xsl:value-of select=@tableStart/
   xsl:text To: /xsl:text
   xsl:value-of select=@tableStart/
 /fo:block
  /fo:static-content


  fo:static-content flow-name=xsl-region-body

 !-- XSL FO code to process the xml goes here... --

 !-- This body content gets page header using the
xsl-region-start above --
 !-- Is is possible to have a different header for this/each page
--
 !-- depending on the data being processed eg. let's say we have a
xml having car schema --
 !-- would it be possible to have the page header vary depending on
the car detail being displayed ??? --
 !-- (assuming each car gets displayed on its own page i.e.
separate page for each car) --

  /fo:static-content


  Assuming an XML like :-

   Vehicle type=4 wheel drive

  car category=sedan
  !-- Car details here... --
  /car

  car category=sports
  !-- Car details here... --
  /car

   /Vehicle


   Any ideas ? Is there a better way to achieve the same results ? Any
helps/hints/suggestions appreciated.

   Thanks!,

   Dharmendra


Recall: Dynamic Header in Page Sequence [region-before]

2002-02-12 Thread Sharan, Dharmendra
Sharan, Dharmendra would like to recall the message, Dynamic Header in Page
Sequence [region-before].


Re: Pipe XSLT Transform to FOP

2002-02-12 Thread Bart Locanthi
Could anyone point me in the right direction of how I could transform
my XML to PDF without creating an intermediate file?
send your XML to a PipedOutputStream pos and use an 
InputSource(pos.getInputStream())

make your XML thing a Thread and start() it.



Re: Pipe XSLT Transform to FOP

2002-02-12 Thread Bertrand Delacretaz
On Tuesday 12 February 2002 02:00, Ryan Howe wrote:
 I have been looking for a way to pipe the output of my Transformer
 into the Input of the FOP Driver object. 

Cocoon (xml.apache.org/cocoon) does just that and much more - you might 
want to have a look!

-- 
 -- Bertrand Delacrétaz, www.codeconsult.ch
 -- web technologies consultant - OO, Java, XML, C++







RE: HTML to PDF using FOP

2002-02-12 Thread Michiel Verhoef
First: please use text only mails and NO backgrounds! They cause mails to be
unneccessary huge..

Now, wrt your question: yes, as long as you manage to convert the HTML to
fo.
If the HTML is well formed (so, in effect is XML) you may use XSLT,
otherwise
you need another programming language to do this for you.

Michiel


-Original Message-
From: Idrees Ali [mailto:[EMAIL PROTECTED]
Sent: dinsdag 12 februari 2002 16:43
To: [EMAIL PROTECTED]
Subject: HTML to PDF using FOP


Is it possible to convert HTML to PDF using fop.

Have a Nice One
 \|/
   (@ @)
 --oOO--(_)--OOo

  


Re: Dynamic Header in Page Sequence [region-before]

2002-02-12 Thread Chuck Paussa
Sharan,
You can use marker and retrieve marker. The header has to be variable 
depending on the contents of the page. Example follows. Retrieve marker 
retrieves whatever you put within the fo:marker tags. Those contents 
are not output on the page. Also, your code used region-start, you want 
region-before. You used static-content instead of fo:flow.

fo:static-content flow-name=xsl-region-before
fo:block font-size=16pt font-weight=bold font-family=sans-serif
xsl:text Car: /xsl:text
fo:retrieve-marker retrieve-class-name=car-category retrieve-boundary=page 
retrieve-position=first-starting-within-page/
/fo:block
/fo:static-content
fo:flow flow-name=xsl-region-body
xsl:for-each select=/car
fo:blockfo:marker marker-class-name=car-categoryxsl:value-of 
select=Car/@category//fo:marker
xsl:value-of select=@name/
. . .
/fo:block
/fo:flow
Chuck
Sharan, Dharmendra wrote:
Hi XSL FOP Developers,
 I want to ask if it is possible to have a dynamic Header implemented
in a Page-Sequence.
 something like ...
 fo:static-content flow-name=xsl-region-start
fo:block font-size=16pt font-weight=bold
font-family=sans-serif
  xsl:text Car: /xsl:text
  xsl:value-of select=Car/@category/
/fo:block
 /fo:static-content
 fo:static-content flow-name=xsl-region-body
!-- XSL FO code to process the xml goes here... --
!-- This body content gets page header using the
xsl-region-start above --
!-- Is is possible to have a different header for this/each page
--
!-- depending on the data being processed eg. let's say we have a
xml having car schema --
!-- would it be possible to have the page header vary depending on
the car detail being displayed ??? --
!-- (assuming each car gets displayed on its own page i.e.
separate page for each car) --
   
 /fo:static-content

 Assuming an XML like :-
  Vehicle type=4 wheel drive
 car category=sedan
 !-- Car details here... --
 /car
 car category=sports
 !-- Car details here... --
 /car
  /Vehicle
  Any ideas ? Is there a better way to achieve the same results ? Any
helps/hints/suggestions appreciated.
  Thanks!,
  Dharmendra




RE: HTML to PDF using FOP

2002-02-12 Thread Bruno VERNAY
Title: RE: HTML to PDF using FOP





You should take a look at the Docbook project : http://docbook.org/
They provide XSL to publish XML sources in many format : HTML, XHTML, FO, PDF, PS ...





Re: sax conflicts with tomcat-4.0.2-LE-jdk1.4

2002-02-12 Thread Joerg Pietschmann
Jeremias Maerki [EMAIL PROTECTED] wrote:
 The only place where Xerces is directly imported is the PFMReader and
 TTFReader. Ok, Driver, when startet using the command line, uses Xerces
 by default, but nothing prevents you from using any JAXP parser with FOP.

Stuff matching org.apache.x* in 0.20.2:
...Driver.java
  parserClassName = org.apache.xerces.parsers.SAXParser;
...PFMReader.java
  org.apache.xerces.dom.*;
  org.apache.xml.serialize.*;
  org.apache.xalan.xslt.*;
...TTFReader.java
  dto.
...fop.layout.hyphenation.PatternParser.java
  parserClassName = org.apache.xerces.parsers.SAXParser;
...fop.tools.anttasks.CompileXMLFiles.java
  parserClassName = org.apache.xerces.parsers.SAXParser;
...fop.tools.xslt.Xalan1Transform.java
  org.apache.xalan.xslt.*;
...fop.tools.xslt.XSLTransform.java
  Class.forName(org.apache.xalan.xslt.XSLTProcessor);

I believe all this stuff could be replaced by JAXP 1.1 standard
functionality. This means FOP could also be build with any JAXP
1.1 compatible XML/XSL library.
This would also get rid of some unfortunate dependencies from
Driver.getParserClassName() (why not use
  SAXParserFactory.newSAXParser().getXMLReader()
instead and let the library handle all the annoying stuff? At
the same time, validation could be switched off, gaining some
performance in rare cases).
I could try to prepare patches, however:
- Is there a chance to get them into the maintenance branch?
  (there is a feature freeze pending, AFAIK)
- Last time i tried i was not able to build FOP successfully,
  because of an odd ant incompatibility problem i didn't (and
  still don't) have time to resolve. This means i can only try
  basic compilation, someone else would have to finalize the
  patch.


(Crossposted to fop-dev)

Regards
J.Pietschmann


Re: Getting system-time

2002-02-12 Thread Costantino Sertorio

meena,
do you want to measure the xsl-fo transformation time? then you might use
fop with the -d option, which outputs it with some other data.
costantino




 
Chuck Paussa
 
[EMAIL PROTECTED]To: [EMAIL PROTECTED] 
 
s.dhl.com  cc: 
 
Subject: Re: Getting 
system-time 
12.02.2002 16:56
 
Please respond to   
 
fop-user
 

 

 




Meena,

You'll have to use an XSL extension function and use an XSL processor that
implements that function.

The most standard date implementation is the one offered by EXSLT.


xsl:stylesheet version=1.0
xmlns:xsl=http://www.w3.org/1999/XSL/Transform;
xmlns:date=http://exslt.org/dates-and-times;
extension-element-prefixes=date
. . .
xsl:value-of select=date:date-time()/

The only xsl processor that implements this internally that I know of is
Saxon by Mike Kay


Chuck
Meena wrote:
 Hi,
 Is there anyway to find the time taken to run an xsl file(something
 that will give the overall time for execution at the end of completion
 of the program)

 Regds,
 Meena


 **Disclaimer




 Information contained in this E-MAIL being proprietary to Wipro
 Limited
 is 'privileged' and 'confidential' and intended for use only by the
 individual or entity to which it is addressed. You are notified that
 any
 use, copying or dissemination of the information contained in the
 E-MAIL
 in any manner whatsoever is strictly prohibited.



  







Making FO

2002-02-12 Thread Aleksei Vassiljev



Hi all

Does anybody know any good tool for 
convertingHTML (or rtf, or doc) to FO.
I have tried html2fo, which I had found on 
sourceforge.net, but it doesn't understand styles and some tags.
Maybe anybody know a better tool?

Aleksei Vassiljev



Re: HTML to PDF using FOP

2002-02-12 Thread Idrees Ali
Major problem i found is converting the table tag cause fop requires you to
define the column size before you use it and if i am using html just looking
at it i cannot figure out how many columns i have for the table.

Any idaeas how to do with XSL.

- Original Message -
From: Michiel Verhoef [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, February 12, 2002 10:45 AM
Subject: RE: HTML to PDF using FOP


 First: please use text only mails and NO backgrounds! They cause mails to
be
 unneccessary huge..

 Now, wrt your question: yes, as long as you manage to convert the HTML to
 fo.
 If the HTML is well formed (so, in effect is XML) you may use XSLT,
 otherwise
 you need another programming language to do this for you.

 Michiel


 -Original Message-
 From: Idrees Ali [mailto:[EMAIL PROTECTED]
 Sent: dinsdag 12 februari 2002 16:43
 To: [EMAIL PROTECTED]
 Subject: HTML to PDF using FOP


 Is it possible to convert HTML to PDF using fop.

 Have a Nice One
  \|/
(@ @)
  --oOO--(_)--OOo





Re: Making FO

2002-02-12 Thread Idrees Ali



I just came to know about HTMLdoc which 
will convert your html to pdf without using any fo. if you are interested check 
following site

http://www.easysw.com/htmldoc
- Original Message - 

  From: 
  Aleksei 
  Vassiljev 
  To: [EMAIL PROTECTED] 
  Sent: Tuesday, February 12, 2002 12:55 
  PM
  Subject: Making FO
  
  Hi all
  
  Does anybody know any good tool for 
  convertingHTML (or rtf, or doc) to FO.
  I have tried html2fo, which I had found on 
  sourceforge.net, but it doesn't understand styles and some tags.
  Maybe anybody know a better tool?
  
  Aleksei Vassiljev
  


Re: Making FO

2002-02-12 Thread Bart Locanthi
xslt was created for doing just this. it's a very important technology 
and there are finally some good books on it.

Does anybody know any good tool for converting HTML (or rtf, or doc) 
to FO.

I have tried html2fo, which I had found on sourceforge.net, but it 
doesn't understand styles and some tags.

Maybe anybody know a better tool?
 

Aleksei Vassiljev
 





Re: text-align centered not working?

2002-02-12 Thread Stephen Clarke
Hi Cristoph, Magnus and Jay,
Thanks for taking the trouble to help a new newbie. That worked fine. For a
moment there I almost flipped. {:-)
--
Best,
Stephen

- Original Message -
From: S. Jayaraman [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, February 12, 2002 3:41 PM
Subject: AW: text-align centered not working?


 Hi
 Try text-align=center





Borders not displaying

2002-02-12 Thread Stephen Clarke
Hi again,
For my next question, can anyone tell me what could be wrong with the
following. It doesn't seem to display any borders. Is this a problem with
FOP or with me? I've followed the reference manual as closely as I can.

  fo:block border-before-color=blue border-before-width=2px
border-after-color=blue  border-after-width=2px
border-start-color=blue  border-start-width=2px
border-end-color=blueborder-end-width=2px
You have been selected for special high intensity training.
  /fo:block

Grateful for any assistance. Many thanks.
--
Best,
Stephen




How to use keep-together?

2002-02-12 Thread Stephen Clarke
Hi,
Sorry to bother you all again. This should be the last question for a while.
I've been trying to get keep-together=always to work. I've tried it on
blocks, inlines and on blocks surrounding blocks. Nothing seems to make any
difference, yet the FOP parser doesn't complain about the code. Again, I
just want to know whether it's me or FOP. This would be a very nice feature
to have implimented in FOP. It *does* seem to be in the pdf documentation
that came with FOP.

Just for completeness, here's some code I'm trying.

   block keep-together=always space-after=0.5emThis is a test with
keep-together
   inline keep-together=always
Indignor quicquam reprehendi, non quia crasse compositum illepedeve putetur,
sed quia nuper, nec veniam antiquis, sed honorem et praemia posci. Recte
necne crocum floresque perambulet Attae fabula si dubitem, clament periisse
pudorem cuncti paene patres, ea cum reprehendere coner, quae gravis Aesopus,
quae doctus Roscius egit; vel quia nil rectum, nisi quod placuit sibi,
ducunt, vel quia turpe putant parere minoribus, et quae imberbes senes.
   /inline
   /block

It just carries on splitting regardless.
( 
Any ideas?
--
Best,
Stephen