AW: help please Problem with generation PDF

2001-09-17 Thread Beer, Christian

Hi!

I think that 
  inputHandler.getInputSource() 
returns the source xml-file you mentioned in your mail. That is 
because fop tries to process your xml-file as a fo-file but failes.

I don't know how to use a XSLTInputHandler, but I think there must
be another way.

Christian

-Ursprüngliche Nachricht-
Von: Semprini Davide [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 14. September 2001 15:41
An: [EMAIL PROTECTED]
Betreff: help please Problem with generation PDF


Hi,

I have witten a Servlet that take two file in input (file.xml and file.xsl)
my code is:

 Driver driver = new Driver();
 driver.setRenderer(Driver.RENDER_PDF);
 File xmlFile = new File(c:\\xml_to_pdf.xml);
 File xslFile = new File(c:\\TransformPDF.xsl);   
 InputHandler inputHandler = new 
XSLTInputHandler(xmlFile,xslFile);   
 XMLReader parser=createParser();
 driver.setOutputStream(new FileOutputStream(outFile.pdf));
 driver.render(parser, inputHandler.getInputSource());
  
and my servlet have a block inside Method render( )
The parser is instantiated correctly I think that there is a problem
in the way that i pass the Files!!  TOMCAT REPLY ME:

building formatting object tree
setting up fonts
WARNING: Unknown formatting object ^val

 and then an error inside driven.render()

my xml is very simple like this:
?xml version=1.0 encoding=UTF-8?
val
titleProva di PDF/title
sourceSorgente/source
date13-09-01/date
paragraph number=1
lineQuesta e' una prova di creazione di PDF utilizzando i tag 
XSL-FO/line
/paragraph
/val

WHY the transform don't know my root element!

Please can somebody help me??

Tanks a lot

D.Semprini



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

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




Re: FOP on IBM AS400

2001-09-17 Thread Keiron Liddle

On Fri, 14 Sep 2001 12:30:09 Stephen Fry wrote:
 Hi
 
 We are attempting to port our application which uses fop 0.20.1 to the
 AS400. We seems to have some issues with FOP's use of AWT classes. Has
 anyone any experience of this environment ? Is it possible to configure
 FOP
 not to use AWT or is it fundemental ?
 
 We have bmp files as external-graphic's, and we are rendering to PDF,PS
 and
 PCL.

The AWT classes are used by batik and currently batik is tied into fop. If
someone implements the user agent properly then it will be possible to
separate the use of batik and handle problems better.
I don't know what your problem with the AWT classes is but if it is due to
the display then the real problem is with java, this is fixed in version
jdk1.4.

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




cvs commit: xml-fop/src/org/apache/fop/render/pdf PDFRenderer.java

2001-09-17 Thread keiron

keiron  01/09/17 04:04:50

  Modified:src/org/apache/fop/render AbstractRenderer.java
PrintRenderer.java
   src/org/apache/fop/render/awt AWTRenderer.java
   src/org/apache/fop/render/pdf PDFRenderer.java
  Log:
  put a few common methods in the abstract renderer
  
  Revision  ChangesPath
  1.2   +80 -4 xml-fop/src/org/apache/fop/render/AbstractRenderer.java
  
  Index: AbstractRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/AbstractRenderer.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractRenderer.java 2001/08/21 06:18:55 1.1
  +++ AbstractRenderer.java 2001/09/17 11:04:49 1.2
  @@ -1,8 +1,8 @@
   /*
  - * $Id: AbstractRenderer.java,v 1.1 2001/08/21 06:18:55 keiron Exp $
  + * $Id: AbstractRenderer.java,v 1.2 2001/09/17 11:04:49 keiron Exp $
* Copyright (C) 2001 The Apache Software Foundation. All rights reserved.
* For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  + * LICENSE file included with these sources.
*/
   
   package org.apache.fop.render;
  @@ -18,8 +18,6 @@
   import org.apache.fop.datatypes.*;
   import org.apache.fop.render.pdf.FontSetup;
   
  -import org.apache.fop.svg.SVGArea;
  -
   import org.apache.log.Logger;
   
   // Java
  @@ -34,8 +32,86 @@
   public abstract class AbstractRenderer implements Renderer {
   protected Logger log;
   
  +/**
  + * the current vertical position in millipoints from bottom
  + */
  +protected int currentYPosition = 0;
  +
  +/**
  + * the current horizontal position in millipoints from left
  + */
  +protected int currentXPosition = 0;
  +
  +/**
  + * the horizontal position of the current area container
  + */
  +protected int currentAreaContainerXPosition = 0;
  +
   public void setLogger(Logger logger) {
   log = logger;
   }
   
  +public void renderSpanArea(SpanArea area) {
  +Enumeration e = area.getChildren().elements();
  +while (e.hasMoreElements()) {
  +org.apache.fop.layout.Box b =
  +(org.apache.fop.layout.Box)e.nextElement();
  +b.render(this);// column areas
  +}
  +
  +}
  +
  +protected abstract void doFrame(Area area);
  +
  +/**
  + * render block area
  + *
  + * @param area the block area to render
  + */
  +public void renderBlockArea(BlockArea area) {
  +// KLease: Temporary test to fix block positioning
  +// Offset ypos by padding and border widths
  +this.currentYPosition -= (area.getPaddingTop()
  +  + area.getBorderTopWidth());
  +doFrame(area);
  +Enumeration e = area.getChildren().elements();
  +while (e.hasMoreElements()) {
  +Box b = (Box)e.nextElement();
  +b.render(this);
  +}
  +this.currentYPosition -= (area.getPaddingBottom()
  +  + area.getBorderBottomWidth());
  +}
  +
  +/**
  + * render line area
  + *
  + * @param area area to render
  + */
  +public void renderLineArea(LineArea area) {
  +int rx = this.currentAreaContainerXPosition + area.getStartIndent();
  +int ry = this.currentYPosition;
  +int w = area.getContentWidth();
  +int h = area.getHeight();
  +
  +this.currentYPosition -= area.getPlacementOffset();
  +this.currentXPosition = rx;
  +
  +int bl = this.currentYPosition;
  +
  +Enumeration e = area.getChildren().elements();
  +while (e.hasMoreElements()) {
  +Box b = (Box)e.nextElement();
  +if (b instanceof InlineArea) {
  +InlineArea ia = (InlineArea)b;
  +this.currentYPosition = ry - ia.getYOffset();
  +} else {
  +this.currentYPosition = ry - area.getPlacementOffset();
  +}
  +b.render(this);
  +}
  +
  +this.currentYPosition = ry - h;
  +this.currentXPosition = rx;
  +}
   }
  
  
  
  1.12  +16 -63xml-fop/src/org/apache/fop/render/PrintRenderer.java
  
  Index: PrintRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/PrintRenderer.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- PrintRenderer.java2001/08/21 06:18:55 1.11
  +++ PrintRenderer.java2001/09/17 11:04:49 1.12
  @@ -1,5 +1,5 @@
   /*
  - * $Id: PrintRenderer.java,v 1.11 2001/08/21 06:18:55 keiron Exp $
  + * $Id: PrintRenderer.java,v 1.12 2001/09/17 11:04:49 keiron Exp $
* Copyright (C) 2001 The Apache Software Foundation. All rights 

ETA on 0.20.2

2001-09-17 Thread Louis . Masters

Any ETA on  0.20.2?  I really need markers to implement running headers.
Thanks,
Lou



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




Ant FOP task

2001-09-17 Thread Morrison, John

Hi All,

Does anybody have a build.xml file which demonstrates how to take xml+xslt
files and produce a pdf with the ant fop class?

Thanks,

J.


===
Information in this email and any attachments are confidential, and may
not be copied or used by anyone other than the addressee, nor disclosed
to any third party without our permission.  There is no intention to
create any legally binding contract or other commitment through the use
of this email.

Experian Limited (registration number 653331).  
Registered office: Talbot House, Talbot Street, Nottingham NG1 5HF

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




Re: AW: [Q] root directory for embedded font metric and ttf files ? and new: DumpConfiguration

2001-09-17 Thread axel . spohr


Christian,

unfortunately this hasen't allowed me to import fonts just yet. I have
tried both relative and absolute paths since - to no avail.

I have tried absolute with forward slashes (java path syntax) and
backslashes (windows path syntax - since this is a w2k platform)
and have tried relative and URL style file naming.

Which brings me to the next question: The config.xml has an entry
dumpConfiguration which defaults to false.
Can I override that to true in my userconfig.xml and where would that dump
to ? Console doesn`t show anything. Is there anything else I need to
specify ?
TIA
   Axel
   
   
   
   
   





   

Beer, Christian  

[EMAIL PROTECTED]   To: '[EMAIL PROTECTED]' 
[EMAIL PROTECTED]   
 cc:   

17/09/2001 14:06 Subject: AW: [Q] root directory for 
embedded font metric and ttf  
Please respond tofiles ?   

fop-dev

   

   





If you use a relative path, the path where you start the programm from
is the base-path. So in the case of your servlet it is the path from where
you start the servlet-engine.

-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Gesendet: Montag, 17. September 2001 13:48
An: [EMAIL PROTECTED]
Betreff: [Q] root directory for embedded font metric and ttf files ?


I am embedding FOP 0.20.1 into a servlet using the procedure described on
the embedding page, including loading a user configuration file which I
require to use non-standard fonts in my generated documents.

The documentation for embedding extra fonts is missing information as to
where FOP is looking for these fonts - the sample has an absolute path for
the embed file and a relative path for the metrics file.
For my command line tests as part of the stylesheet development, just
having everything in the local directory worked out.

Relative to what would I need to specify the path for the servlet ? Can I
use some kind of java system resource setup to search the class path ?
TIA

Axel



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




Fop JPEG-Patch

2001-09-17 Thread Daniel Pfuhl

Hi

can anybody give me a quick tour about
how to get fop working with the patch
from eric dalquist?!

i downloaded a developer-snapshot and
copied the patched files at the
appropriate locations. after starting
fop to generate my pdf it is running
into an infinite error without printing
any stack-trace :-(

looks like this:

C:\myWork\xml\fop-devjava -cp
build\fop.jar;lib\batik.jar;lib\xalan-2.0.0.jar;lib\xerces-1.2.3.jar;lib\avalon-framework
-4.0.jar;lib\logkit-1.0b4.jar;lib\jimi-1.0.jar
org.apache.fop.apps.Fop -d -c conf\userconfig.xml -xsl
C:\Programme\Apach
e\tomcat\webapps\cocoon\diplom\styles\main.pdf.xsl
-xml
C:\Programme\Apache\tomcat\webapps\cocoon\diplom\index_raw.xml
-
pdf
C:\Programme\Apache\tomcat\webapps\cocoon\diplom\pdf\outfile_main.pdf
[INFO]: FOP 0.20.1
[INFO]: building formatting object tree
[INFO]: [1]
[INFO]: [1]
[INFO]: [2]
[INFO]: [3]
[INFO]: [1]
[INFO]: [2]
[ERROR]: 
[ERROR]: 
[ERROR]: 
[ERROR]: 

thanks 

=

Daniel Pfuhl
mailto:[EMAIL PROTECTED]

__
Do You Yahoo!?
Gesendet von Yahoo! Mail - http://mail.yahoo.de

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




AW: AW: [Q] root directory for embedded font metric and ttf files ? and new: DumpConfiguration

2001-09-17 Thread Beer, Christian

Sorry, I haven't tried to import fonts or dump the configuration till now. 
Can't help you in that point.

Do you know the filename, where the configuration is dumped to? If yes, try
searching for that file.

That's what I would do. Sorry, I can't help...

-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Gesendet: Montag, 17. September 2001 16:18
An: [EMAIL PROTECTED]
Betreff: Re: AW: [Q] root directory for embedded font metric and ttf
files ? and new: DumpConfiguration 



Christian,

unfortunately this hasen't allowed me to import fonts just yet. I have
tried both relative and absolute paths since - to no avail.

I have tried absolute with forward slashes (java path syntax) and
backslashes (windows path syntax - since this is a w2k platform)
and have tried relative and URL style file naming.

Which brings me to the next question: The config.xml has an entry
dumpConfiguration which defaults to false.
Can I override that to true in my userconfig.xml and where would that dump
to ? Console doesn`t show anything. Is there anything else I need to
specify ?
TIA
   Axel
   
   
   
   
   





 

Beer, Christian

[EMAIL PROTECTED]   To: '[EMAIL PROTECTED]'
[EMAIL PROTECTED]   
 cc:

17/09/2001 14:06 Subject: AW: [Q] root directory
for embedded font metric and ttf  
Please respond tofiles ?

fop-dev

 

 





If you use a relative path, the path where you start the programm from
is the base-path. So in the case of your servlet it is the path from where
you start the servlet-engine.

-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Gesendet: Montag, 17. September 2001 13:48
An: [EMAIL PROTECTED]
Betreff: [Q] root directory for embedded font metric and ttf files ?


I am embedding FOP 0.20.1 into a servlet using the procedure described on
the embedding page, including loading a user configuration file which I
require to use non-standard fonts in my generated documents.

The documentation for embedding extra fonts is missing information as to
where FOP is looking for these fonts - the sample has an absolute path for
the embed file and a relative path for the metrics file.
For my command line tests as part of the stylesheet development, just
having everything in the local directory worked out.

Relative to what would I need to specify the path for the servlet ? Can I
use some kind of java system resource setup to search the class path ?
TIA

Axel



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

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




Re: Fop JPEG-Patch

2001-09-17 Thread Eric B. Dalquist

Just so everyone knows. If anyone has problems with the patch please send me
the jpg at least and preferably the whole .fo that is cause the problems. I'm
pretty busy with a musical right now but I will do my best to find and fix all
the bugs. I unfortunatly didn't have the time to test this patch as much as I
would have liked but the rest of you find the bugs is still help[full.

-Eric Dalquist

Jim Wright wrote:

 Did you rerun the build to get a new jar file and classes?

 Make sure you put the new files in place, delete the one Eric mentions in
 his email, then run the build.

 Worked like a charm for me.

 jw

 -Original Message-
 From: Daniel Pfuhl [mailto:[EMAIL PROTECTED]]
 Sent: Monday, September 17, 2001 9:28 AM
 To: fop-list
 Subject: Fop  JPEG-Patch

 Hi

 can anybody give me a quick tour about
 how to get fop working with the patch
 from eric dalquist?!

 i downloaded a developer-snapshot and
 copied the patched files at the
 appropriate locations. after starting
 fop to generate my pdf it is running
 into an infinite error without printing
 any stack-trace :-(

 looks like this:

 C:\myWork\xml\fop-devjava -cp
 build\fop.jar;lib\batik.jar;lib\xalan-2.0.0.jar;lib\xerces-1.2.3.jar;lib\ava
 lon-framework
 -4.0.jar;lib\logkit-1.0b4.jar;lib\jimi-1.0.jar
 org.apache.fop.apps.Fop -d -c conf\userconfig.xml -xsl
 C:\Programme\Apach
 e\tomcat\webapps\cocoon\diplom\styles\main.pdf.xsl
 -xml
 C:\Programme\Apache\tomcat\webapps\cocoon\diplom\index_raw.xml
 -
 pdf
 C:\Programme\Apache\tomcat\webapps\cocoon\diplom\pdf\outfile_main.pdf
 [INFO]: FOP 0.20.1
 [INFO]: building formatting object tree
 [INFO]: [1]
 [INFO]: [1]
 [INFO]: [2]
 [INFO]: [3]
 [INFO]: [1]
 [INFO]: [2]
 [ERROR]: 
 [ERROR]: 
 [ERROR]: 
 [ERROR]: 

 thanks

 =
 
 Daniel Pfuhl
 mailto:[EMAIL PROTECTED]

 __
 Do You Yahoo!?
 Gesendet von Yahoo! Mail - http://mail.yahoo.de

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

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

--
Eric B. Dalquist




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




DO NOT REPLY [Bug 3655] New: - Driver.reset() does not function properly

2001-09-17 Thread bugzilla

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=3655.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=3655

   Summary: Driver.reset() does not function properly
   Product: Fop
   Version: 0.17
  Platform: PC
OS/Version: Windows NT/2K
Status: NEW
  Severity: Normal
  Priority: Other
 Component: general
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


We use FOP to generate pdf reports. A Driver is instantiated to render the pdf, 
after which the driver is reset. When the same driver is reused to render 
another pdf, one document is created containing the first and the new pdf. So 
both reports are appended. So I presume the reset method does not reinitialize 
the internal datastructures properly.

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




Re: OT(?): transcendental functions in XSLT

2001-09-17 Thread Wim Beliën

If you are using xalan, you can add the
xmlns:math=xalan://java.lang.Math namespace
to your xsl document. Then you can use all
methods out of the java.lang.Math object.
like

line x1={math:log(myTag)} y1=0 x2={math:log(myTag)} y2=0/

Although I haven't tried, I think this should also be possible in a  svg
path construction like

path d=M275,175 v-150 a150,150 0 0,0 -{150 * math:sin(myTag)},{150 -
math:sin(myTag)}z
 fill=yellow stroke=blue stroke-width=5 /

Please keep me posted of your results.

++
Wim Beliën
Netherlands Institute of Applied Geoscience TNO
Delft, the Netherlands
tel : +31 15 2696824
email : [EMAIL PROTECTED]
++

- Original Message -
From: Mark [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, September 16, 2001 5:28 PM
Subject: OT(?): transcendental functions in XSLT

 Hi folks,

 sorry for this slightly off topic post but i was hoping someone could
 help me.

 I thought i should be able to produce a very simple xml schema for
 generating pie charts. the idea was that I could use XSLT to transform
 from the pie-chart schema to SVG (and then to import the SVG into FOP).

 It would be preferable to express the size of the pie chart segments as
 percentages, but the SVG Path object requires coordinates on the
 circumferance of a circle.

 The problem is that there don't seem to be any functions in XSLT or
 XPath that let me find the sin() or cosine() of an angle. Am I missing
 something? I thought I could possibly use a transform but I can't seem
 to perform a transform in the middle of a Path.

 I finally decided that maybe if I created a table of degree-to-sin/cos
 mappings I could somehow use the document() function to import this into
 the stylesheet and use an index to search it (ergh) but that doesn't
 seem to work either.

 There's little point in having a pie-chart schema if you have to do the
 calculations yourself anyway.

 So if anyone has any suggestions .. ? I'd certainly be pleased to share
 a pie-chart-XSLT transform if I can get it going.

 As an aside, does anyone know why SVG paths are so (IMHO) brain dead? I
 can't believe that the elements in a path aren't XML elements, it seems
 very strange. (Generating the paths in XSLT is going to be a bit
 painful, even if I can get the sin() of an angle. I dont really see how
 M300,200 h-150 a150,150 0 1,0 150,-150 z qualifies as XML).

 Cheers
 Mark


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



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




FW: cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2001-09-17 Thread Art Welch

Keiron,

I wonder if NULLing _source, _stream, and _reader in Driver.reset() is such
a good idea. For my own use with the PCLRenderer I take advantage of the
stream staying open to concatenate multiple invocations into one output. I
suppose that the desired things could be saved off before calling reset
(since thankfully you do not call close() or anything) and then put them
back after. But this seems like a bit of a nuisance. But maybe I am the only
one that does this. I know that for most of the other renderers it is not
currently possible to concatenate multiple invocations in FOP. Just a
though.

Art

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 17, 2001 9:30 AM
To: [EMAIL PROTECTED]
Subject: cvs commit: xml-fop/src/org/apache/fop/render/xml
XMLRenderer.java


keiron  01/09/17 06:29:53

  Modified:src/org/apache/fop/apps AWTStarter.java
CommandLineOptions.java Driver.java
   src/org/apache/fop/render AbstractRenderer.java
PrintRenderer.java
   src/org/apache/fop/render/awt AWTRenderer.java
   src/org/apache/fop/render/mif MIFRenderer.java
   src/org/apache/fop/render/ps PSRenderer.java
   src/org/apache/fop/render/xml XMLRenderer.java
  Log:
  fixed a few awt render problems and a bit more render refactoring
  
...
  
  Index: Driver.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/apps/Driver.java,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -r1.34 -r1.35
  --- Driver.java   2001/08/22 08:29:17 1.34
  +++ Driver.java   2001/09/17 13:29:52 1.35
  @@ -1,5 +1,5 @@
   /*
  - * $Id: Driver.java,v 1.34 2001/08/22 08:29:17 keiron Exp $
  + * $Id: Driver.java,v 1.35 2001/09/17 13:29:52 keiron Exp $
* Copyright (C) 2001 The Apache Software Foundation. All rights
reserved.
* For details on use and redistribution please refer to the
* LICENSE file included with these sources.
  @@ -230,6 +230,9 @@
*/
   public synchronized void reset() {
   _areaTree = null;
  +_source = null;
  +_stream = null;
  +_reader = null;
   _treeBuilder.reset();
   }
   

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




RE: DO NOT REPLY [Bug 3655] New: - Driver.reset() does not function properly

2001-09-17 Thread Art Welch

Ah... I see that this is probably why Keiron added the null'ing to
Driver.reset(). I still think that nulling the output stream is not really
appropriate - especially since the output stream is not really an internal
structure of Driver (IIRC). I think that Driver does not create the output
stream. If this is correct then it probably should not null it. Actually I
think that this is a bit gray. Certainly it should not close it. But setting
it's reference to it to null... mainly I do not like it because it is
inconvenient for me and if we wanted to support concatenation in the
renderers this could be in the way.

Again... just a thought...

Art

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 17, 2001 11:46 AM
To: [EMAIL PROTECTED]
Subject: DO NOT REPLY [Bug 3655] New: - Driver.reset() does not function
properly


DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=3655.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=3655

   Summary: Driver.reset() does not function properly
   Product: Fop
   Version: 0.17
  Platform: PC
OS/Version: Windows NT/2K
Status: NEW
  Severity: Normal
  Priority: Other
 Component: general
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


We use FOP to generate pdf reports. A Driver is instantiated to render the
pdf, 
after which the driver is reset. When the same driver is reused to render 
another pdf, one document is created containing the first and the new pdf.
So 
both reports are appended. So I presume the reset method does not
reinitialize 
the internal datastructures properly.

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

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




RE: DO NOT REPLY [Bug 3655] New: - Driver.reset() does not func tion properly

2001-09-17 Thread Art Welch

Also if no other action is taken - like creating a new output stream or
something - aren't we asking for a NPE?

-Original Message-
From: Art Welch 
Sent: Monday, September 17, 2001 12:41 PM
To: '[EMAIL PROTECTED]'
Subject: RE: DO NOT REPLY [Bug 3655] New: - Driver.reset() does not func
tion properly


Ah... I see that this is probably why Keiron added the null'ing to
Driver.reset(). I still think that nulling the output stream is not really
appropriate - especially since the output stream is not really an internal
structure of Driver (IIRC). I think that Driver does not create the output
stream. If this is correct then it probably should not null it. Actually I
think that this is a bit gray. Certainly it should not close it. But setting
it's reference to it to null... mainly I do not like it because it is
inconvenient for me and if we wanted to support concatenation in the
renderers this could be in the way.

Again... just a thought...

Art

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 17, 2001 11:46 AM
To: [EMAIL PROTECTED]
Subject: DO NOT REPLY [Bug 3655] New: - Driver.reset() does not function
properly


DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=3655.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=3655

   Summary: Driver.reset() does not function properly
   Product: Fop
   Version: 0.17
  Platform: PC
OS/Version: Windows NT/2K
Status: NEW
  Severity: Normal
  Priority: Other
 Component: general
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


We use FOP to generate pdf reports. A Driver is instantiated to render the
pdf, 
after which the driver is reset. When the same driver is reused to render 
another pdf, one document is created containing the first and the new pdf.
So 
both reports are appended. So I presume the reset method does not
reinitialize 
the internal datastructures properly.

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

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

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




oe

2001-09-17 Thread Hugues REROLLE

Hello

Do you know why the caractere #156; (e in the o)  doesn't work under FOP.

Thank you.


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




RE: Ant FOP task

2001-09-17 Thread Britton, Colin

Check out the build.xml in xml-fop\docs\xml-docs this does what you want
(take xml, apply xsl to make fo and run fop task to make pdf)


rgds
cb


 -Original Message-
 From: Morrison, John [mailto:[EMAIL PROTECTED]]
 Sent: Monday, September 17, 2001 10:03 AM
 To: '[EMAIL PROTECTED]'
 Subject: Ant FOP task
 
 
 Hi All,
 
 Does anybody have a build.xml file which demonstrates how to 
 take xml+xslt
 files and produce a pdf with the ant fop class?
 
 Thanks,
 
 J.
 
 
 ==
 =
 Information in this email and any attachments are 
 confidential, and may
 not be copied or used by anyone other than the addressee, nor 
 disclosed
 to any third party without our permission.  There is no intention to
 create any legally binding contract or other commitment 
 through the use
 of this email.
 
 Experian Limited (registration number 653331).  
 Registered office: Talbot House, Talbot Street, Nottingham NG1 5HF
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
 
 

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




Re: [PATCH] JPG Compression

2001-09-17 Thread Eric Dalquist

Jim,

I found the bug. I imagine this isn't the last time something like this will
come up. JPEGs use a fairly simple header setup to store pertinent
information in the image. The JPEG standard says the image width, height and
color depth should be stored in the FFC0 header the jpeg you have stored the
info in a FFC2 header which I had not heard of. It seems there are many
flavors of jpeg so little fixes like this may be happening for a while.
Attached is a new JpegImage.java which will fix the problem. If you're
interested the change was made on line 81.

-Eric Dalquist

- Original Message -
From: Jim Wright [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, September 16, 2001 11:01 PM
Subject: RE: [PATCH] JPG Compression


 Hey Eric:

 Been working with the patched stuff on and off all day -- still looks
great!

 Attached is a rather junky macintosh-based jpg that demonstrates the
header
 problem. Let me know if you get a fix. Either way, thanks again for the
 patch!

 jw

 -Original Message-
 From: Eric Dalquist [mailto:[EMAIL PROTECTED]]
 Sent: Saturday, September 15, 2001 4:42 PM
 To: [EMAIL PROTECTED]
 Subject: Re: [PATCH] JPG Compression


 JpegImage.java

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


user configuration file

2001-09-17 Thread Kevin Ward


I am trying to work with a separate user configuration file to turn off the 
debugging information that is displayed:


using SAX parser org.apache.xerces.parsers.SAXParser
building formatting object tree
setting up fonts
formatting FOs into areas
  [1]
  [1] [2] [3] [4] [5] [6]
rendering areas to PDF
writing out PDF


I have set 'quiet' to 'true' in the user configuration file and that file 
appears to be correctly parsed when I use 
Options.loadStandardConfiguration() but the user file does not override the 
standard configuration file -- I checked using 
Configuration.dumpConfiguration().  Is this correct, and is there another 
way to turn off the debugging lines (quiet = true)?

Thanks,

Kevin


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




FYI: Fop 0.19 JPEG-Patch

2001-09-17 Thread Don Wellington

It appears to work with FOP 0.19 for people who are
using older versions of FOP. Took my picture intensive
PDF from 35MB to 4MB.

Don


__
Terrorist Attacks on U.S. - How can you help?
Donate cash, emergency relief information
http://dailynews.yahoo.com/fc/US/Emergency_Information/

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




RE: [PATCH] JPG Compression

2001-09-17 Thread Jim Wright

Eric:

More specifically, the header from Photoshop 6.0 for Windows seems to work
the most reliably. Other Photoshop versions will sometimes give the error.

I've yet to install the latest update, but will do so, and test. I'll let
you know how it works out.

Otherwise, the patch seems to be holding up quite well. In an existing FOP
install, we've passed close to 80 or so different images through, all of
which worked very well.

I can't speak to Daniel Pfuhl's issue of longer XSL documents as ours, while
fairly graphics intensive, are only 4-8 pages in length, and the XSL
documents are not all that huge.

Thanks again!

jw

-Original Message-
From: Eric Dalquist [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 17, 2001 12:48 PM
To: [EMAIL PROTECTED]
Subject: Re: [PATCH] JPG Compression


Jim,

I found the bug. I imagine this isn't the last time something like this will
come up. JPEGs use a fairly simple header setup to store pertinent
information in the image. The JPEG standard says the image width, height and
color depth should be stored in the FFC0 header the jpeg you have stored the
info in a FFC2 header which I had not heard of. It seems there are many
flavors of jpeg so little fixes like this may be happening for a while.
Attached is a new JpegImage.java which will fix the problem. If you're
interested the change was made on line 81.

-Eric Dalquist

- Original Message -
From: Jim Wright [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, September 16, 2001 11:01 PM
Subject: RE: [PATCH] JPG Compression


 Hey Eric:

 Been working with the patched stuff on and off all day -- still looks
great!

 Attached is a rather junky macintosh-based jpg that demonstrates the
header
 problem. Let me know if you get a fix. Either way, thanks again for the
 patch!

 jw

 -Original Message-
 From: Eric Dalquist [mailto:[EMAIL PROTECTED]]
 Sent: Saturday, September 15, 2001 4:42 PM
 To: [EMAIL PROTECTED]
 Subject: Re: [PATCH] JPG Compression



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




More on properties

2001-09-17 Thread Peter B. West

I have been thinking about specifying as many of the characteristics of 
properties as possible in static data structures, one way or another. 
One approach is to create, in a non-instantiable class, static final 
arrays containing various data about properties, such as those which are 
contained in Appendix C of the spec.  These arrays are indexed by a set 
of static final ints encoding the set of properties.  These ints are 
derived from a HashMap indexed by the name of the property, and that 
HashMap is the only place in which the property name is used.  It's all 
very C.

Parallel to this class was another which had a couple of accessors and a 
set of member classes corresponding to most of the properties.  In these 
classes, themselves not originally intended for instantiation, were 
arrays of enum values for those properties whose legal values included 
one of a set of enumerated values.  As well as the String array 
containing the value as a String, there is a set of static final ints 
which encode the enumerated values.  That was the motivation for this 
set of classes; to be able to specify such property-specific constants.

This classname is accessed from another array indexed by the property 
integer constant.  I had assumed that, given the name of a class, I 
would be able to get the same access to that class, its fields, arrays 
and methods, through a variable containing the name, as I would by 
naming the class directly in my code.  That's what reflection is all 
about, right?  But I am puzzled as to how to access array elements when 
I don't actually have an array object, just the array class object. 
Arrays seem to be neither fish nor fowl in this scheme.  Can anyone 
point me in the right direction.  I would also like to hear what 
pitfalls there are in accessing class members rather than instance 
members, by such means.

My other requirement for arrays was in connection with property 
specification stacks.  One way to approach the property context for a 
given FO is to use stacks to contain the currently relevant property 
value.  I envisaged a set of stacks, one per property, initialized to 
the initial value of the property. Then, whenever a property is 
specified on an FO element, that value can be pushed onto the stack. 
(whether separate specified, computed and actual values need be stacked 
I don't know.)  At the same time, the FO node gets a list of the 
propeties which have had values pushed.

On the way out, these values are popped.  Values which are inherited, or 
on which inherit is specified, require no modification to the stack; 
non-inherited values for which no inherit is specified require that 
the initial value (available at the bottom of the stack) is pushed and 
noted.  Obviously, these stacks only attain the depth of the FO tree, so 
they are not particularly demanding of memory.  There are currently 247 
FO properties, not including compound expansions.

I thought that I would be good, and think inside the object here, 
putting the individual stacks inside each of the property classes 
mentioned above.  But the difficuties in thinking out the stack access 
are making me lean towards a separate array of stack objects.

All of the above may be of more relevance to the C/C++ project.

Any comments?

Peter
-- 
Peter B. West  [EMAIL PROTECTED]  http://powerup.com.au/~pbwest
Lord, to whom shall we go?


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




Re: OT(?): transcendental functions in XSLT

2001-09-17 Thread Mark Lillywhite

Howdy transformers,

Thanks to those that helped me out. I tried the developerworks article
that Trevor mentioned; the article was for an older version of xalan,
but once I knew where to look I was able to bind to the java.lang.Math
class and now I have transcendentals coming out my ears :)

Anyway I got one wedge of pie to draw now, and a second one draws OK for
areas  50%, so I'm on my way, I'll put the scripts on my web site if I
get them working satisfactorally.

Cheers
Mark



On Tue, 2001-09-18 at 01:40, Wim Beliën wrote:
 If you are using xalan, you can add the
 xmlns:math=xalan://java.lang.Math namespace
 to your xsl document. Then you can use all
 methods out of the java.lang.Math object.
 like
 
 line x1={math:log(myTag)} y1=0 x2={math:log(myTag)} y2=0/
 
 Although I haven't tried, I think this should also be possible in a  svg
 path construction like
 
 path d=M275,175 v-150 a150,150 0 0,0 -{150 * math:sin(myTag)},{150 -
 math:sin(myTag)}z
  fill=yellow stroke=blue stroke-width=5 /
 
 Please keep me posted of your results.
 
 ++
 Wim Beliën
 Netherlands Institute of Applied Geoscience TNO
 Delft, the Netherlands
 tel : +31 15 2696824
 email : [EMAIL PROTECTED]
 ++
 
 - Original Message -
 From: Mark [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Sunday, September 16, 2001 5:28 PM
 Subject: OT(?): transcendental functions in XSLT
 
  Hi folks,
 
  sorry for this slightly off topic post but i was hoping someone could
  help me.
 
  I thought i should be able to produce a very simple xml schema for
  generating pie charts. the idea was that I could use XSLT to transform
  from the pie-chart schema to SVG (and then to import the SVG into FOP).
 
  It would be preferable to express the size of the pie chart segments as
  percentages, but the SVG Path object requires coordinates on the
  circumferance of a circle.
 
  The problem is that there don't seem to be any functions in XSLT or
  XPath that let me find the sin() or cosine() of an angle. Am I missing
  something? I thought I could possibly use a transform but I can't seem
  to perform a transform in the middle of a Path.
 
  I finally decided that maybe if I created a table of degree-to-sin/cos
  mappings I could somehow use the document() function to import this into
  the stylesheet and use an index to search it (ergh) but that doesn't
  seem to work either.
 
  There's little point in having a pie-chart schema if you have to do the
  calculations yourself anyway.
 
  So if anyone has any suggestions .. ? I'd certainly be pleased to share
  a pie-chart-XSLT transform if I can get it going.
 
  As an aside, does anyone know why SVG paths are so (IMHO) brain dead? I
  can't believe that the elements in a path aren't XML elements, it seems
  very strange. (Generating the paths in XSLT is going to be a bit
  painful, even if I can get the sin() of an angle. I dont really see how
  M300,200 h-150 a150,150 0 1,0 150,-150 z qualifies as XML).
 
  Cheers
  Mark
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, email: [EMAIL PROTECTED]
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
 


 PGP signature


RE: [PATCH] JPG Compression

2001-09-17 Thread Jim Wright

Eric:

Latest patch does seem to solve the current header problem quite nicely.

Thanks!

jw

-Original Message-
From: Eric Dalquist [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 17, 2001 12:48 PM
To: [EMAIL PROTECTED]
Subject: Re: [PATCH] JPG Compression


Jim,

I found the bug. I imagine this isn't the last time something like this will
come up. JPEGs use a fairly simple header setup to store pertinent
information in the image. The JPEG standard says the image width, height and
color depth should be stored in the FFC0 header the jpeg you have stored the
info in a FFC2 header which I had not heard of. It seems there are many
flavors of jpeg so little fixes like this may be happening for a while.
Attached is a new JpegImage.java which will fix the problem. If you're
interested the change was made on line 81.

-Eric Dalquist

- Original Message -
From: Jim Wright [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, September 16, 2001 11:01 PM
Subject: RE: [PATCH] JPG Compression


 Hey Eric:

 Been working with the patched stuff on and off all day -- still looks
great!

 Attached is a rather junky macintosh-based jpg that demonstrates the
header
 problem. Let me know if you get a fix. Either way, thanks again for the
 patch!

 jw

 -Original Message-
 From: Eric Dalquist [mailto:[EMAIL PROTECTED]]
 Sent: Saturday, September 15, 2001 4:42 PM
 To: [EMAIL PROTECTED]
 Subject: Re: [PATCH] JPG Compression



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