Re: FOP character mapping problems

2003-04-25 Thread J.Pietschmann
Clay Leeds wrote:
FMI: Is that like regular, Bold, Italic, and Bold Italic?
I've seen TTCs mainly for providing several writing styles, sort of,
for e.g. chinese. The concept is not unlikely the concept of
character slant in western scripts; it covers for example variations
in line caps, line width changes along lines, gaps and bends. In such
cases the fonts in the TTC have related but different names.
Occasionally I've seen completely unrelated fonts in one TTC. I don't
really know whether TTCs are just concatenations of TTFs with a common
header or whether the fonts may share structures like code tables or
glyph definitions. Jeremias will tell you.
J.Pietschmann
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: PDF Conversion

2003-04-25 Thread amit kaushik
this is true that the order of the argument doesn't matter but the problem
still persist. Please help me on that,

thanks


- Original Message -
From: J.Pietschmann [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, April 24, 2003 11:47 PM
Subject: Re: PDF Conversion


 Clay Leeds wrote:
  I think you have your arguments in the wrong order. I'm not sure if it
  matters,

 Option order on the command line *doesn't* matter. Order is only
 significant if the defaults -fo and -pdf are omitted:
 This works
fop foo.fo foo.pdf
 This won't work
fop foo.pdf foo.fo
 Any option can be placed anywhere, all of the following is ok:
fop -d foo.fo foo.pdf
fop foo.fo -d foo.pdf
fop foo.fo foo.pdf -d

 J.Pietschmann


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: can I?

2003-04-25 Thread Oleg Tkachenko
joni santoso wrote:
I usually use fop to convert fo to pdf using command line.
Now, I wonder if I can use fop programatically to take streamed fo 
object (not from files) and convert it to pdf (what objects to use?)
Sure you can.
Look at http://xml.apache.org/fop/embedding.html
--
Oleg Tkachenko
http://www.tkachenko.com/blog
Multiconn Technologies, Israel
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: HTML render class available?

2003-04-25 Thread amit kaushik
Hi Christian,

here is a XSL to render XML in to FO.
http://www-106.ibm.com/developerworks/library/x-xslfo2app/xhtml-to-xslfo.xsl

i hope this will help you.

Amit Kaushik


- Original Message -
From: Christian Neuroth [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, April 25, 2003 3:20 PM
Subject: HTML render class available?


 Hi!

 As I am a newbie to FOP, I am not sure whether my post makes sense or not.

 I really enjoy working with FOP: I use one XSL-FO sheet to generate plain
 text,
 PDF and even SVG documents. The resulting docs have the same layout. Since
 the layout is very complex, we require that the layout is configured in
only
 one
 XSL-FO stylesheet.

 The only thing that I am missing, is a render class for HTML as we are
also
 in need of a HTML doc. Does anyone have a solution for this?

 Regards + Thanks!

 Christian


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTML render class available?

2003-04-25 Thread Christian Neuroth
Hi!

Thanks for your fast reply, Amit. However, what I was looking for was a way
to transform XML into HTML with the help of FOP.

Until now, I can do XML-PDF, XML-PS, XML-SVG, because there are render
classes for those document types... I am looking for a subclass of
org.apache.fop.render.AbstractRenderer, which supports the transformation of
XML into HTML. This would be great because I would then only have one XSL-FO
sheet, which is used for all desired document formats.

Thanks,

Christian

 here is a XSL to render XML in to FO.

http://www-106.ibm.com/developerworks/library/x-xslfo2app/xhtml-to-xslfo.xsl

 i hope this will help you.

 Amit Kaushik


 - Original Message -
 From: Christian Neuroth [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Friday, April 25, 2003 3:20 PM
 Subject: HTML render class available?


  Hi!
 
  As I am a newbie to FOP, I am not sure whether my post makes sense or
not.
 
  I really enjoy working with FOP: I use one XSL-FO sheet to generate
plain
  text,
  PDF and even SVG documents. The resulting docs have the same layout.
Since
  the layout is very complex, we require that the layout is configured in
 only
  one
  XSL-FO stylesheet.
 
  The only thing that I am missing, is a render class for HTML as we are
 also
  in need of a HTML doc. Does anyone have a solution for this?
 
  Regards + Thanks!
 
  Christian
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: block-containers and absolute positioning

2003-04-25 Thread David Neary


De : J.Pietschmann [mailto:[EMAIL PROTECTED]
 David Neary wrote:
fo:block-container font-size=20pt text-align-last=center
  fo:block left=0pt top=0pt width=20mm height=20mm 
position=absolute
 
 Specifying position on fo:block has no effect in FOP, it only works on
 fo:block-container. You have to use two containers:

Thanks a lot - that works great, and has given bme a much better idea of
what's happening.

Dave Neary.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTML render class available?

2003-04-25 Thread Christian Neuroth
 your xsl stylesheet can contain:
 table
 tr
 tdxsl:value-of select=something_in_your_xml//td
 /tr
 table

 the resultig FO is:
 table
 tr
 tdThatsTheDataFromXML/td
 /tr
 table

 DONE

yep. I understand that I can create a XSL stylesheet like your example. But
I try to write a Java application which simply switches between different
render classes to realize different output formats:

// Setup renderer (output format)
driver.setRenderer(Driver.RENDER_PDF);

The only thing that I have to change is the parameter for the setRenderer
method. There are renderer available for SVG, PDF, PS, PCL and so on.
However, not for HTML. And I am looking for someone, who perhaps did
implement a renderer for HTML or has some useful hints how I can do this.

Thanks.

Christian



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTML render class available?

2003-04-25 Thread William Gilbert
 yep. I understand that I can create a XSL stylesheet like your example. But
 I try to write a Java application which simply switches between different
 render classes to realize different output formats:
 
   // Setup renderer (output format)
   driver.setRenderer(Driver.RENDER_PDF);
 
 The only thing that I have to change is the parameter for the setRenderer
 method. There are renderer available for SVG, PDF, PS, PCL and so on.
 However, not for HTML. And I am looking for someone, who perhaps did
 implement a renderer for HTML or has some useful hints how I can do this.

I agree with both. Up to now I generate HTML vis XSL and PDF via XSL-FOP.
Fortunately, my incoming XSL is very HTML-like, where it isn't I write a
custom XSL transform.

However, it would be nice to have an HTML output from the FO Processor in
order to minimize the amount of custom work to be done per project.  If the
client then request 'better' HTML then write it and bill 'em for it.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: HTML render class available?

2003-04-25 Thread Torsten Erler
No I don't think that anyone has written this Renderer, because you've to
translate the whole fo-reference back into html syntax, which would be like
a shot from the back through the breast into the eye.

You can try to write it, but before take a look at
http://www.w3.org/TR/xsl/slice7.html

Each generated FO tag/property has to be translated and replaced by html
tags for outputting.
Have fun ;)

cu Torsten

 -Original Message-
 From: Christian Neuroth [mailto:[EMAIL PROTECTED]
 Sent: Freitag, 25. April 2003 14:18
 To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Subject: Re: HTML render class available?


  your xsl stylesheet can contain:
  table
  tr
  tdxsl:value-of select=something_in_your_xml//td
  /tr
  table
 
  the resultig FO is:
  table
  tr
  tdThatsTheDataFromXML/td
  /tr
  table
 
  DONE

 yep. I understand that I can create a XSL stylesheet like
 your example. But
 I try to write a Java application which simply switches
 between different
 render classes to realize different output formats:

 // Setup renderer (output format)
 driver.setRenderer(Driver.RENDER_PDF);

 The only thing that I have to change is the parameter for the
 setRenderer
 method. There are renderer available for SVG, PDF, PS, PCL and so on.
 However, not for HTML. And I am looking for someone, who perhaps did
 implement a renderer for HTML or has some useful hints how I
 can do this.

 Thanks.

 Christian



 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTML render class available?

2003-04-25 Thread William Gilbert
 I agree with both. Up to now I generate HTML vis XSL and PDF via XSL-FOP.
 Fortunately, my incoming XSL is very HTML-like, where it isn't I write a
 custom XSL transform.

Boo-boo...  Line two should read XML not XSL:

I agree with both. Up to now I generate HTML vis XSL and PDF via XSL-FOP.
Fortunately, my incoming XML is very HTML-like, where it isn't I write a
custom XSL transform.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



AW: HTML render class available?

2003-04-25 Thread Sam Prokop
http://www.renderx.com/fo2html.html

Some Guys from RenderX have written an XSL, which does just that.

You can give it a try, but the produced html is not the best.


 -Ursprüngliche Nachricht-
 Von: William Gilbert [mailto:[EMAIL PROTECTED] 
 Gesendet: Freitag, 25. April 2003 14:35
 An: [EMAIL PROTECTED]
 Betreff: Re: HTML render class available?
 
 
  I agree with both. Up to now I generate HTML vis XSL and PDF via 
  XSL-FOP. Fortunately, my incoming XSL is very HTML-like, where it 
  isn't I write a custom XSL transform.
 
 Boo-boo...  Line two should read XML not XSL:
 
 I agree with both. Up to now I generate HTML vis XSL and PDF 
 via XSL-FOP. Fortunately, my incoming XML is very HTML-like, 
 where it isn't I write a custom XSL transform.
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: squere instead of bullet in lists?

2003-04-25 Thread Chris Bowditch
From: anton [EMAIL PROTECTED]
Hi!
I wish to use square insteed of bullet. In the Norms Stylesheet they are
commentde out, 'cause they not shown in PDF correct:
!-- why do these symbols not work? --
  !--
  xsl:when test=$itemsymbol='circle'#8728;/xsl:when
  xsl:when test=$itemsymbol='round'#8728;/xsl:when
  xsl:when test=$itemsymbol='square'#9744;/xsl:when
  xsl:when test=$itemsymbol='box'#9744;/xsl:when
  --
When you say doesnt work, what are the symptoms? Do you see # in the 
resulting PDF? You need to make sure the current font contains glyphs for 
the code points you mentioned. Check which font you are using.

Chris
_
Worried what your kids see online? Protect them better with MSN 8 
http://join.msn.com/?page=features/parentalpgmarket=en-gbXAPID=186DI=1059

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: HTML render class available?

2003-04-25 Thread Ralf Butterweck

There is a XSLT-stylesheet for FO-HTML transformation:
  http://www.renderx.com/fo2html.html

first step:   XML+XSL-FO
second step: FO +XSL  -HMTL

Hope thats help


Date sent:  Fri, 25 Apr 2003 11:50:14 +0200
From:   Christian Neuroth [EMAIL PROTECTED]
Subject:HTML render class available?
To: [EMAIL PROTECTED]
Send reply to:  [EMAIL PROTECTED]

 Hi!
 
 As I am a newbie to FOP, I am not sure whether my post makes sense or not.
 
 I really enjoy working with FOP: I use one XSL-FO sheet to generate plain
 text, PDF and even SVG documents. The resulting docs have the same layout.
 Since the layout is very complex, we require that the layout is configured in
 only one XSL-FO stylesheet.
 
 The only thing that I am missing, is a render class for HTML as we are also in
 need of a HTML doc. Does anyone have a solution for this?
 
 Regards + Thanks!
 
 Christian
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



object administration in a fo:table

2003-04-25 Thread Todtenhaupt, Susann
Hello!

I've tried to put a fo:block-container into a fo:table-cell. Furthermore
this container holds another fo:block-container with some blocks in it. But
in my PDF the first container collapsed and attributes like height didn't
work. In HTML it's possible to have objects in a table and the table renders
the necessary design. 

Thanx suse


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



AW: squere instead of bullet in lists?

2003-04-25 Thread anton
Hi!


When you say doesnt work, what are the symptoms? Do you see # in the
resulting PDF? You need to make sure the current font contains glyphs for
the code points you mentioned. Check which font you are using.


It works after J.Pietschmanns tip fine, thanks. I don't know exactly why
this mail was sended twice. Sorry for the trouble.


CU
Anton


smime.p7s
Description: S/MIME cryptographic signature


AW: Number alignment in TOC

2003-04-25 Thread anton
Hi!


The problem is already fixed, but the code is not yet released.
You can get it from CVS, see
  http://xml.apache.org/fop/download.html
Be sure to get the code from the maintenance branch:
  http://xml.apache.org/fop/dev/index.html#lines


So, i get the sources and compiled it with the newest SDK under Windows.
There were no errors but when i wish to render my fo-File, i get the
following errot:

Exception in thread main java.lang.NoClassDefFoundError:
org/apache/fop/apps/Fop

I checked the generated file fop.jar, the class is there and the path's
seems to be OK too. The Path to the fop.jat in my bath files must be also
correct, cause i overwrite the old fop.jar with the new version.

There was generated another file too, not sure about the exact name,
something like pdf-transformer.jar, for what ist this file to use?


CU
Anton


smime.p7s
Description: S/MIME cryptographic signature


newbie help on error message

2003-04-25 Thread Eric Pement
warningNewbie alert/warning

I've been given the assignment of generating .PDFs from .XML files.
So I've installed FOP, and had it working mostly successfully from
the command line (i.e., the /fop/examples/fo will compile).

What I need to do now is to create an .XSL file, which will create the
.FO file ... and you know the rest. Problem is, I didn't write the .XML
file and I'm at a novice level in all of this. So I'd like to build the
.XSL file incrementally, seeing if I can print single tags from the .XML
file, and then successively adding tags until I have a generalized
solution that will work on whatever .XML file we feed it which obeys
the given schema.

Right now, I'm getting an error message, fo:flow must contain block-level
children, which I don't know what to do with.  My input xsl code is this
(with nonessentials removed):

  fo:flow flow-name=xsl-region-body
  xsl:apply-templates select=Title /
  /fo:flow

  . . .

  xsl:template match=[EMAIL PROTECTED]'title_1']
fo:block
  font-size=24pt line-height=28pt text-align=start
  font-family=Helvetica font-weight=bold color=blue
  space-after.optimum=12pt
  xsl:value-of select=Title /
/fo:block
  /xsl:template

I want to insert the value of the Title tag if there is a
t_style attribute of title_1.  And as you might guess, later
on if the attribute says title_2, I select a different font
size, color, and so forth.

I don't know why this error message is occurring, since I think
the block-level children are invoked by the match. I would
also like some pointers, web links or ideas on building an
.XSL file in stages, since I seem to be failing even on the
first steps. Thanks in advance.


-- 
Eric Pement - [EMAIL PROTECTED]
Education Technical Services, MBI


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: FOP character mapping problems

2003-04-25 Thread Victor Mote
J.Pietschmann wrote:

 TTC files are basically a bunch of TTF fonts lumped together in one
 file.

I just committed a note to this effect to the font embedding section in the
documentation to clarify this for future users.

Victor Mote


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: PDF Conversion

2003-04-25 Thread Victor Mote
amit kaushik wrote:

 this is true that the order of the argument doesn't matter but the problem
 still persist. Please help me on that,

Usual practice on this list is to submit bare-minimum FO input:
http://xml.apache.org/fop/gethelp.html#user-mailing-list

Your problem looks like it is at the transformation stage, which means that
it is failing in the process of creating the FO, and is upstream of FOP's
core processing, and is therefore outside the scope of support usually
available on this list.

Start by running the transformation separately:
http://xml.apache.org/fop/running.html#running_xalan

We expect that to fail. You can probably track down the problem by using a
binary approach in your XSL file. (Comment out half of it  see which half
causes the failure. Repeat in the half that causes the failure until you
have it narrowed down enough to see the problem). If that doesn't help, try
the same thing with the XML file, since you could have an encoding problem.

Another possibility is to run the transformation using a different XSLT
engine, which might give better diagnostics. It could also be a bug in
Xalan.

Victor Mote


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: HTML render class available?

2003-04-25 Thread Victor Mote
Christian Neuroth wrote:

 As I am a newbie to FOP, I am not sure whether my post makes sense or not.

 I really enjoy working with FOP: I use one XSL-FO sheet to generate plain
 text,
 PDF and even SVG documents. The resulting docs have the same layout. Since
 the layout is very complex, we require that the layout is
 configured in only
 one
 XSL-FO stylesheet.

 The only thing that I am missing, is a render class for HTML as
 we are also
 in need of a HTML doc. Does anyone have a solution for this?

HTML is fundamentally different from FOP's other output formats, most of
which are paginated -- HTML is not. FOP does support MIF  RTF output
(neither of these renderers is robust right now), both of which are
structural, like HTML, but there is a big difference -- both are much more
complex than HTML, and it makes some sense to hide that complexity from
users. One could write an HTML renderer for FOP, but the results would
probably not be satisfactory. It really makes more sense to use a separate
transformation to convert your XML directly to HTML. This will, I think,
give you an order of magnitude more flexibility than anything you could get
by passing the whole thing through FOP. I think you could structure your
stylesheets to share the things that need to be common between them.

Victor Mote


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Number alignment in TOC

2003-04-25 Thread Victor Mote
anton wrote:

 So, i get the sources and compiled it with the newest SDK under Windows.
 There were no errors but when i wish to render my fo-File, i get the
 following errot:

 Exception in thread main java.lang.NoClassDefFoundError:
 org/apache/fop/apps/Fop

 I checked the generated file fop.jar, the class is there and the path's
 seems to be OK too. The Path to the fop.jat in my bath files must be also
 correct, cause i overwrite the old fop.jar with the new version.

It looks like the fop.jar file is not in your CLASSPATH. See:
http://xml.apache.org/fop/running.html#Starting+FOP+as+a+standalone+applicat
ion.
The usual practice would be to run either fop.bat or fop.sh to get all of
the correct settings. If you need to do something different, review those
scripts to make sure your solution covers all of the necessary steps.

Victor Mote


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: HTML render class available?

2003-04-25 Thread Partridge, Michael
I would also like the HTML renderer so I could create one stylesheet w/
embedded xsl:fo that could be used to create both PDF and HTML output.
This would make format changes easy as they would only have to be made
in one place instead of in each format's template, as I'll probably have
to do it. 

Mike

-Original Message-
From: Victor Mote [mailto:[EMAIL PROTECTED] 
Sent: Friday, April 25, 2003 12:43 PM
To: [EMAIL PROTECTED]
Subject: RE: HTML render class available?


Christian Neuroth wrote:

 As I am a newbie to FOP, I am not sure whether my post makes sense or
not.

 I really enjoy working with FOP: I use one XSL-FO sheet to generate
plain
 text,
 PDF and even SVG documents. The resulting docs have the same layout.
Since
 the layout is very complex, we require that the layout is
 configured in only
 one
 XSL-FO stylesheet.

 The only thing that I am missing, is a render class for HTML as
 we are also
 in need of a HTML doc. Does anyone have a solution for this?

HTML is fundamentally different from FOP's other output formats, most of
which are paginated -- HTML is not. FOP does support MIF  RTF output
(neither of these renderers is robust right now), both of which are
structural, like HTML, but there is a big difference -- both are much
more
complex than HTML, and it makes some sense to hide that complexity from
users. One could write an HTML renderer for FOP, but the results would
probably not be satisfactory. It really makes more sense to use a
separate
transformation to convert your XML directly to HTML. This will, I think,
give you an order of magnitude more flexibility than anything you could
get
by passing the whole thing through FOP. I think you could structure your
stylesheets to share the things that need to be common between them.

Victor Mote


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTML render class available?

2003-04-25 Thread Clay Leeds
 Christian Neuroth wrote:
The only thing that I am missing, is a render class for HTML as
we are also
in need of a HTML doc. Does anyone have a solution for this?

Ralph Butterweck's explanation pretty much nailed it (note the link to
RenderX's fo2html stylesheet page):

 There is a XSLT-stylesheet for FO-HTML transformation:
   http://www.renderx.com/fo2html.html
 
 first step:   XML+XSL-FO
 second step: FO +XSL  -HMTL
 
 Hope thats help

Having never done XML=HTML before, these two simple steps worked
surprisingly well for me. Here's how I transformed my XML  XSL files
into HTML using the xalan.bat file included (thanks!) with FOP (watch wrap):

NOTE: xalan command line arguments:
xalan.bat -in XML-IN-FILE -xsl XSLFILE -out OUTFILE

*-=- STEP 1 -=-*
C:\PROGRA~1\Java\FOP-02~1.4
xalan.bat -in c:\path\to\xml\test_MIWC_1.2.XML -xsl
c:\path\to\xsl\xml_med7_MIWC.fo -out test_MIWC_1.2.fo

*-=- STEP 2 -=-*
C:\PROGRA~1\Java\FOP-02~1.4
xalan.bat -in c:\path\to\xml\test_MIWC_1.2.fo -xsl
c:\path\to\xsl\fo2html.xsl -out test_MIWC_1.2.html


Like the results from using FOP to transform XML to -txt (not really
that useful), the result is not generally desirable, however, it
provided output that was at least somewhat useful. I could certainly
tweak the output a bit and make it pretty.

I doubt it would take much to have FOP do this (in theory at least ;-p),
but you can already use XALAN to use this, so why bother. The argument
against doing this is similar to the argument against having FOP output
the *.fo file used to output the PDF (something else for which xalan is
useful).

-- 
Clay Leeds - [EMAIL PROTECTED]
Web Developer - Medata, Inc. - http://www.medata.com
PGP Public Key: https://mail.medata.com/pgp/cleeds.asc


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: HTML render class available?

2003-04-25 Thread Adam Shelley
Unfortuneately, as victor noted html is not designed to be a printed medium.
Its purpose is out side the scope out of FOP.  You can do this with your
embedded program by using one of the FO-XHTML links that was mentioned but
this will be slower than if you just transformed it once.  The actual HTML
renderer (your web browser) isn't capable of knowing about pages and page
flows (there is nothing in the specifications that allow this).  What you
may want to do is base your documents on XHTML before the FO process and
start from the html output.  This will eliminate the need for the extra
steps.

-Adam

-Original Message-
From: Partridge, Michael [mailto:[EMAIL PROTECTED]
Sent: April 25, 2003 10:55 AM
To: [EMAIL PROTECTED]
Subject: RE: HTML render class available?


I would also like the HTML renderer so I could create one stylesheet w/
embedded xsl:fo that could be used to create both PDF and HTML output.
This would make format changes easy as they would only have to be made
in one place instead of in each format's template, as I'll probably have
to do it.

Mike



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: newbie help on error message

2003-04-25 Thread Victor Mote
Eric Pement wrote:

 file and I'm at a novice level in all of this. So I'd like to build the
 .XSL file incrementally, seeing if I can print single tags from the .XML
 file, and then successively adding tags until I have a generalized
 solution that will work on whatever .XML file we feed it which obeys
 the given schema.

That is a sound approach.

 Right now, I'm getting an error message, fo:flow must contain block-level
 children, which I don't know what to do with.  My input xsl code is this
 (with nonessentials removed):

   fo:flow flow-name=xsl-region-body
   xsl:apply-templates select=Title /
   /fo:flow

   . . .

   xsl:template match=[EMAIL PROTECTED]'title_1']
 fo:block
   font-size=24pt line-height=28pt text-align=start
   font-family=Helvetica font-weight=bold color=blue
   space-after.optimum=12pt
   xsl:value-of select=Title /
 /fo:block
   /xsl:template

 I want to insert the value of the Title tag if there is a
 t_style attribute of title_1.  And as you might guess, later
 on if the attribute says title_2, I select a different font
 size, color, and so forth.

I'm no XSLT expert, so your approach might be OK. However I would recommend
making your template match = Title, then putting an xsl:if inside the
template to deal with the difference in attributes, perhaps by pointing to
separate templates for the two styles.

 I don't know why this error message is occurring, since I think
 the block-level children are invoked by the match. I would
 also like some pointers, web links or ideas on building an
 .XSL file in stages, since I seem to be failing even on the
 first steps. Thanks in advance.

You will benefit first from looking at this page:
http://xml.apache.org/fop/running.html#running_xalan

By using the xalan script, you can store  later look at the actual FO code
that is created by the transformation. This will tell you whether your
stylesheet actually did what you intended.

Also, check out:
http://xml.apache.org/fop/resources.html#specs and
http://xml.apache.org/fop/resources.html#articles

Victor Mote


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



FO/FOP for modifiable fields

2003-04-25 Thread sanjeet1973
Hi,

This might be a silly question, but I'd like to know
if it is possible to create a modifiable field on the
resulting PDF document. Is there any way I can tell
the FOP, through an attribute may be, to create a
field that can be modified by the user should he have
to?

Thanks in advance for your response. 

best,
Sanjeet.

__
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo
http://search.yahoo.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Unknown formatting object

2003-04-25 Thread Willis, Matthew
Title: Unknown formatting object





Hi,


I'm getting the following exception:


WARNING: Unknown formatting object http://www.w3.org/1999/XSL/Transform^stylesheet
org.apache.fop.apps.FOPException


when running the following code snippet to set up an embedded FOP:


Driver fopDriver = new Driver(new InputSource(XSL_FO_FILE_PATH), new FileOutputStream(OBI_PDF_PO_FILE_PATH));
fopDriver.setRenderer(Driver.RENDER_PDF);
fopDriver.run();


While researching the problem, I found in one of the FOP FAQ's that receiving something like this error means that I need to check that the xsl namespace is set to http://www.w3.org/1999/XSL/Transform. I've double-checked this and it appears to be set correctly (see below).

xsl:stylesheet version=1.0
 xmlns:xsl=http://www.w3.org/1999/XSL/Transform
 xmlns:fo=http://www.w3.org/1999/XSL/Format


Anyone have any clues?


Here are the versions I'm using for the various jars:


xalan 2.0.0
xerces 1.2.3
fop 0.18 DEV


Running fop at the command line works fine with these. Running it embedded on the other hand...


Regards,
Matt




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

RE: Unknown formatting object

2003-04-25 Thread Adam Shelley
Title: Unknown formatting object



Sounds like you 
are taking a .xsl file and doing xsl-output format here. FOP 
only understands FO. You have to translate all your xsl files to xml(fo) 
before trying to translate it to your output format.

fop -xsl 
xslfile.xsl -xml xmlfile.xml pdf.pdf

Your xsl file is 
not to output anythign except fo. Try using the xslt processor to 
translate your xml/xsl to fo and review it to make sure that no xsl elements are 
left.

-Adam

-Original Message-From: Willis, 
Matthew [mailto:[EMAIL PROTECTED]Sent: April 25, 2003 12:28 
PMTo: '[EMAIL PROTECTED]'Cc: Willis, 
MatthewSubject: Unknown formatting object

  Hi, 
  I'm getting the following exception: 
  WARNING: Unknown formatting object http://www.w3.org/1999/XSL/Transform^stylesheet 
  org.apache.fop.apps.FOPException 
  when running the following code snippet to set up 
  an embedded FOP: 
  Driver fopDriver = new Driver(new 
  InputSource(XSL_FO_FILE_PATH), new 
  FileOutputStream(OBI_PDF_PO_FILE_PATH)); fopDriver.setRenderer(Driver.RENDER_PDF); fopDriver.run(); 
  While researching the problem, I found in one of 
  the FOP FAQ's that receiving something like this error means that I need to 
  check that the xsl namespace is set to http://www.w3.org/1999/XSL/Transform. I've double-checked this and it appears to be set correctly 
  (see below).
  xsl:stylesheet version="1.0"  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"  xmlns:fo="http://www.w3.org/1999/XSL/Format" 
  Anyone have any clues? 
  Here are the versions I'm using for the various 
  jars: 
  xalan 2.0.0 xerces 1.2.3 fop 0.18 DEV 

  Running fop at the command line works fine with 
  these. Running it embedded on the other hand... 
  Regards, Matt 


AW: Number alignment in TOC

2003-04-25 Thread anton
Hi!


The usual practice would be to run either fop.bat or fop.sh to get all of
the correct settings. If you need to do something different, review those
scripts to make sure your solution covers all of the necessary steps.


I try it at home, cause' at work i don't have many right's on the system.

And I get following error:

[INFO] 1.0dev
Exception in thread main java.lang.NoClassDefFoundError:
org/apache/commons/io/output/Co
untingOutputStream
at org.apache.fop.pdf.PDFFactory.makeStream(PDFFactory.java:1206)
at
org.apache.fop.render.pdf.PDFRenderer.renderPage(PDFRenderer.java:466)
at
org.apache.fop.area.RenderPagesModel.addPage(RenderPagesModel.java:117)
at org.apache.fop.area.AreaTree.addPage(AreaTree.java:141)
at
org.apache.fop.layoutmgr.PageLayoutManager.finishPage(PageLayoutManager.ja
va:49


The class CountingOutputStream in fact didn't exist. Why? It was compiled
without errors. Where i can get this class and where i should put it, so
the fop will work?


CU
Anton


smime.p7s
Description: S/MIME cryptographic signature


Help: Output from servlet is garbage

2003-04-25 Thread Joseph . Sadove


FOP version: fop-0.20.3
Platform: Win2K
WebSphere V5.0
J2EE Version: 1.3

I am getting following gibberish as a result of parsing the tollowing fo:
document. Apologies if this is too much too ask here.

I am also getting the following messages, but I think these are only page
size issues that shouldn't cause this result.

GIBBERISH EXTRACT
%PDF-1.3 %?«¬­ 4 0 obj  /Type /Info /Producer (null)  endobj 5 0 obj
 /Length 1581 /Filter /FlateDecode  stream x???Ks?HF??Z??(??2?xL ?
(`? I2 ?=W­n??·7???mY?a?'¤­??/?B?(U ­jc+MHM?®dM??O???
«?2}??µ¤2q?'+^QZ ???/ ? ??N? 4|*«?o?_?¶w????f?
|?»'W?S-?b*'V?« nDm­??O?¶fU?LF??)??t Ak??T|????}
xqZi#8f?ZB­?qS3u d?¬­??
/GIBBERISH EXTRACT

XML FO DOC follows:

fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
        fo:layout-master-set
                fo:simple-page-master master-name=first page-height
=21cm page-width=29.7cm margin-top=1cm margin-bottom=2cm
margin-left=2.5cm margin-right=2.5cm
                        fo:region-body margin-top=3cm /
                        fo:region-before extent=3cm /
                        fo:region-after extent=1.5cm /
                /fo:simple-page-master
        /fo:layout-master-set
        fo:page-sequence master-reference=first
                fo:flow flow-name=xsl-region-body
                        fo:block font-size=11pt font-family=sans-serif
font-weight=bold text-align=left border-top-width=5px
border-top-style=solid border-top-color=blue border-bottom-width=5px
border-bottom-style=solid border-bottom-color=blue space-after.optimum
=10ptMonthly Histogram for null null/fo:block
                        fo:table border-collapse=separate
                                fo:table-column column-width=36mm /
                                fo:table-column column-width=4mm /
                                fo:table-column column-width=61mm /
                                fo:table-column column-width=4mm /
                                fo:table-column column-width=61mm /
                                fo:table-column column-width=4mm /
                                fo:table-column column-width=83mm /
                                fo:table-column column-width=83mm /
                                fo:table-body
                                        fo:table-row
                                                fo:table-cell border-width
=0.0mm border-style=solid background-color=white
                                                        fo:table
border-collapse=separate

fo:table-column column-width=35mm /

fo:table-body font-size=8pt font-family=sans-serif

fo:table-row font-size=10pt font-family=sans-serif
fo:table-cell background-color=aqua
fo:block text-align=centerApplications/Systems/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell background-color=lightblue
fo:block text-align=centerMONTH/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell background-color=blue
fo:block color=white text-align=centerWEEK/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:block1633 ARCSERVE BACKUP/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:block4 CC ARCSERVE BKP/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockAAMS/IPTS/IRMIS/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockACBS/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockACBS-ALPHA/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockARMS/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCALL REPORT (MARK TO MKT)/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCARS/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCASSETT/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCDB/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCFAS/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCHECK PROCESSOR/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCHINA 

RE: Help: Output from servlet is garbage

2003-04-25 Thread Adam Shelley
The giberish is your pdf in binary format.  if you are using ie add
dummy.pdf onto the end to ensure it will open it in the acrobat plugin.
Check the docs regarding this.

-Adam

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: April 25, 2003 1:40 PM
To: [EMAIL PROTECTED]
Subject: Help: Output from servlet is garbage




FOP version: fop-0.20.3
Platform: Win2K
WebSphere V5.0
J2EE Version: 1.3

I am getting following gibberish as a result of parsing the tollowing fo:
document. Apologies if this is too much too ask here.

I am also getting the following messages, but I think these are only page
size issues that shouldn't cause this result.

GIBBERISH EXTRACT
%PDF-1.3 %?«¬­ 4 0 obj  /Type /Info /Producer (null)  endobj 5 0 obj
 /Length 1581 /Filter /FlateDecode  stream x???Ks?HF??Z??(??2?xL ?
(`? I2 ?=W­n??·7???mY?a?'¤­??/?B?(U ­jc+MHM?®dM??O???
«?2}??µ¤2q?'+^QZ ???/ ? ??N? 4|*«?o?_?¶w????f?
|?»'W?S-?b*'V?« nDm­??O?¶fU?LF??)??t Ak??T|????}
xqZi#8f?ZB­?qS3u d?¬­??
/GIBBERISH EXTRACT

XML FO DOC follows:

fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
        fo:layout-master-set
                fo:simple-page-master master-name=first page-height
=21cm page-width=29.7cm margin-top=1cm margin-bottom=2cm
margin-left=2.5cm margin-right=2.5cm
                        fo:region-body margin-top=3cm /
                        fo:region-before extent=3cm /
                        fo:region-after extent=1.5cm /
                /fo:simple-page-master
        /fo:layout-master-set
        fo:page-sequence master-reference=first
                fo:flow flow-name=xsl-region-body
                        fo:block font-size=11pt font-family=sans-serif
font-weight=bold text-align=left border-top-width=5px
border-top-style=solid border-top-color=blue border-bottom-width=5px
border-bottom-style=solid border-bottom-color=blue space-after.optimum
=10ptMonthly Histogram for null null/fo:block
                        fo:table border-collapse=separate
                                fo:table-column column-width=36mm /
                                fo:table-column column-width=4mm /
                                fo:table-column column-width=61mm /
                                fo:table-column column-width=4mm /
                                fo:table-column column-width=61mm /
                                fo:table-column column-width=4mm /
                                fo:table-column column-width=83mm /
                                fo:table-column column-width=83mm /
                                fo:table-body
                                        fo:table-row
                                                fo:table-cell border-width
=0.0mm border-style=solid background-color=white
                                                        fo:table
border-collapse=separate

fo:table-column column-width=35mm /

fo:table-body font-size=8pt font-family=sans-serif

fo:table-row font-size=10pt font-family=sans-serif
fo:table-cell background-color=aqua
fo:block text-align=centerApplications/Systems/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell background-color=lightblue
fo:block text-align=centerMONTH/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell background-color=blue
fo:block color=white text-align=centerWEEK/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:block1633 ARCSERVE BACKUP/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:block4 CC ARCSERVE BKP/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockAAMS/IPTS/IRMIS/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockACBS/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockACBS-ALPHA/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockARMS/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCALL REPORT (MARK TO MKT)/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCARS/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCASSETT/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm border-style=solid background-color
=white
fo:blockCDB/fo:block
/fo:table-cell

/fo:table-row

fo:table-row
fo:table-cell border-width=0.175mm 

Re: PDF Conversion

2003-04-25 Thread J.Pietschmann
amit kaushik wrote:
this is true that the order of the argument doesn't matter but the problem
still persist. Please help me on that,
Fat chance. Well, let's see...
java.lang.RuntimeException: java.lang.ArrayIndexOutOfBoundsException
at 
org.apache.xalan.transformer.TransformerImpl.run(TransformerImpl.java:3170)
^
This indicates the problem is in Xalan, not FOP. There are some vague
memories that an old Xalan release had this kind of problem. Which FOP
release are you using (see http://xml.apache.org/fop/gethelp.html
point three, grumble, grumble). Get 0.20.5rc2 and run the transformation
standalone in order to get better diagnostics (see
   http://xml.apache.org/fop/running.html#running_xalan)
This may be caused by this part of the style sheet:
 xsl:text disable-output-escaping=yes
lt;!DOCTYPE fo:root [
  lt;!ENTITY tilde  amp;#126;gt;
  lt;!ENTITY florin amp;#131;gt;
...
Remove this. It doesn't work as intended in this context, it
is unnecessary, and you don't need it. I always wonder why
sick brains com up with outlandish pseudo-solutions of this
kind and throw it on unsuspecting newbies.
J.Pietschmann
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: AW: Number alignment in TOC

2003-04-25 Thread J.Pietschmann
anton wrote:
And I get following error:
[INFO] 1.0dev
 I told you to be sure to get the code from the maintenance branch. The
branch tag is fop-0_20_2-maintain.
J.Pietschmann
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Help: Output from servlet is garbage

2003-04-25 Thread Joseph . Sadove

Thanks for the super fast reponse.
I'm using the following code to write the rendered stream to the response. I don't think I can just append the dummy.pdf to the prepared stream, as it will will likely have an eof marker.
I was not able to find anything in the apache/xml docs and nothing wholly relevant in the archives. I may be a bit lame today (among other days). I would really appreciate it if you or someone else could help me further in this. 
As a note, I had this working at one point. I made some big changes and then this started happening. I then went and removed the changes and now the problem persists. Hmmm.

a) Can you/anyone suggest how this could be done
b) Can you point to where to look on the dummy.pdf problem

Thanks againJoe

CODE-SNIPPET
Reader reader = new java.io.StringReader(strBuffer1.toString());
InputSource foDoc = new InputSource(reader);

response.setContentType(application/pdf);

XMLReaderFactory.createXMLReader();
System.setProperty(
org.xml.sax.driver,
org.apache.xerces.parsers.SAXParser);

ByteArrayOutputStream baos = new ByteArrayOutputStream();
org.apache.fop.apps.Driver driver2 =
new org.apache.fop.apps.Driver(foDoc, baos);

String version = org.apache.fop.apps.Version.getVersion();
driver2.setRenderer(org.apache.fop.render.pdf.PDFRenderer);

driver2.addElementMapping(
org.apache.fop.fo.StandardElementMapping);
driver2.addElementMapping(org.apache.fop.svg.SVGElementMapping);

XMLReader parser = createParser();
parser.setFeature(
http://xml.org/sax/features/namespace-prefixes,
true);

driver2.run();

byte[] content = baos.toByteArray();
response.setContentLength(content.length);
response.getOutputStream().write(content);
//THIS WILL NOT WORK EVEN IF I FIX content.length --
//response.getOutputStream().write(dummy.pdf.getBytes());

/CODE-SNIPPET








Adam Shelley [EMAIL PROTECTED]
04/25/2003 04:45 PM
Please respond to fop-user


To:[EMAIL PROTECTED]
cc:
Subject:RE: Help: Output from servlet is garbage


The giberish is your pdf in binary format. if you are using ie add
dummy.pdf onto the end to ensure it will open it in the acrobat plugin.
Check the docs regarding this.

-Adam

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: April 25, 2003 1:40 PM
To: [EMAIL PROTECTED]
Subject: Help: Output from servlet is garbage




FOP version: fop-0.20.3
Platform: Win2K
WebSphere V5.0
J2EE Version: 1.3

I am getting following gibberish as a result of parsing the tollowing fo:
document. Apologies if this is too much too ask here.

I am also getting the following messages, but I think these are only page
size issues that shouldn't cause this result.

GIBBERISH EXTRACT
%PDF-1.3 %?«¬­ 4 0 obj  /Type /Info /Producer (null)  endobj 5 0 obj
 /Length 1581 /Filter /FlateDecode  stream x???Ks?HF??Z??(??2?xL ?
(`? I2 ?=W­n??·7???mY?a?'¤­??/?B?(U ­jc+MHM?®dM??O???
«?2}??µ¤2q?'+^QZ ???/ ? ??N? 4|*«?o?_?¶w????f?
|?»'W?S-?b*'V?« nDm­??O?¶fU?LF??)??t Ak??T|????}
xqZi#8f?ZB­?qS3u d?¬­??
/GIBBERISH EXTRACT

XML FO DOC follows:

fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format
        fo:layout-master-set
                fo:simple-page-master master-name=first page-height
=21cm page-width=29.7cm margin-top=1cm margin-bottom=2cm
margin-left=2.5cm margin-right=2.5cm
                        fo:region-body margin-top=3cm /
                        fo:region-before extent=3cm /
                        fo:region-after extent=1.5cm /
                /fo:simple-page-master
        /fo:layout-master-set
        fo:page-sequence master-reference=first
                fo:flow flow-name=xsl-region-body
                        fo:block font-size=11pt font-family=sans-serif
font-weight=bold text-align=left border-top-width=5px
border-top-style=solid border-top-color=blue border-bottom-width=5px
border-bottom-style=solid border-bottom-color=blue space-after.optimum
=10ptMonthly Histogram for null null/fo:block
                        fo:table border-collapse=separate
                                fo:table-column column-width=36mm /
                                fo:table-column column-width=4mm /
                                fo:table-column column-width=61mm /
                                fo:table-column column-width=4mm /
                                fo:table-column column-width=61mm /
                                fo:table-column column-width=4mm /
                                fo:table-column column-width=83mm /
                                fo:table-column column-width=83mm /
                                fo:table-body
                                        

Re: Rendering PDF with EPS graphics in it

2003-04-25 Thread J.Pietschmann
Olivier Imbert wrote:
I have to render PDF including EPS graphics.
Everything renders fine using FOP 0.20.4.
I got a performance issue when printing on a PostScript printer  (several 
types used) thru Acrobat Reader : for each page including EPS graphics the 
printer spend a lot of time (formatting ?) before printing.
Jeremias is absent until end of next week, be a bit more patient.
J.Pietschmann
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: FO/FOP for modifiable fields

2003-04-25 Thread Eric Pement
At 12:07 PM 4/25/2003 -0700, you wrote:

This might be a silly question, but I'd like to know
if it is possible to create a modifiable field on the
resulting PDF document. Is there any way I can tell
the FOP, through an attribute may be, to create a
field that can be modified by the user should he have
to?

I assume you mean, modified by the user on the command line?
If it were me, I would use a shell script (*nix) or batch file
(Windows) which accepts an argument. That argument would be one
or more strings to change just before printing. The batch file
might look something like this:

   @echo off
   :: filename: MODIFY.BAT, a sample Windows batch file
   ::
   :: If no argument is given, the .FO file is processed normally.
   :: If an argument is given, alter the .FO file before sending
   :: it to FOP for processing. The argument string may not
   :: contain an equal sign.
   ::
   :: If there was no argument passed, print the file normally.
   IF %1== GOTO print
   :: Implied ELSE is we have an argument, so execute this instead.
   echo We were given the following user change: %1
   set VAR=%1
   ::
   :: Execute sed (stream editor) or awk or perl or python or whatever.
   :: This example uses sed, since it's small, fast, free and open source.
   sed s=fixed-string=%VAR%=g; yourfile.fo temp.fil
   ::
   move /Y temp.fil yourfile.fo
   :print
   call fop.bat yourfile.fo yourfile.pdf
   ::end

If you need help explaining any of this, let me know. The basic idea is
that you have a fixed string in yourfile.fo which will print as is
unless you intend to change it. That string might be an email address
like [EMAIL PROTECTED] or a date like April 2003.  If no argument is passed
on the command line (you type modify and press ENTER), the resulting
.PDF file will contain that literal string. But if you pass a command like:

modify [EMAIL PROTECTED]

or
 
modify April 25, 2003

then [EMAIL PROTECTED] will be replaced with [EMAIL PROTECTED] , or the 
general
date of April 2003 will be replaced with April 25, 2003 and so forth.
The batch file could be revised to expect more than one substitution.

This example could be changed to interactively prompt the user for a
value, or it could run under a different command shell (like 4NT or
bash). Hope this helps. Write me if you have further questions.


-- 
Eric Pement - [EMAIL PROTECTED]
Education Technical Services, MBI


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: object administration in a fo:table

2003-04-25 Thread J.Pietschmann
Todtenhaupt, Susann wrote:
I've tried to put a fo:block-container into a fo:table-cell. Furthermore
this container holds another fo:block-container with some blocks in it. But
in my PDF the first container collapsed and attributes like height didn't
work. 
FOP doesn't implement the whole XSLFO spec. In particular block
containers are not guaranteed to work except as immediate children
of a flow.
 In HTML it's possible to have objects in a table and the table renders
 the necessary design.
This is rather irrelevant here.
In order to recieve some real help you'll have to describe your
problem a bit more detailed.
J.Pietschmann
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Help: Output from servlet is garbage

2003-04-25 Thread Steve Albin








Your output is actually correct and your servlet
is doing the right thing. Microsoft IE does not recognize the content as a PDF
file and therefore does not invoke Acrobat to display the content, rather it
simply dumps your PDF data as text to the browser window. What IE needs is an
actual .pdf at the end of the URL used to invoke your servlet. That is how it
knows to render the output using Acrobat. The suggestion Adam made was to
append dummy.pdf to the end of the URL used to invoke your serlvet (not to
append it to your response output stream). This is exactly what I have to do,
since I am also generating PDF in memory and returning it to an IE browser. 



Hope this helps.

-Steve



-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] 
Sent: Friday, April 25, 2003 2:47
PM
To: [EMAIL PROTECTED]
Subject: RE: Help: Output from
servlet is garbage




Thanks for the super fast reponse. 
I'm
using the following code to write the rendered stream to the response. I don't
think I can just append the dummy.pdf to the prepared stream, as it will
will likely have an eof marker. 
I
was not able to find anything in the apache/xml docs and nothing wholly
relevant in the archives. I may be a bit lame today (among other days). I would
really appreciate it if you or someone else could help me further in this. 
As
a note, I had this working at one point. I made some big changes and then this
started happening. I then went and removed the changes and now the problem
persists. Hmmm. 

a)
Can you/anyone suggest how this could be done 
b)
Can you point to where to look on the dummy.pdf problem


Thanks
againJoe 

CODE-SNIPPET


  
Reader reader = new java.io.StringReader(strBuffer1.toString()); 

  
InputSource foDoc = new InputSource(reader); 


   response.setContentType(application/pdf);



  
XMLReaderFactory.createXMLReader(); 

  
System.setProperty( 

   
   org.xml.sax.driver, 

   
   org.apache.xerces.parsers.SAXParser);



  
ByteArrayOutputStream baos = new ByteArrayOutputStream();


  
org.apache.fop.apps.Driver driver2 = 

   
   new org.apache.fop.apps.Driver(foDoc, baos);



  
String version = org.apache.fop.apps.Version.getVersion(); 

  
driver2.setRenderer(org.apache.fop.render.pdf.PDFRenderer);



  
driver2.addElementMapping( 

   
   org.apache.fop.fo.StandardElementMapping);


  
driver2.addElementMapping(org.apache.fop.svg.SVGElementMapping);



  
XMLReader parser = createParser(); 

  
parser.setFeature( 

   
  
http://xml.org/sax/features/namespace-prefixes, 

   
   true); 


  
driver2.run(); 


  
byte[] content = baos.toByteArray(); 

   response.setContentLength(content.length);


  
response.getOutputStream().write(content); 
//THIS
WILL NOT WORK EVEN IF I FIX content.length -- 
//
   response.getOutputStream().write(dummy.pdf.getBytes());


/CODE-SNIPPET







 
  
  
  
  
  Adam Shelley
  [EMAIL PROTECTED] 
  04/25/2003 04:45 PM 
  Please
  respond to fop-user 
  
  
  
  
 To:[EMAIL PROTECTED]
  
  
 cc: 
  
 Subject:RE: Help: Output
  from servlet is garbage
  
 





The giberish is your pdf in binary format. if
you are using ie add
dummy.pdf onto the end to ensure it will open it in the acrobat plugin.
Check the docs regarding this.

-Adam

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: April 25, 2003 1:40 PM
To: [EMAIL PROTECTED]
Subject: Help: Output from servlet is garbage




FOP version: fop-0.20.3
Platform: Win2K
WebSphere V5.0
J2EE Version: 1.3

I am getting following gibberish as a result of parsing the tollowing fo:
document. Apologies if this is too much too ask here.

I am also getting the following messages, but I think these are only page
size issues that shouldn't cause this result.

GIBBERISH EXTRACT
%PDF-1.3 %? 4 0 obj  /Type /Info /Producer (null)  endobj 5
0 obj
 /Length 1581 /Filter /FlateDecode  stream
x???Ks?HF??Z??(??2?xL ?
(`? I2 ?=Wn??7???mY?a?'??/?B?(U jc+MHM?dM??O???
?2}??2q?'+^QZ ???/ ? ??N? 4|*?o?_?wf?
|?'W?S-?b*'V? nDm??O?fU?LF??)??t Ak??T|}
xqZi#8f?ZB?qS3u d???
/GIBBERISH EXTRACT

XML FO DOC follows:

fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format
fo:layout-master-set
fo:simple-page-master
master-name=first page-height
=21cm page-width=29.7cm margin-top=1cm
margin-bottom=2cm
margin-left=2.5cm margin-right=2.5cm
  
 fo:region-body margin-top=3cm /
  
 fo:region-before extent=3cm /
  
 fo:region-after extent=1.5cm /
   

RE: Help: Output from servlet is garbage

2003-04-25 Thread Steve Albin








By the way, see the Note halfway down the
page http://xml.apache.org/fop/embedding.htmlb
under Using FOP in a Servlet



Some versions of
Internet Explorer will not automatically show the PDF. This is well-known to be
a limitation of Internet Explorer, and is not a problem with the servlet.
However, Internet Explorer can still be used to download the PDF so that it can
be viewed later. Also, appending .pdf to the end of the URL may help.



-Steve



-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] 
Sent: Friday, April 25, 2003 2:47
PM
To: [EMAIL PROTECTED]
Subject: RE: Help: Output from
servlet is garbage




Thanks for the super fast reponse. 
I'm
using the following code to write the rendered stream to the response. I don't
think I can just append the dummy.pdf to the prepared stream, as it will
will likely have an eof marker. 
I
was not able to find anything in the apache/xml docs and nothing wholly
relevant in the archives. I may be a bit lame today (among other days). I would
really appreciate it if you or someone else could help me further in this. 
As
a note, I had this working at one point. I made some big changes and then this
started happening. I then went and removed the changes and now the problem
persists. Hmmm. 

a)
Can you/anyone suggest how this could be done 
b)
Can you point to where to look on the dummy.pdf problem


Thanks
againJoe 

CODE-SNIPPET


  
Reader reader = new java.io.StringReader(strBuffer1.toString()); 

  
InputSource foDoc = new InputSource(reader); 


  
response.setContentType(application/pdf); 


  
XMLReaderFactory.createXMLReader(); 

  
System.setProperty( 

   
   org.xml.sax.driver, 

   
   org.apache.xerces.parsers.SAXParser);



  
ByteArrayOutputStream baos = new ByteArrayOutputStream();


  
org.apache.fop.apps.Driver driver2 = 

   
   new org.apache.fop.apps.Driver(foDoc, baos);



  
String version = org.apache.fop.apps.Version.getVersion(); 

  
driver2.setRenderer(org.apache.fop.render.pdf.PDFRenderer);



  
driver2.addElementMapping( 

   
   org.apache.fop.fo.StandardElementMapping);


  
driver2.addElementMapping(org.apache.fop.svg.SVGElementMapping);



  
XMLReader parser = createParser(); 

  
parser.setFeature( 

   
   http://xml.org/sax/features/namespace-prefixes,


   
   true); 


  
driver2.run(); 


  
byte[] content = baos.toByteArray(); 

  
response.setContentLength(content.length); 

  
response.getOutputStream().write(content); 
//THIS
WILL NOT WORK EVEN IF I FIX content.length -- 
//
   response.getOutputStream().write(dummy.pdf.getBytes());


/CODE-SNIPPET







 
  
  
  
  
  Adam Shelley
  [EMAIL PROTECTED] 
  04/25/2003 04:45 PM 
  Please
  respond to fop-user 
  
  
  
  
 To:[EMAIL PROTECTED]
  
  
 cc: 
  
 Subject:RE: Help: Output
  from servlet is garbage
  
 





The giberish is your pdf in binary format. if
you are using ie add
dummy.pdf onto the end to ensure it will open it in the acrobat plugin.
Check the docs regarding this.

-Adam

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: April 25, 2003 1:40 PM
To: [EMAIL PROTECTED]
Subject: Help: Output from servlet is garbage




FOP version: fop-0.20.3
Platform: Win2K
WebSphere V5.0
J2EE Version: 1.3

I am getting following gibberish as a result of parsing the tollowing fo:
document. Apologies if this is too much too ask here.

I am also getting the following messages, but I think these are only page
size issues that shouldn't cause this result.

GIBBERISH EXTRACT
%PDF-1.3 %? 4 0 obj  /Type /Info /Producer (null)  endobj 5
0 obj
 /Length 1581 /Filter /FlateDecode  stream
x???Ks?HF??Z??(??2?xL ?
(`? I2 ?=Wn??7???mY?a?'??/?B?(U jc+MHM?dM??O???
?2}??2q?'+^QZ ???/ ? ??N? 4|*?o?_?wf?
|?'W?S-?b*'V? nDm??O?fU?LF??)??t Ak??T|}
xqZi#8f?ZB?qS3u d???
/GIBBERISH EXTRACT

XML FO DOC follows:

fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format
fo:layout-master-set
   
fo:simple-page-master master-name=first page-height
=21cm page-width=29.7cm margin-top=1cm
margin-bottom=2cm
margin-left=2.5cm margin-right=2.5cm
  
 fo:region-body margin-top=3cm /
  
 fo:region-before extent=3cm /
  
 fo:region-after extent=1.5cm /
   
/fo:simple-page-master
/fo:layout-master-set
fo:page-sequence
master-reference=first
fo:flow
flow-name=xsl-region-body
  
 fo:block font-size=11pt font-family=sans-serif
font-weight=bold text-align=left

Re: newbie help on error message

2003-04-25 Thread J.Pietschmann
Eric Pement wrote:
Right now, I'm getting an error message, fo:flow must contain block-level
children, which I don't know what to do with.
It means exactly what it says.
  fo:flow flow-name=xsl-region-body
  xsl:apply-templates select=Title /
  /fo:flow
  . . .
  xsl:template match=[EMAIL PROTECTED]'title_1']
fo:block
Chances are that your template isn't matched for whatever reason,
and the flow turns out empty or perhaps with text supplied from
default templates.
I don't know why this error message is occurring, since I think
the block-level children are invoked by the match.
Well, inspect the FO file to be *sure*.
I would
also like some pointers, web links or ideas on building an
.XSL file in stages, since I seem to be failing even on the
first steps. Thanks in advance.
Buy Mike Kay's book on XSLT (ISBN 1861005067) and perhaps
D.Pawsons book about XSLFO (ISBN 0596003552) and work through
the examples. It is usually unwise to learn a new technology on
the job.
Victor: as usual, something for the ressources page?
J.Pietschmann

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: FO/FOP for modifiable fields

2003-04-25 Thread J.Pietschmann
[EMAIL PROTECTED] wrote:
This might be a silly question, but I'd like to know
if it is possible to create a modifiable field on the
resulting PDF document.
If you mean PDFForms then no, this is not possible. The
XSL spec does not provide definitions for this.
J.Pietschmann
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Unknown formatting object

2003-04-25 Thread J.Pietschmann
Willis, Matthew wrote:
I'm getting the following exception:
WARNING: Unknown formatting object
http://www.w3.org/1999/XSL/Transform^stylesheet
...
when running the following code snippet to set up an embedded FOP:
Driver fopDriver = new Driver(new InputSource(XSL_FO_FILE_PATH), new
FileOutputStream(OBI_PDF_PO_FILE_PATH));
You are feeding the style sheet as input to the formatter. This
can't work, the formatter will only take FO documents, which is
something different.
If you want to transform some input XML with the style sheet and
have the formatter work on the result of the transformation, see
  http://xml.apache.org/fop/embedding.html#servlet-transform
Here are the versions I'm using for the various jars:
fop 0.18 DEV
That's darn old, you should upgrade. The code example above
probably won't work with this old FOP release.
J.Pietschmann
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Help: Output from servlet is garbage

2003-04-25 Thread J.Pietschmann
[EMAIL PROTECTED] wrote:
I'm using the following code to write the rendered stream to the response. 
I don't think I can just append the dummy.pdf to the prepared stream,
It was meant to append this to the URL which causes the servlet
producing the PDF to be invoked.
CODE-SNIPPET
This seems to be awfully overcomplicated. In particular this:
 Reader reader = new  java.io.StringReader(strBuffer1.toString());
indicates you are building an XML string in memory, then parse it,
which is often inefficient.
Look at the FOP FAQ
  http://xml.apache.org/fop/faq.html#part-iex
and the code samples here
  http://xml.apache.org/fop/embedding.html
J.Pietschmann
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: newbie help on error message

2003-04-25 Thread Eric Pement
At 12:25 PM 4/25/2003 -0600, Victor Mote wrote:

Eric Pement wrote:
 Right now, I'm getting an error message, fo:flow must contain block-level
 children, which

   I've fixed the error message, by changing

   fo:flow flow-name=xsl-region-body
   xsl:apply-templates select=Title /
   /fo:flow


To this:
   
  fo:flow flow-name=xsl-region-body
  fo:block
  xsl:apply-templates select=Title /
  /fo:block
  /fo:flow

So I no longer get the error message. However, the content
of the fo:blocks is now empty, and whatever is in the Title
tags is being ignored and not printed in the output document.

All Xalan did was to confirm that nothing is printed in the 
output. Problem is, it didn't tell me exactly why the content
is being skipped. I guess I have more to discover.

I changed this:

   xsl:template match=[EMAIL PROTECTED]'title_1']
 fo:block
   font-size=24pt line-height=28pt text-align=start
   font-family=Helvetica font-weight=bold color=blue
   space-after.optimum=12pt
   xsl:value-of select=Title /
 /fo:block
   /xsl:template


and replaced xsl:value-of ... to xsl:apply-templates and it
didn't help either. If anyone has any other suggestions, PLEASE
pipe in and suggest something. Thanks much!!


-- 
Eric Pement - [EMAIL PROTECTED]
Education Technical Services, MBI


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: newbie help on error message

2003-04-25 Thread J.Pietschmann
Eric Pement wrote:
So I no longer get the error message. However, the content
of the fo:blocks is now empty, and whatever is in the Title
tags is being ignored and not printed in the output document.
All Xalan did was to confirm that nothing is printed in the 
output. Problem is, it didn't tell me exactly why the content
is being skipped. I guess I have more to discover.

 xsl:template match=[EMAIL PROTECTED]'title_1']
   fo:block
 font-size=24pt line-height=28pt text-align=start
 font-family=Helvetica font-weight=bold color=blue
 space-after.optimum=12pt
 xsl:value-of select=Title /
  ^^
This will only result in a value if you have a Title element
in the matched Title element.
However, I guess the above template didn't match at all. There
is no way to tell why whithout knowing the match pattern for the
template which produces the fo:flow and the relevat part of the
source XML.
J.Pietschmann
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]