Re: Error when building FOP svn 1800269 - cannot find symbol symbol getNameForGID(int)

2017-06-29 Thread John Brown


On Thursday, June 29, 2017 8:49 AM, Simon Stener wrote:
>
> Hi,
> 
> Maybe you have an old fontbox jar on your classpath?

Yes, that was it. I had fontbox-1.3.1.jar in fop-svn\fop\lib as well as 
fontbox-2.0.4.

Regards,
John Brown.

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Error when building FOP svn 1800269 - cannot find symbol symbol getNameForGID(int)

2017-06-29 Thread John Brown
john@john-pc /c/downloads/fop-svn/fop
$ ant
Buildfile: c:\downloads\fop-svn\fop\build.xml
Trying to override old definition of task javac
Trying to override old definition of task junit

init-avail:
 [echo] --- Apache FOP 2.3.0-SNAPSHOT [1999-2017] 

 [echo] See build.properties and build-local.properties for additional 
build settings
 [echo] Apache Ant(TM) version 1.9.6 compiled on June 29 2015
 [echo] VM: 25.112-b15, Oracle Corporation
 [echo] JAVA_HOME: c:/progra~1/java/jdk1.8.0_112
 [echo] JAI Support NOT Present
 [echo] JCE Support PRESENT
 [echo] JUnit Support NOT Present - Committers are required to have JUnit 
working
 [echo] XMLUnit Support NOT Present - you can get it from 
http://xmlunit.sourceforge.net

init:

codegen:
 [echo] Generating the java files from xml resources
 [xslt] Transforming into 
c:\downloads\fop-svn\fop\build\gensrc\org\apache\fop\fonts\base14

compile-java:
[javac] Compiling 211 source files to c:\downloads\fop-svn\fop\build\classes
[javac] warning: [options] bootstrap class path not set in conjunction with 
-source 1.6
[javac] 
c:\downloads\fop-svn\fop-core\src\main\java\org\apache\fop\render\ps\Type1FontFormatter.java:115:
 error: cannot find symbol
[javac] String name = 
font.getCharset().getNameForGID(gid.getKey());
[javac]^
[javac]   symbol:   method getNameForGID(Integer)
[javac]   location: class CFFCharset
[javac] 
c:\downloads\fop-svn\fop-core\src\main\java\org\apache\fop\render\ps\Type1FontFormatter.java:160:
 error: cannot find symbol
[javac] String mapping = font.getCharset().getNameForGID(gid);
[javac]   ^
[javac]   symbol:   method getNameForGID(int)
[javac]   location: class CFFCharset
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
[javac] 2 errors
[javac] 1 warning

BUILD FAILED
c:\downloads\fop-svn\fop\build.xml:351: Compile failed; see the compiler error 
output for details.

Total time: 11 seconds

john@john-pc /c/downloads/fop-svn/fop
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Re: [FOP] Cannot add cropped pdf as fo:external-graphic

2016-11-06 Thread John Brown
On Sunday, November 6, 2016 2:59 PM,Simon Steiner wrote:

> Hi,
> 
> Can you report any bugs on jira https://issues.apache.org/jira/browse/FOP
> 
> Thanks

https://issues.apache.org/jira/browse/FOP-2660

Regards,
John Brown.


-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



[FOP] Cannot add cropped pdf as fo:external-graphic

2016-11-06 Thread John Brown
My original pdf (created by printing to PDF Creator 
(http://www.pdfforge.org/pdfcreator) works as an external graphic in test.fo. 
This PDF has 1-inch borders which I removed using Briss 
(http://briss.sourceforge.net/). The cropped PDF image is not displayed in 
test.pdf. I think that it is present but invisible because when I look at the 
document's properties (Fonts), I see two fonts but lorem_cropped.pdf has 1 font.

To reproduce:


http://www.w3.org/1999/XSL/Format;>
  

  

  
  

  
Hello, World!
  
  
 
  

  



lorem.pdf is a "Lorem ipsum" paragraph printed to PDF Creator on letter
 size paper.
lorem_cropped.pdf is lorem.pdf cropped to contain just the paragraph
with minimal whitespace.
test.pdf is the output of
C:\>fop test.fo test.pdf

I am using fop SVN r1768353 (2016-10-20 17:03:59 -0500) and the fop
PDF Images plugin from
https://dist.apache.org/repos/dist/dev/xmlgraphics/binaries/ on
Windows 10.

Regards,
John Brown.




lorem.pdf
Description: lorem.pdf


lorem_cropped.pdf
Description: lorem_cropped.pdf


test.pdf
Description: test.pdf

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org

Custom hyphenation files

2016-02-12 Thread John Brown

I was tring to follow the instructions for manually installing OFFO
hyphenation files.
 https://xmlgraphics.apache.org/fop/1.0/hyphenation.html shows
how to use the source files (not the compiled fop-hyph.jar). I did the
following:

1) I renamed $FOP_HOME/lib/fop-hyph.jar.
2) I copied en_GB.xml from offo-hyphenation.zip to /path/to/book.xml
3) Added the following entry to fop.xconf:
  en_GB
4) Then
  cd /path/to/book.xml
  xsltproc -o book.fo xsl-ns/fo/docbook.xsl book.xml
  fop -c fop.xconf book.fo book.pdf

The result was:
INFO: Rendered page #1.
Exception in thread "main" java.lang.StackOverflowError
    at org.apache.fop.hyphenation.TernaryTree.insert(TernaryTree.java:191)
    at org.apache.fop.hyphenation.TernaryTree.insert(TernaryTree.java:244)
...[line above repeated several times]

        at org.apache.fop.hyphenation.TernaryTree.insert(TernaryTree.java:244)

Two questions:

1) What am I doing wrong? By the way, it is fop-svn 1728886.

2) How do you choose the location of en_GB.xml? I tried setting
hyphenation-base. https://xmlgraphics.apache.org/fop/2.0/configuration.html
says that relative URIs for hyphenation-base are evaluated relative to the base
URI of the configuration file. Does that mean that mean that hyphenation-base
would have to be set to ..//full/path/to/en_GB-location?

For what it is worth, I set ..

Regards,
John Brown.
   
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: Performance improvement suggestions

2013-01-16 Thread John Brown
Nels wrote:


 I have updated to 1.1 now.
 Adding fopFactory.setStrictValidation(false); directly into the fop script
 gives me this error:
 fop[263]: 0403-057 Syntax error at line 1 : `(' is not expected.

 The actual line added is:
 FOP_OPTS=fopFactory.setStrictValidation(false);

 Appreciate your advice.



Put an ESCAPE before the brackets:
FOP_OPTS=fopFactory.setStrictValidation\(false\);

Regards,
John Brown.   
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: Performance improvement suggestions

2013-01-16 Thread John Brown
Nels wrote:

 Thanks John, doing that I now get this error:

 Exception in thread main java.lang.NoClassDefFoundError:
snip/
 Could not find the main class: fopFactory.setStrictValidation(false).
 Program will exit.


I was not really paying atention to what you were trying to do.
The previous instruction was just to get the shell to accept
brackets. However, FOP_OPTS is for specifying parameters to java,
for example -Xms64m to set the initial size of the heap to 64 MB.
You cannot insert a function call there.

Regards,
John Brown.   
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: Performance improvement suggestions

2013-01-16 Thread John Brown
Nels wrote:

 I can't get the fop option -q for quiet mode to work. Running from the
 command line I tried:
 fop -q -xml xml_file.xml -xsl xsl_file.xsl -pdf pdf_file.pdf

 But I still receive warnings. Can I suppress these this way?



The warnings that you are seeing are displayed on the standard error
output. You can redirect it like this on Linux:
$ fop -q ... 2 /dev/null
or like this on Windows:
C:\fop -q 2 nul

Are you sure that you want to suppress those warnings? Consider
a DocBook document that I am working on now. When not suppressing
warnings, I get among the output:

...
Font ZapfDingbats,normal,700 not found. Substituting with ZapfDingbats,normal
,400.
Couldn't find hyphenation pattern for lang=en.
...

With -q, the font warning goes away, but the hyphenation warning
remains. If I suppress the hyphenation warning, I will not know that
there is a problem.

Regards,
John Brown.   
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: FOP-Trunk revision 1428722 unit test fails

2013-01-07 Thread John Brown
Simon Steiner wrote:

 Hi,

 You need extra jars in classpath to run the unit tests. To just build you
 can use ant package.

 Some of these might be needed if you want to run tests:

 # lib/barcode4j-fop-ext.jar
 # lib/barcode4j.jar
 # lib/checkstyle-5.5-all.jar
 # lib/fop-hyph.jar
 # lib/jacocoagent.jar
 # lib/jacocoant.jar
 # lib/jai_imageio.jar
 # lib/junit-4.10.jar
 # lib/zxing-core-1.7.jar

 Thanks


Hello Simon,

Of these, I have /path/to/fop-trunk-checkout/build/fop-hyph.jar
and /mingw/local/lib/junit-4.8.1.jar (not v 4.10) where /mingw/local
is where I installed ant-1.8.4.

`ant package' works. Thanks.

Regards,
John Brown.   
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



FW: FOP-Trunk revision 1428722 unit test fails

2013-01-04 Thread John Brown
Hello All,

The following error occurred while building FOP-Trunk 1428722:

[junit] Testsuite: org.apache.fop.intermediate.IFTestCase
[junit] Tests run: 10, Failures: 0, Errors: 1, Time elapsed: 0.346 sec
[junit]
[junit] Testcase: runTest[5](org.apache.fop.intermediate.IFTestCase):
Caused an ERROR
[junit] Expected XPath expression to evaluate to 'true', but got '' (XPath:
/descendant::if:text[1]/@hyphenated)
[junit] java.lang.RuntimeException: Expected XPath expression to evaluate to
'true', but got '' (XPath: /descendant::if:text[1]/@hyphenated)
[junit] at org.apache.fop.layoutengine.EvalCheck.doCheck(EvalCheck.java:
86)
[junit] at org.apache.fop.layoutengine.EvalCheck.check(EvalCheck.java:65
)
[junit] at org.apache.fop.intermediate.IFTester.doIFChecks(IFTester.java
:80)
[junit] at org.apache.fop.intermediate.IFTestCase.runTest(IFTestCase.jav
a:103)
[junit]
[junit]

BUILD FAILED
C:\Users\John\Downloads\Open_Source\fop-svn\build.xml:820: Tests failed

However, it seems to have built fop*.jar. What is the significance
of the failed test?

Regards,
John Brown.   
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: FOP-Trunk revision 1428722 unit test fails

2013-01-04 Thread John Brown
I forgot to mention:

JDK version: jdk1.6.0_38.
O/S: Windows 8 Pro.
Ant version: 1.8.4.

Regards,
John Brown.   
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: table of contents page number not showing in RTF output

2012-05-24 Thread John Brown

Hello Glenn,

Glenn Adams wrote:

 On Wed, May 23, 2012 at 2:21 PM, Chen Yang  wrote:

 Hey guys,
 
I am converting xml to rtf using fop trunk ver. page numbers (table of
content to be exact) showing up as # symbol but field codes are
correct, if I print the document, Word will display the numbers, what
is it that I need to do to display the numbers immediately?
 
 
 
example:
 
CONFLICT MANAGEMENT#
DEVELOPING OTHERS#
FOSTERING LEARNING...#
IMPACT AND INFLUENCE...#

 

 what do you mean by Word will display the numbers?



He probably means that when he opens the document for the
first time, # is displayed instead of page numbers, but if he
refreshes the table of contents, the numbers will appear.

Regards,
John Brown.

  
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



Re: FOP embedded in Java app not rendering graphics

2010-12-21 Thread John Brown
Furst, Tom tom.furst at rcmt.com writes:

 
 Forgot the attachment. Here it is.
 
 
 Chris,
 
 There a number of warnings, but none that relate missing images. 


There are *36* occurrences of Image not found in your log file, such as:

 SEVERE: Image not found. URI: illustrations/KH-Logo-large1.jpg. 
 (No context info available)

How could you say that none of the warnings relate to missing images?
Let me guess: you grepped WARNING and you did not find these because
they are SEVERE.

Now that you have reported your problem accurately, I am sure that
an expert will be able to help you in short order. Until then, I
believe that the problem is that your fo:external-graphic tag
should look like this:

fo:external-graphic src=url(path/to/image/jpg) blah-blah-blah /

Is that what you have? This brings me to my second point.

What you should really submit is a minimal XSL-FO file that causes the
problem.


Regards,
Alias John Brown.


-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: fox:external-document not showing all pages

2010-04-29 Thread John Brown

bonekrusher wrote:


 Thanks John,

 I double checked and reloaded the files on the PC that its not working and
 still having the problem. Perhaps the issue lies in the pdf...

 Any other thoughts?


Apart from that, I don't have any ideas. I still believe that the
difference must be in the FOP installation on the machines. If you
are sure that both machines are using:

1) The same version of FOP
2) The same version of the PDF image plugin - what version
are you using by the way?
3) FOP is being invoked the same way - for example, your
CLASSPATH is set on both machines such that an older version
of (1) and (2) is not being found before the current version

then I don't know what it could be. If the same PDF works on
one machine and not the other, it cannot be the PDF.

Regards,
Alias John Brown.
  
_
Hotmail has tools for the New Busy. Search, chat and e-mail from your inbox.
http://www.windowslive.com/campaign/thenewbusy?ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_1
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: fox:external-document not showing all pages

2010-04-29 Thread John Brown

J.Pietschmann wrote: 
 On 29.04.2010 19:31, John Brown wrote:
 I still believe that the
 difference must be in the FOP installation on the machines. If you
 are sure that both machines are using:

 1) The same version of FOP
 [etc.]
 
 JRE vendor and version and in some cases even the OS
 may be relevant too. In particular JREs on Linux tend
 to have weird bugs which had caused FOP to malfunction
 for some input in the past.
 
 J.Pietschmann
 


Indeed. I assumed that the original poster would have checked
the Java versions. I believe that the Sun JRE is the one that is
supported by the FOP developers.

I have never had a problem using the Sun
JRE on Windows or Linux. I once wasted a lot of time on Ubuntu
Linux because I did not realise that even though the Sun JRE
was installed, it was not the default. FOP did not work with
the default JRE.

Regards,
Alias John Brown.
  
_
The New Busy is not the too busy. Combine all your e-mail accounts with Hotmail.
http://www.windowslive.com/campaign/thenewbusy?tile=multiaccountocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_4
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: fox:external-document not showing all pages

2010-04-28 Thread John Brown


bonekrusher wrote:


 Hi I am using fox:external-document to add a 8 page pdf to my pdf output via
 Apache FOP. On my machine (PC) the pdf is added and all 8 pages show up,
 however on another machine (PC) only the first page shows up.

 I am using all the exact files on both machines (via svn).

 here is the fo code:

 
 xmlns:fox=http://xmlgraphics.apache.org/fop/extensions; content-type=pdf
 src=C:\stylesheets\forms.pdf/

 Any thoughts why this would work on one machine and not another?

 Thanks,
 --

This is interesting. I thought that it was only capable of adding one page
(the first?) of a multi-page PDF. You probably have a more recent version of
the PDF image plug-in on the machine that works.

YOu can get the plug-in at:
http://www.jeremias-maerki.ch/development/fop/index.html

Regards,
Alias John Brown.
  
_
Hotmail is redefining busy with tools for the New Busy. Get more from your 
inbox.
http://www.windowslive.com/campaign/thenewbusy?ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_2
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: Using a PDF as an Image

2009-08-05 Thread John Brown

Jeff Steffanina wrote:

 I have a finished form that contains all my graphics.  It is a 
 PDF.


 I want to print it and add all the applicable data. I have been 
 doing this with JPG files with great success.


 I am getting the error: No ImagePreloader found




 I see the notes about using an SVG. Is it possible to use a PDF
 for this purpose?


 Is there one reference point where it clearly describes the 
 process?

http://www.jeremias-maerki.ch/download/fop/pdf-images/

Version 1.3 is the latest stable version. The archive contains a README.

Regards,
Alias John Brown.



_
Express your personality in color! Preview and select themes for Hotmail®. 
http://www.windowslive-hotmail.com/LearnMore/personalize.aspx?ocid=PID23391::T:WLMTAGL:ON:WL:en-US:WM_HYGN_express:082009
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: FOP issue - Flow 'xsl-region-body' does not map to the region-body in page-master 'blank'.

2009-06-07 Thread John Brown

Danushka Menikkumbura wrote:

 Alias John Brown wrote:


 Did you remember to set fop1.extensions = 1?


 Where should I set this?.

 Thanks,
 Danushka

 --

Anywhere, I suppose. Wherever you set your other parameters
(such as double.sided.), or you can set it on your XSLT
processor's command line.

Regards,
Alias John Brown.

_
Lauren found her dream laptop. Find the PC that’s right for you.
http://www.microsoft.com/windows/choosepc/?ocid=ftp_val_wl_290
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: FOP issue - Flow 'xsl-region-body' does not map to the region-body in page-master 'blank'.

2009-06-06 Thread John Brown


Danushka Menikkumbura wrote:



 Hi,

 I am trying to use FOP in one of my projects. At the moment PDF
 generation is done by XEP and I just want to replace that with
 FOP. My program can generate .fo files by some XSLT processing
 mechanism. I get this error as mentioned in the subject when I
 try to generated the corresponding PDF files using FOP. When
 Googled, I found that this could be solved by setting 
 double.sided to 0. Unfortunately in my case this works for 
 some files but not for some other.


 Please help me solve this issue.

 Thanks,
 Danushka

 --

Did you remember to set fop1.extensions = 1?

Regards,
Alias John Brown

_
Windows Live™ SkyDrive™: Get 25 GB of free online storage.
http://windowslive.com/online/skydrive?ocid=TXT_TAGLM_WL_SD_25GB_062009
-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org



RE: Japanese Char Issues

2009-04-06 Thread John Brown


Not sure what happened to the attachment, but here it is:


_
Rediscover Hotmail®: Get e-mail storage that grows with you. 
http://windowslive.com/RediscoverHotmail?ocid=TXT_TAGLM_WL_HM_Rediscover_Storage1_042009

test.pdf
Description: Adobe PDF document

-
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org

RE: Fop Warnings

2008-10-02 Thread John Brown

Vincent Hennebert wrote:
 Hi,
 
 Just a little precision, for the sake of correctness.
 
 John Brown wrote:
 Tom Browder wrote:
 
 
 One more thing: the XSL-FO produced by FOP does not contain any
 new line characters,
 
 Strictly speaking it’s not FOP that produces the XSL-FO, it’s the XSLT
 processor configured in your Java installation, that is called by FOP.
 You can configure another XSLT processor, or even use a non-Java one
 (e.g., xsltproc) in a prior step. For the rest you’re definitely right.

You're right, of course. As a matter of fact, I use xsltproc.
_
Stay up to date on your PC, the Web, and your mobile phone with Windows Live.
http://clk.atdmt.com/MRT/go/msnnkwxp1020093185mrt/direct/01/
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Fop Warnings

2008-10-01 Thread John Brown

Tom Browder wrote:
 
 On Wed, Oct 1, 2008 at 1:11 PM, Vincent Hennebert  wrote:
 Hi Tom,

 Tom Browder wrote:
 ...
 Is there a way to get fop to point to the source of the warnings?

 You have to write the XSL-FO produced by the XSLT processor into a file.
 ...
 For debugging purpose you can proceed in two steps:
fop -xml document.xsl -xsl sytesheet.xsl -foout document.fo
fop -fo document.fo -pdf document.pdf
 ...
 Note that that won't point you to the DocBook source, unfortunately.
 From the FO file you'll have to figure out what part of the DocBook
 source that corresponds to. Tedious, but I'm not sure there is any
 
 Thanks for the help, Vincent.
 
 -Tom
 

One more thing: the XSL-FO produced by FOP does not contain any
new line characters, so FOP will tell you that the error is on line 1 at
position 7458 o something similar. You can format the XSL-FO using
'xmllint --format' before running FOP. xmllint is part of the libxml2
project.
_
Get more out of the Web. Learn 10 hidden secrets of Windows Live.
http://windowslive.com/connect/post/jamiethomson.spaces.live.com-Blog-cns!550F681DAD532637!5295.entry?ocid=TXT_TAGLM_WL_domore_092008
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Adding Verdana font in Linux and registering it with FOP 0.94

2008-09-29 Thread John Brown
nancy_b nancy_brndt at yahoo.com writes:

 
 
 Hi John,
 
 Thanks for your response! Unfortunately, the auto-detect capability did not
 work for me. By the way, where is the main configuration file that FOP uses
 to process default fonts and other parameters?
 
 Thanks in advance!
 Nancy

Apparently, the defaults are built-in. You have to make your own
configuration file and run 
fop -c custom-conf-file rest-of-command-line

Copy the sample file at There is a sample file at
fop-folder/conf/fop.xconf and edit it. My previous
post shows where to add (or uncomment) the necessary tags.

Also note the suggestion by another poster to use the directory
tag, which is necessary if verdana.ttf is not located in one of the
standard places on your system.

I have used such Windows TrueType fonts as Arial, Times New Roman,
Calibri and Cambria like this on my Kubuntu Hardy Heron system.




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



RE: Adding Verdana font in Linux and registering it with FOP 0.94

2008-09-28 Thread John Brown

Nancy Brandt wrote:
 
 Hi guys,
 
 I am working in Debian Linux.
 
 I would like to change the default body font to Verdana. As Bob Stayton
 writes in his book about Docbook XML, I should run the following command
 after locating the needed font:
 
 # java -cp /home/nancy/fop-0.94/build/fop.jar;
 /usr/share/java/avalon-framework.jar; /usr/share/java/commons-logging.jar;
 /usr/share/java/commons-io.jar org.apache.fop.fonts.apps.TTFReader
 /usr/share/fonts/truetype/verdana.ttf verdana_metric.xml
 
 But the following error occurs:
 Usage: gij [OPTION] ... CLASS [ARGS] ...
   to invoke CLASS.main, or
gij -jar [OPTION] ... JARFILE [ARGS] ...
   to execute a jar file
 Try `gij --help' for more information.
 bash: /usr/share/java/avalon-framework.jar: Permission denied
 bash: /usr/share/java/commons-logging.jar: Permission denied
 bash: /usr/share/java/commons-io.jar: Permission denied
 
 What do I do wrong? :-(
 
 Thanks in advance!
 Nancy
 

These are basic questions, but:

1) Do you keep the FOP jar filesin /usr/share/java? They are
normally found in fop\build or fop\lib.
2) Are these the actual names of the files? My FOP jar files
   usually have a version number suffix: 
   avalon-framework-4.2.0.jar, commons-io-1.3.1.jar, ...

_
Stay up to date on your PC, the Web, and your mobile phone with Windows Live.
http://clk.atdmt.com/MRT/go/msnnkwxp1020093185mrt/direct/01/
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Adding Verdana font in Linux and registering it with FOP 0.94

2008-09-28 Thread John Brown

Nancy Brandt wrote:


 Hi dear John,

 You always try to help me :-)

 Well, when I run '$ locate  fop.jar' for example, I get the following
 results:

 /home/nancy/fop-0.94/build/fop.jar
 /usr/bin/build/fop.jar
 /usr/share/java/fop.jar

 I've tried to use the files located in the 'lib' directory (those with
 version number), but it did not change anything.
 My best wishes,
 Nancy


FOP can automatically detect fonts now. Try using auto-detect
instead of the font metrics file. See
http://xmlgraphics.apache.org/fop/0.94/fonts.html#register
for details.

The relevant parts of my fop configuration file look like this:



...
  

   
...

  

...


...
  


Nancy Brandt wrote:


 Hi dear John,

 You always try to help me :-)

 Well, when I run '$ locate  fop.jar' for example, I get the following
 results:

 /home/nancy/fop-0.94/build/fop.jar
 /usr/bin/build/fop.jar
 /usr/share/java/fop.jar

 I've tried to use the files located in the 'lib' directory (those with
 version number), but it did not change anything.
 My best wishes,
 Nancy


FOP can automatically detect fonts now. Try using auto-detect
*instead of* the font metrics file.  If your fonts are not in the
standard locations, you can use the  tag. See
http://xmlgraphics.apache.org/fop/0.94/fonts.html#register
for details.

The relevant parts of my fop configuration file look like this:



...
  

   
...

  

...


...
  

_
Stay up to date on your PC, the Web, and your mobile phone with Windows Live.
http://clk.atdmt.com/MRT/go/msnnkwxp1020093185mrt/direct/01/
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Adding Verdana font in Linux and registering it with FOP 0.94

2008-09-28 Thread John Brown
Nancy Brandt wrote:


 Hi dear John,

 You always try to help me :-)

 Well, when I run '$ locate  fop.jar' for example, I get the following
 results:

 /home/nancy/fop-0.94/build/fop.jar
 /usr/bin/build/fop.jar
 /usr/share/java/fop.jar

 I've tried to use the files located in the 'lib' directory (those with
 version number), but it did not change anything.
 My best wishes,
 Nancy


I keep forgetting not to write XML in Hotmail.

FOP can automatically detect fonts now. Try using auto-detect
instead of the font metrics file. See
http://xmlgraphics.apache.org/fop/0.94/fonts.html#register
for details.

The relevant parts of my fop configuration file look like this:

renderers
renderer mime=application/pdf
...
  fonts
!-- embedded fonts --
   
...
auto-detect/
  /fonts

...
/renderer

...
  /renderers



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



Re: Draft Mode background image - should it work in off-the-shelf fop ?

2008-09-19 Thread John Brown
Kerry, Richard richard.kerry at siemens.com writes:

 
 
 
  
 I've recently been 
 trying to produce a draft version of a document, originating in 
 DocBook.
  
snip/

 However, I am not seeing the background watermark, nor any 'Draft' 
 strings in the corners which I think I've read should be 
 there.
 
  
snip/
  
 Uncetainly,
 Richard.
  
  
 

Set the draft.mode parameter to yes. If you want to use a local image
as the watermark, set draft.watermark.image to /path/to/local/image-file.



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



Re: Draft Mode background image - should it work in off-the-shelf fop ?

2008-09-19 Thread John Brown
Kerry, Richard richard.kerry at siemens.com writes:

 
 
 
 And - the documentation for draft.watermark.image says it's a URI; doesn't
that mean it's not
 /path/to/local/image-file but file:///path/to/local/image-file (actually
 file:///C:/path/to/local/image-file.png as this is on Windows)
 
 Uncertainly,
 Richard.


I see that you have solved your problem, but for what it's worth,
you are probably right. I've never tested it. 
I usually keep my images in a directory within the directory
containing the XML source, so that I can use relative paths
such as images/draft.png.




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



Re: Trying to programmatically add fonts

2008-09-05 Thread John Brown
eborisow eborisow at yahoo.com writes:

 
 
 Hi,
 
 I am trying to embed fonts in a program.  I was able to get my fonts to work
 when I run fop.bat standalone.  Here were the relevant lines from the config
 xml.
 

snip
Contents of config file
/snip
 
 Like I said, this one works.  Now, in an application, I am trying to do the
 same using the API.
 
snip
Code to do above programatically
/snip

snip
Contents of log
/snip 

 So, I am obviously doing something wrong.  Can someone see what the problem
 is?

According to the documentation at 
http://xmlgraphics.apache.org/fop/0.95/fonts.html#basics

It is currently not possible to easily configure fonts from Java code.

I assume that this means that it is not impossible, but I have no idea
how. Hopefully an expert will turn up soon.

 
 Thanks,
 Eric





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



RE: Adding support for PDF images to FOP

2008-08-07 Thread John Brown


Jeremias Maerki wrote:


 I have verified that version 1.2 still works with FOP 0.95.

 If you get the message No ImagePreloader found for *.pdf it means that
 the plug-in isn't in the classpath. Please note that on Windows, it's
 not enough to put some JARs in FOP's lib directory if you use fop.bat.
 You'll have to edit this file and add the two JARs
 (fop-pdf-images-1.2.jar and PDFBox-0.7.4-dev.jar). fop.cmd is a little
 smarter as is the shell script on Unixes.


That fixed it. I really should have tried that. Anyway, thanks.

By the way, there is no fop.cmd in fop-0.95-bin.zip; only fop and fop.bat.



_
Reveal your inner athlete and share it with friends on Windows Live.
http://revealyourinnerathlete.windowslive.com?locale=en-usocid=TXT_TAGLM_WLYIA_whichathlete_us
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: FOP - FONTS - expl. verdana

2008-08-06 Thread John Brown
lmhelp lmbox at wanadoo.fr writes:

 
 
 Thank you Jeremias.
 
 Hi everyone,
 
 So, I've upgraded to fop-0.95.
 
 I've added the following line to the ../fop-0.95/conf/fop.xconf file:
   directoryC:/Program Files/fop-0.95/fonts_lea//directory
 (Maybe this is not the right file to update... ?)


1) Did you run 'fop -c ../fop-0.95/conf/fop.xconf FO-file PDF-file'?
If you did and it didn't work, add the auto-detect tag:

fonts
  directoryC:/Program Files/fop-0.95/fonts_lea//directory
  auto-detect
/fonts

Also, if the font is in C:\Windows\Fonts, then you might not
even need the directory tag, as I would imagine that
C:\Windows\Fonts is one of the standard locations checked when
auto-detect is enabled.

2) Maybe it does not like the space in Program Files. Try the
short name instead:

C:/Progra~1/fop-0.95_lea

I don't think that the trailing / is necessary, but don't quote me.
I don't have a trailing / in my fop.xconf.




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



Re: Font substitution not working with Ghostscript font

2008-08-05 Thread John Brown
Hello Jeremias,

Jeremias Maerki wrote:

 
 Your configuration is slightly wrong. It should look like this:

You fixed the problem. Thanks.

I saw your other post in which you said that FOP will now automatically
replace font weight 400 with 200. I will try it soon, but just for my
understanding, could you answer the following questions related to [1],
[2], and [3] below?

 ?xml version=1.0 encoding=UTF-8?
 fop
   fonts

[1] substitutions

   substitution

[2] from font-family=URW Bookman L font-weight=400/

 to font-family=URW Bookman L font-weight=200/
   /substitution
 /substitutions
   /fonts
   renderers
 renderer mime=application/pdf
   fonts

[3] directory recursive=true/usr/local/share/fonts/directory

 auto-detect/
   /fonts
 /renderer
   /renderers
 /fop
 


 The substitutions are defined for all renderers.

1) I see that the substitutions element was in the wrong place.

   I'm not sure how I could have made such a basic mistake.
   Feature request: Would it be possible for FOP to validate
   against a DTD, so that the user would know that his configuration
   is bad?

 Plus see my changes to the from/to elements.

2) Are you saying that I need to use the numerical weights instead of
   normal, bold, etc.? I was not really using question marks; I 
   was just indicating the values that I varied during my trial-and-error
   process.

   By the way, how would I know that the weight or URW Bookman L Light
   is 200? I thought that fontforge would have told me, but the font info
   dialog box showed the weight as Regular.

 
 I've also fixed a couple of problems in Trunk found while looking into
 this:
 http://svn.apache.org/viewvc?rev=682616view=rev
 http://svn.apache.org/viewvc?rev=682617view=rev
 

I tested with 682617, and it seems to be OK now.

 Now I need to check why the font lookup didn't automatically replace the
 weight 400 with weight 200. I thought I had added that at some point.
 

I will try your latest update in a little while.




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



Re: Font substitution not working with Ghostscript font

2008-08-05 Thread John Brown
Hello Jeremias,

Jeremias Maerki dev at jeremias-maerki.ch writes:

 
 On 05.08.2008 12:09:37 John Brown wrote:
  Hello Jeremias,
  
  Jeremias Maerki wrote:
  
   
   Your configuration is slightly wrong. It should look like this:
  
  [3] directory recursive=true/usr/local/share/fonts/directory

Font substitution without substitution also works.

Just one more thing: I forgot to ask question 3. I take it that
/usr/share/fonts/type1/gsfonts is one of the standard places that
FOP searches for fonts, so I did not need a directory entry?


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



Font substitution not working with Ghostscript font

2008-08-04 Thread Alias John Brown

I have been trying to use the URW Bookman L font, which is one of the
Ghostscript fonts (b018012l.pfb). Apache FOP recognises it only when it is
bold.
More accurately, it uses the Demi Bold font when Bold is requested.
Howevere, it does not use the Light font when Normal is requested,
which is what I want.

When I run fc-list, I get the following information:

$ fc-list | grep URW\ Book
URW Bookman L:style=Demi Bold
URW Bookman L:style=Light
URW Bookman L:style=Light Italic
URW Bookman L:style=Demi Bold Italic

I wrote a small FO file:

?xml version=1.0 encoding=UTF-8?
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
xmlns:fox=http://xmlgraphics.apache.org/fop/extensions; font-family=URW
Bookman L
  fo:layout-master-set
fo:simple-page-master master-name=A4 page-height=29.7cm
page-width=21cm margin=2cm
  fo:region-body/
/fo:simple-page-master
  /fo:layout-master-set
  fo:page-sequence master-reference=A4
fo:flow flow-name=xsl-region-body
  fo:block
fox:destination internal-destination=hello/
  /fo:block
  fo:block id=hello-normal font-weight=normalHello World
Normal!/fo:block
  fo:block id=hello-bold font-weight=boldHello World
Bold!/fo:block
  fo:block id=hello-italic font-style=italicHello World
Italic!/fo:block
  fo:block id=hello-bold-italic font-weight=bold
font-style=italicHello World Bold Italic!/fo:block
/fo:flow
  /fo:page-sequence
/fo:root

I wrote fop.xconf like this:


$ fop -c fop.xconf font.fo font.pdf
Aug 4, 2008 6:35:36 PM org.apache.fop.events.LoggingEventListener
processEvent
WARNING: Font URW Bookman L,normal,400 not found. Substituting with
any,normal,400.
Aug 4, 2008 6:35:36 PM org.apache.fop.events.LoggingEventListener
processEvent
WARNING: Font URW Bookman L,normal,700 not found. Substituting with URW
Bookman L,normal,600.
Aug 4, 2008 6:35:37 PM org.apache.fop.events.LoggingEventListener
processEvent
WARNING: Font URW Bookman L,italic,400 not found. Substituting with
any,italic,400.
Aug 4, 2008 6:35:37 PM org.apache.fop.events.LoggingEventListener
processEvent
WARNING: Font URW Bookman L,italic,700 not found. Substituting with URW
Bookman L,italic,600.
Aug 4, 2008 6:35:37 PM org.apache.fop.events.LoggingEventListener
processEvent
WARNING: Destination: Unresolved ID reference hello found.


I tried various combinations of the following:

substitutions
   substitution
 from font-family=URW Bookman L font-weight=normal
font-style=normal/
 to   font-family=URW Bookman L font-weight=? font-style=?/
   /substitution
 /substitutions

but nothing worked.

I made a font metrics file. Within the font metric file, I changed the name
of the font
from URWBookmanL-Ligh to URW Bookman L, and in the fop.xconf, I wrote:

font-triplet name=URW Bookman L style=normal weight=normal/


This seemed to work, but it was very tiresome. Normal, Bold and Bold Italic
are
working now, so I only have to do it one more time to make Italic work.

How can I get font substitution to work?

My complete fop.xconf is:
?xml version=1.0 encoding=UTF-8?
fop
 renderers
 renderer mime=application/pdf
 fonts
 substitutions
   substitution
 from font-family=URW Bookman L font-weight=normal
font-style=normal/
 to   font-family=URW Bookman L font-weight=? font-style=?/
   /substitution
 /substitutions
!--
 
  font-triplet name=URW Bookman L style=normal weight=normal/
 
--
!-- directory recursive=true/usr/local/share/fonts/directory --
 directory recursive=true/usr/share/fonts/type1/gsfonts/directory
 auto-detect/ 
 /fonts
 /renderer
 /renderers
/fop


I am using fop-trunk r 682557 (Jul 31, 2008).



-- 
View this message in context: 
http://www.nabble.com/Font-%3Csubstitution%3E-not-working-with-Ghostscript-font-tp18823889p18823889.html
Sent from the FOP - Users mailing list archive at Nabble.com.


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



Re: Problem with Asian Language fonts

2008-07-09 Thread John Brown
My XML is being totally scrambled. I meant to write:

Don't use the chararcter entity  a m p ;, which means that
you want a literal ampersand character to appear in the output.

That is, instead of  a m p ; # 2 1 2 7 1 ;, write  # 2 1 2 7 1 ;



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



Re: Named destination: hyperlink to target in external PDF jumps to first page

2008-05-22 Thread John Brown
Andreas Delmelle andreas.delmelle at telenet.be writes:

 
 On May 21, 2008, at 17:26, John Brown wrote:
 
 
  2) Is there a way to specify a relative path (current directory) with
  file:// syntax? file:f2.pdf does not work.

snip/

 Depending on the answer to my above question, you could try:
 
 file://./f2.pdf#hello
 
 HTH!
 
 Cheers
 
 Andreas
 

I got a different error.when I clicked the hyperlink, it immediately
displayed Timeout on server. Anyway, a post in this mailing-list
(http://article.gmane.org/gmane.text.xml.fop.user/25889) says that
file: urls are always absolute, so it seems that I am out of luck.




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



Named destination: hyperlink to target in external PDF jumps to first page

2008-05-21 Thread John Brown

Hello All,

I am trying to use named destinations to create a file f1.pdf with
a hyperlink to targets in another file f2.pdf. The hyperlink jumps
to the first page in f2.pdf. I found a message in another newsgroup
that said that this feature does not work for local PDF files; it works
only for PDFs served by a web server. 

1) Is this true?

2) Is there a way to specify a relative path (current directory) with
file:// syntax? file:f2.pdf does not work. I get a message box saying:
The file or folder smb://f2.pdf/#hello does not exist.
I have to write file:///path/to/f2.pdf, which would not be meaningful
on another computer.

I am currently on Kubuntu Hardy Heron (8.10), although the PDFs
are being created for Windows users. I am using fop-trunk 653186.




  

  

  
  

  Hello World!
 Hello, Book 2
  

  





  

  

  
  

  Hello World!

  
  

  

  
  This is the Hello World that I want!

  


_
Make every e-mail and IM count. Join the i’m Initiative from Microsoft.
http://im.live.com/Messenger/IM/Join/Default.aspx?source=EML_WL_ MakeCount
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Named destination: hyperlink to target in external PDF jumps to first page

2008-05-21 Thread John Brown

John Brown johnbrown105 at hotmail.com writes:

 
 
 Hello All,
 
 I am trying to use named destinations to create a file f1.pdf with
 a hyperlink to targets in another file f2.pdf. The hyperlink jumps
 to the first page in f2.pdf. I found a message in another newsgroup
 that said that this feature does not work for local PDF files; it works
 only for PDFs served by a web server. 
 
 1) Is this true?
 
 2) Is there a way to specify a relative path (current directory) with
 file:// syntax? file:f2.pdf does not work. I get a message box saying:
 The file or folder smb://f2.pdf/#hello does not exist.
 I have to write file:///path/to/f2.pdf, which would not be meaningful
 on another computer.
 
 I am currently on Kubuntu Hardy Heron (8.10), although the PDFs
 are being created for Windows users. I am using fop-trunk 653186.
 

Sorry - I keep forgetting that Hotmail strips out all XML.
I was trying top include my FO files.

!-- f1.fo --
?xml version=1.0 encoding=UTF-8?
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
xmlns:fox=http://xmlgraphics.apache.org/fop/extensions; font-family=Cambria
  fo:layout-master-set
fo:simple-page-master master-name=A4 page-height=29.7cm
page-width=21cm margin=2cm
  fo:region-body/
/fo:simple-page-master
  /fo:layout-master-set
  fo:page-sequence master-reference=A4
fo:flow flow-name=xsl-region-body
  fo:block id=helloHello World!
 fo:basic-link external-destination=url('file:f2.pdf#hello')Hello,
Book 2/fo:basic-link
  /fo:block
/fo:flow
  /fo:page-sequence
/fo:root


!-- f2.fo --
?xml version=1.0 encoding=UTF-8?
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
xmlns:fox=http://xmlgraphics.apache.org/fop/extensions; font-family=Cambria
  fo:layout-master-set
fo:simple-page-master master-name=A4 page-height=29.7cm
page-width=21cm margin=2cm
  fo:region-body/
/fo:simple-page-master
  /fo:layout-master-set
  fo:page-sequence master-reference=A4
fo:flow flow-name=xsl-region-body
  fo:block id=page1Hello World!/fo:block
/fo:flow
  /fo:page-sequence
  fo:page-sequence master-reference=A4
fo:flow flow-name=xsl-region-body
  fo:block
fox:destination internal-destination=hello/
  /fo:block
  fo:block id=helloThis is the Hello World that I want!/fo:block
/fo:flow
  /fo:page-sequence
/fo:root



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



Re: Problem using Lucida Console font

2008-05-08 Thread John Brown
Jeremias Maerki dev at jeremias-maerki.ch writes:

 
 I have an Ubuntu 8.04 in a VM to play with. So I copied over the Bodoni
 fonts from that ZIP file you indicated. However, the ZIP does not
 contain any AFM files for the Bodoni font, just the PFB and PFM.

You are right. The timestamp was different for the AFM files (2007 as 
opposed to 1990), so I looked inside one and saw:

Comment AFM Generated by Ghostscript/pf2afm

 Looking
 at these fonts, BTW, gives me a strong impression that these are illegal
 and altered copies (Some of the fonts give a BBS phone number). Anyway,
 I had no problems

Oh well...

 auto-detecting and using the fonts with FOP 0.95beta.

fop-trunk also works.

 If you've installed the fonts in a location other than the directory
 mentioned in the following Java class:

http://svn.apache.org/repos/asf/xmlgraphics/fop/trunk/src/java/org/apache/fop/fonts/autodetect/UnixFontDirFinder.java
 you'll have to use the directory element in the font configuration.


It worked. All fonts that I have tried so far (TT and Type1) can now
be used. By the way, the FOP-trunk online documentation says:

Font registration via XML font metrics file is still supported and is still
necessary if you want to use a TrueType Collection (*.ttc). Direct support for
TrueType collections may be added later.

This should be updated, as I can use such fonts. Cambria is an MS font that
comes with Office 2007, but, for whatever reason, it is included in the
latest PowerPoint viewer, the installer of which runs on Linux. Cambria.ttf
contains Cambria and Cambria Math (which I know only because FOP
told me) and I can select either one.

Thanks.

snip/


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



Identify list in subject line

2008-05-08 Thread John Brown
Hello all,

I think that messages on the fop-users mailing list should identify
themselves in the subject line, like most mailing lists. For example:

[fop-users] Problem using Lucida Console font



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



RE: Identify list in subject line

2008-05-08 Thread John Brown

Andreas Delmelle wrote:
 
 On May 8, 2008, at 12:08, Jeremias Maerki wrote:
 
 On 08.05.2008 12:01:51 John Brown wrote:
 Hello all,

 I think that messages on the fop-users mailing list should identify
 themselves in the subject line, like most mailing lists. For example:

 [fop-users] Problem using Lucida Console font

 ezmlm adds the List-Post header entry. You can use that for  
 filtering
 (assuming that was the cause for this message).
 
 The recipient would also be a reasonable choice, no?
 

I normally filter on the 'To:' line, but I have not got around to
creating a filter for fop-users yet. I wanted to identify those
messages just by looking. It's not a big deal.
_
Make Windows Vista more reliable and secure with Windows Vista Service Pack 1.
http://www.windowsvista.com/SP1?WT.mc_id=hotmailvistasp1banner
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem using Lucida Console font

2008-05-07 Thread John Brown
Andreas Delmelle andreas.delmelle at telenet.be writes:

 
 
 On May 7, 2008, at 10:30, Andreas Delmelle wrote:
  snip /
 
  Can you try to checkout and build FOP 0.95 (*), and see if that  
  helps already? 

snip/

 If you still need it, the URL to use with SVN for 0.95 head:
 http://svn.apache.org/repos/asf/xmlgraphics/fop/branches/fop-0_95
 
 Cheers
 
 Andreas
 


I am on Linux (Kubuntu Gutsy Gibbon (7.10?)). Auto-detection of
fonts does not work most of the time. For example, I cannot use
Bodoni (Type 1 font - the download page says that it is shareware,
but neither the site nor the ZIP file says who should be paid).
I downloaded the font at
http://www.winsite.com/bin/Info?50017011.

Scribus lets me embed this font in a PDF, and Scribus itself
says that it is strict about the fonts that it allows to be
embedded, so I assume that nothing is wrong with the font.

'fc-list Bodoni' gives:
Bodoni:style=Bold
Bodoni:style=Normal-Italic
Bodoni:style=Normal

'ls /usr/local/share/fonts/bodoni*' gives:
/usr/local/share/fonts/bodoni.afm   /usr/local/share/fonts/bodonii.pfb
/usr/local/share/fonts/bodonib.afm  /usr/local/share/fonts/bodonii.pfm
/usr/local/share/fonts/bodonib.pfb  /usr/local/share/fonts/bodoni.pfb
/usr/local/share/fonts/bodonib.pfm  /usr/local/share/fonts/bodoni.pfm
/usr/local/share/fonts/bodonii.afm

AFM, PFM and PFB files are all present.

However fop-trunk svn (653186, 2008-05-03) and fop-0.95beta svn
(653537, 2008-05-05) both say:
WARNING: Font 'Bodoni,normal,400' not found. Substituting 
with 'any,normal,400'.

I used the same FO and fop.xconf that was posted.

I noticed that fop printed a lot of warnings like:

May 7, 2008 2:05:22 PM org.apache.fop.fonts.truetype.TTFFile determineAscDesc
WARNING: Ascender and descender together are larger than the em box. This 
could lead to a wrong baseline placement in Apache FOP.

and

May 7, 2008 2:05:35 PM org.apache.fop.fonts.truetype.TTFFile 
guessVerticalMetricsFromGlyphBBox
WARNING: xHeight value could not be determined. The font may not work as 
expected.
May 7, 2008 2:05:35 PM org.apache.fop.fonts.type1.PFMFile loadExtMetrics
WARNING: Size of extension block was expected to be 52 bytes, but was 0 bytes.

The messages do not say which fonts cause the warnings. I do
not know if it matters.

By the way, I have found a few Type 1 fonts that fop
recognises, but no TrueType fonts so far.



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



Feature request: hyperlinks from one PDF to another

2008-04-26 Thread John Brown

Hello all,

I want to be able to construct a hyperlink to an hotspot within 
another PDF file. DocBook has an  tag that allows this,
but it does not work with FOP because:

Neither FOP nor Xml2PDF write ihe original ID values from the XSLT
 process to the PDF file. So although a link with a fragment identifier
 is properly formed, the ID value it points to does not exist in the
 destination PDF.

Can this behaviour be changed?

Perhaps more appropriate on a PDF list:

Is there a tool (free as in free beer) that will let me discover the IDs that
have been assigned to hotspots in a PDF, so that I  may use them in my
DocBook document?
_
Back to work after baby–how do you know when you’re ready?
http://lifestyle.msn.com/familyandparenting/articleNW.aspx?cp-documentid=5797498ocid=T067MSN40A0701A
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Including an image as a page

2008-04-17 Thread John Brown
Jeremias Maerki dev at jeremias-maerki.ch writes:

 On the block containing the fo:external-graphic add these properties:
 font-size=0 line-height=0 break-before=page break-after=page

When I made the changes, I saw that the page seemed to be indented, so I
added 'start-indent=0 end-indent=0' also. The appearance seems to be
perfect now, but I still get one warning (I got 2 originally):

WARNING: Part/page 0 overflows the available area in block-progression
dimension. (fo:block-container, location: 317/58)
How can I avoid this warning? Can I ignore it?

The relevant block now looks like this:
fo:block id=id2489196 text-align=center line-height=0
  font-size=0 break-before=page break-after=page 
  start-indent=0 end-indent=0
  fo:external-graphic src=url(doc1-page1.pdf) 
   width=8.5in height=11in 
   content-width=8.5in content-height=11in 
   
   text-align=center display-align=center/
/fo:block



snip/
 
 A better solution might be to investigate if you can create a custom
 extension for DocBook so you could still use fox:external-document from
 inside DocBook. But I don't know enough about DocBook to know if that is
 even doable.
 

Now that I know the FO that works, I will probably try to see if I can
extend my custom stylesheet to add the necessary attributes. I think that
this way is easier because it does not disturb the structure of the DocBook
document. 

The DocBook docs explain how to add elements to the Docbook DTD, but
considering that I don't really know what I am doing, I would not want to
take on that task.



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



Re: Including an image as a page

2008-04-17 Thread John Brown
Jeremias Maerki dev at jeremias-maerki.ch writes:

 

snip/
 the warning is about the
 block-container further up in your file. The height of the
 block-container is set to 0.01in and its contents (the fo:leader) grow
 beyond that. Just remove the leader.
 

All warnings are gone now. Thanks.


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



Re: Including an image as a page

2008-04-16 Thread John Brown
The fox:external-document extension works. Since it seems that I will
probably have to post-process the fo file, I need to decide whether 
it is easier to:

1) insert the fox:external-document at an appropriate place, so that 
   the table of contents and any other hyperlinks still work
2) Fix the FO so that I do not get the following warnings:

Apr 16, 2008 6:29:20 PM org.apache.fop.layoutmgr.PageBreakingAlgorithm
updateData2
WARNING: Part/page 0 overflows the available area in block-progression
dimension. (fo:block-container, location: 317/58)
Apr 16, 2008 6:29:20 PM
org.apache.fop.layoutmgr.inline.LineLayoutManager$LineBreakingAlgorithm
updateData2
WARNING: Line 1 of a paragraph overflows the available area by more than
50
points. (fo:block, location: 324/52)
Apr 16, 2008 6:29:20 PM org.apache.fop.layoutmgr.PageBreaker$1
notifyOverflow
WARNING: Content of the region-body on page 2 overflows the available
area in
block-progression dimension. (fo:page-sequence, location: 65/312)

I have created extdoc.tar.bz2 and uploaded it to:
http://download.yousendit.com/4487E58200672F10

The archive contains:
Bytes  Filename Description
28823  doc1-page1.pdf   External document that I am trying to import

18854  extdoc.foFO produced by DocBook stylesheets + xsltproc
trimmed as much as possible

39827  extdoc.pdf   Result of fop extdoc.fo extdoc.pdf. You will
note the result is not correct.

16150  images/draft.png Background image in document

I did what I thought was necessary to set all borders to 0 in the
DocBook XML file.

Can you tell me how to fix the FO so that all the space on the 
8in X 11in page is available for the external document?



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



Re: table-layout warning message

2008-04-03 Thread John Brown
 nancy_b wrote:

  WARNING: table-layout=fixed and column-width unspecified = falling back
  to proportional-column-width(1)

nancy_b nancy_brndt at yahoo.com writes:

snip

 I need some customization that says:
 
 if table-layout=fixed, use proportional column width...
 

Hello nancy_b,

Did you ever find a solution to this problem?


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



RE: FOP 0.94 bin - Severe Exceptions on Solaris Box

2008-03-20 Thread John Brown

Newkid wrote:
 
 Support Cell,
 
 Could you please advice what needs to be done to run the FOP 0.94 on a
 solaris box? I have set the CLASSPATH; Convert the FOP.sh file for UNIX; etc
 for all necessary files but when I tried to run FOP on Solaris it's showing
 the below error:
 

Maybe your conversion is incorrect?

 *
 -bash-3.00$ Fop -xml abc.xml -xsl abc.xsl -pdf abc.pdf
 
[output snipped - prints help screen as if fop were called without parameters]
 
 Mar 20, 2008 3:28:36 PM org.apache.fop.cli.Main startFOP
 SEVERE: Exception
 java.lang.IllegalArgumentException: Error creating InputHandler object.
 at
 org.apache.fop.cli.CommandLineOptions.createInputHandler(CommandLineOptions.java:818)
 at
 org.apache.fop.cli.CommandLineOptions.parse(CommandLineOptions.java:165)
 at org.apache.fop.cli.Main.startFOP(Main.java:154)
 at org.apache.fop.cli.Main.main(Main.java:197)
 **
 I even tried ./Fop -d -xml abc.xml -xsl abc.xsl -pdf abc.pdf as suggested in
 other but still NO use. Please help me out and let me know what needs to be
 done more to get rid of this issue.
 
 The same application is working fine on WINDOWS box but when I deployed on
 SOLARIS, I received the above mentioned error.

 Any tip would be deeply appreciated.!
 Newkid


Apparently you used the Windows distribution and tried to convert it
to Unix. Why not download the Unix distribution instead? The filename
ends with .tar.gz.

It is possible that they are *not* identical except for the scripts, and
it is possible that your modification of the Cygwin fop.sh to Unix was
not correct.

 
_
Shed those extra pounds with MSN and The Biggest Loser!
http://biggestloser.msn.com/
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: FOP 0.94 - Unkown Error

2008-03-18 Thread John Brown

bonekrusher wrote:

 
 This may sound like a crazy question; Is this the only location to download
 the FOP trunk?
 
 http://svn.apache.org/repos/asf/xmlgraphics/fop/trunk/
 
 How how I download the all the files at once?
 
 Thanks
 
 

http://xmlgraphics.apache.org/fop/dev/tools.html#svn

Remember, though, that you are going to have to compile it.
The instructions were given to you in a previous post:

 Sure, you just have to build it before. See the following page for 
 building instructions:
 http://xmlgraphics.apache.org/fop/trunk/compiling.html

You are going to have to download the Java Development Kit, Apache
Ant, and Subversion, if you don't already have them.

One thing: when you get to the point where you should set environment
variables, you should probably

set JAVACMD=

for a peaceful life.

_
Connect and share in new ways with Windows Live.
http://www.windowslive.com/share.html?ocid=TXT_TAGHM_Wave2_sharelife_012008
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Cannot build simple DOcBook document with fop svn 637076; works with 0.94

2008-03-16 Thread John Brown


Andreas Delmelle wrote:

 What I could do, is make the necessary adjustments to your FO to
 avoid the error, but I'm not certain if the result is still what you
 expect: see attachment FO + result PDF.

 HTH!


I finally looked at your PDF and saw that it looked just the way that it
ought to look in my opinion. The table of contents and chapter 1 both
start on odd-numbered pages.

I have a few questions.

1) Can you explain briefly what changes you made to the FO? It seems
that there are *no* line breaks in the FO produced by fop. The only
editor that I have that can edit it is vi. I was hoping to format the FO
by displaying it in Internet Explorer, and then Copy+Paste into a text
editor, but the '+' and '-' used to expand and collapse the tree are
also copied.

2) Did you have to search the whole file looking for the tag(s) that
needed to be changed, or did you have to make only one change?
That is, if my FO had 500 pages instead of 5 pages, how much work
would it be to edit the FO by hand?

3) What did you use to edit the FO?

_
Need to know the score, the latest news, or you need your Hotmail®-get your 
fix.
http://www.msnmobilefix.com/Default.aspx
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Cannot build simple DOcBook document with fop svn 637076; works with 0.94

2008-03-16 Thread John Brown





Andreas Delmelle wrote:

 On Mar 16, 2008, at 08:46, John Brown wrote:
 
 Hi John,
 
 
  I finally looked at your PDF and saw that it looked just the way  
  that it
  ought to look in my opinion. The table of contents and chapter 1 both
  start on odd-numbered pages.
 
  I have a few questions.
 
  1) Can you explain briefly what changes you made to the FO?
 
 As I recall, the only small things I altered were:
 - remove the region-name property from the fo:region-body in the  
 very first fo:simple-page-master
 - on that same fo:region-body, set the margin-bottom and -top such  
 that the region has zero height
 - a bit further on, there were some fo:static-contents that mapped  
 to the 'blank body' region; I commented those out.
 
[snip]

I suppose that this means that I could fix the problem by modifying the
Docbook stylesheets (not easy with my Hello, world! knowledge), but
which is wrong, fop or the stylesheets?
 
By the way, I just discovered that xmllint --format can indent the FO.

_
Need to know the score, the latest news, or you need your Hotmail®-get your 
fix.
http://www.msnmobilefix.com/Default.aspx

Ant unable to locate tools.jar when building FOP trunk

2008-03-15 Thread John Brown

Hello All,

I am on Windows XP, and I have the following packages installed:

JDK 1.6 in c:\program files\java\jdk1.6.0_03
apache-ant-1.7.0 in c:\program files\utils\apacahe-ant-1.7.0
fop-0.94 in c:\program files\utils\fop-0.94
fop svn (svn 637076) in c:\downloads\utils\fop

I set my environment variables as follows:

set JAVA_HOME=c:\progra~1\java\jdk1.6.0_03
set ANT_HOME=c:\progra~1\utils\apacahe-ant-1.7.0
set CLASSPATH=
set 
PATH=%PATH%;C:\Progra~1\Dev\Git\cmd;c:\progra~1\utils\apache-ant-1.7.0\bin;c:\progra~1\
Java\jdk1.6.0_03\bin

I did not add fop to my path because I have two versions. My PATH is correct;
I can run fop and ant just by typing 'fop' and 'ant'.

When I try to build fop, I get the following output:

C:\Downloads\Utils\fopant
Unable to locate tools.jar. Expected to find it in C:\Program Files\Java\jre1.6.
0_03\lib\tools.jar
/**/
/* Why does it say this? I set JAVA_HOME to my JDK directory; see below  */
/**/
Buildfile: build.xml

init-avail:
 [echo] --- Apache FOP svn-trunk [1999-2007] ---
-
 [echo] See build.properties and build-local.properties for additional build
 settings
 [echo] Apache Ant version 1.7.0 compiled on December 13 2006
 [echo] VM: 1.6.0_03-b05, Sun Microsystems Inc.
 [echo] JAVA_HOME: c:\progra~1\java\jdk1.6.0_03
  //
  /* See ? */
  //
 [echo] Jimi Support NOT Present
 [echo] JAI Support NOT Present
 [echo] JCE Support PRESENT
 [echo] JUnit Support NOT Present - Committers are required to have JUnit wo
rking
 [echo] XMLUnit Support NOT Present - you can get it from http://xmlunit.sou
rceforge.net

init-filters-jdk14:
 [echo] Use GraphicsConfiguration adapter for JDK 1.4.



In the end, I had to copy tools.jar to the directory where ant expected to find 
it.

1) How can I make ant look for tools.jar in the right place?

2) DO I need to be concerned about the things that are NOT Present?
_
Shed those extra pounds with MSN and The Biggest Loser!
http://biggestloser.msn.com/
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Cannot build simple DOcBook document with fop svn 637076; works with 0.94

2008-03-15 Thread John Brown

Hello All,

Please see the attached archive book2.tgz, which contains:

book2.xml - Minimal DocBook file
book2.fo - Generated from book.xml using DocBook stylesheets with xsltproc



I tried to convert the .fo to PDF with fop-0.94 and fop-trunk. My installed 
packages are:

DocBook DTD 4.1.2
DocBook XSL Stylesheets 1.62.0
JDK 1.6.0_03
fop-0.94 and fop svn (revision 637380)
xsltproc - Using libxml 20627, libxslt 10120 and libexslt 813

It works with fop-0.94, but fop-trunk gives the following errors:
C:\Downloads\Utils\fopfop c:\msys\tmp\book2.fo c:\msys\tmp\book2.pdf
Mar 15, 2008 5:56:56 AM org.apache.fop.cli.Main startFOP
SEVERE: Exception
java.io.FileNotFoundException: c:\msys\tmp\book2.pdf (The process cannot access
the file because it is being used by another process)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.(Unknown Source)
at java.io.FileOutputStream.(Unknown Source)
at org.apache.fop.cli.Main.startFOP(Main.java:161)
at org.apache.fop.cli.Main.main(Main.java:197)

C:\Downloads\Utils\fopfop c:\msys\tmp\book2.fo c:\msys\tmp\book2.pdf
Mar 15, 2008 5:57:17 AM org.apache.fop.fonts.FontInfo notifyFontReplacement
WARNING: Font 'Symbol,normal,700' not found. Substituting with 'Symbol,normal,40
0'.
Mar 15, 2008 5:57:17 AM org.apache.fop.fonts.FontInfo notifyFontReplacement
WARNING: Font 'ZapfDingbats,normal,700' not found. Substituting with 'ZapfDingba
ts,normal,400'.
Mar 15, 2008 5:57:18 AM org.apache.fop.cli.Main startFOP
SEVERE: Exception
java.lang.IllegalStateException: Flow 'xsl-region-body' does not map to the regi
on-body in page-master 'blank'. FOP presently does not support this.
at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:217)
at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:125)
at org.apache.fop.cli.Main.startFOP(Main.java:166)
at org.apache.fop.cli.Main.main(Main.java:197)

-

java.lang.IllegalStateException: Flow 'xsl-region-body' does not map to the regi
on-body in page-master 'blank'. FOP presently does not support this.
at org.apache.fop.layoutmgr.PageProvider.cacheNextPage(PageProvider.java
:275)
at org.apache.fop.layoutmgr.PageProvider.getPage(PageProvider.java:221)
at org.apache.fop.layoutmgr.PageProvider.getPage(PageProvider.java:185)
at org.apache.fop.layoutmgr.PageSequenceLayoutManager.createPage(PageSeq
uenceLayoutManager.java:139)
at org.apache.fop.layoutmgr.AbstractPageSequenceLayoutManager.makeNewPag
e(AbstractPageSequenceLayoutManager.java:289)
at org.apache.fop.layoutmgr.AbstractPageSequenceLayoutManager.doForcePag
eCount(AbstractPageSequenceLayoutManager.java:370)
at org.apache.fop.area.AreaTreeHandler.finishPrevPageSequence(AreaTreeHa
ndler.java:186)
at org.apache.fop.area.AreaTreeHandler.startAbstractPageSequence(AreaTre
eHandler.java:199)
at org.apache.fop.area.AreaTreeHandler.startPageSequence(AreaTreeHandler
.java:194)
at org.apache.fop.fo.pagination.PageSequence.startOfNode(PageSequence.ja
va:114)
at org.apache.fop.fo.FOTreeBuilder$MainFOHandler.startElement(FOTreeBuil
der.java:300)
at org.apache.fop.fo.FOTreeBuilder.startElement(FOTreeBuilder.java:168)
at org.apache.xalan.transformer.TransformerIdentityImpl.startElement(Tra
nsformerIdentityImpl.java:1072)
at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Sour
ce)
at org.apache.xerces.xinclude.XIncludeHandler.startElement(Unknown Sourc
e)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unkn
own Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContent
Dispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Un
known Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Sour
ce)
at org.apache.xalan.transformer.TransformerIdentityImpl.transform(Transf
ormerIdentityImpl.java:484)
at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:214)
at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:125)
at org.apache.fop.cli.Main.startFOP(Main.java:166)
at org.apache.fop.cli.Main.main(Main.java:197)

I don't have to use the svn version, of course, but since bugs are being fixed 
and
features added all the time ...

How can I make xsltproc generate FO that will be accepted by fop trunk? Probably
by upgrading my stylesheets? My DocBook DTD and stylesheets are not nearly
the most current versions. I use these particular versions because they are able
to build the HTML documentation for an open-source package that I use.


_
Need to know the score, the latest news, or you need your Hotmail®-get your 
fix.
http://www.msnmobilefix.com/Default.aspx

book2.tgz
Description: Binary data

RE: Ant unable to locate tools.jar when building FOP trunk

2008-03-15 Thread John Brown


Andreas Delmelle wrote:

 On Mar 15, 2008, at 11:44, John Brown wrote:

 Hi

 I am on Windows XP, and I have the following packages installed:

 
 When I try to build fop, I get the following output:

 C:\Downloads\Utils\fopant
 Unable to locate tools.jar. Expected to find it in C:\Program Files
 \Java\jre1.6.
 0_03\lib\tools.jar
 /**/
 /* Why does it say this? I set JAVA_HOME to my JDK directory; see
 below */
 /**/

 In the end, I had to copy tools.jar to the directory where ant
 expected to find it.

 1) How can I make ant look for tools.jar in the right place?

 Just a hunch, but could it have something to do with the abbreviated
 path (C:\Program Files - C:\progra~1) in the JAVA_HOME variable?

 Try setting it to the full path. Windows XP has no issues with a
 command like 'set JAVA_HOME=c:\program files\java...'.


It didn't work. I have no knowledge of debugging Java, so I can't begin
to track down this error myself. I found the following in the WHATSNEW
file in the ant directory under Fixed bugs:

* Ant failed to locate tools.jar if the jre directory name wasn't all
  lowercase.  Bugzilla Report 25798.

Just in case, I went in the Registry and changed JavaHome to lower case
everywhere, but it didn't help. I have compiled fop trunk before without
a problem, so I have no idea
what went wrong. Anyway, I have a workaround, so I won't worry about it,
although a solution is still welcome if anybody finds one.

_
Helping your favorite cause is as easy as instant messaging. You IM, we give.
http://im.live.com/Messenger/IM/Home/?source=text_hotmail_join
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Ant unable to locate tools.jar when building FOP trunk

2008-03-15 Thread John Brown

Andreas Delmelle wrote:

 
 On Mar 15, 2008, at 12:51, John Brown wrote:
 
 Hi John
 
 C:\Downloads\Utils\fopant
 Unable to locate tools.jar. Expected to find it in C:\Program Files
 \Java\jre1.6.
 0_03\lib\tools.jar
 /**/
 /* Why does it say this? I set JAVA_HOME to my JDK directory; see
 below */
 /**/

 In the end, I had to copy tools.jar to the directory where ant
 expected to find it.

 1) How can I make ant look for tools.jar in the right place?

 Just a hunch, but could it have something to do with the abbreviated
 path (C:\Program Files - C:\progra~1) in the JAVA_HOME variable?

 Try setting it to the full path. Windows XP has no issues with a
 command like 'set JAVA_HOME=c:\program files\java...'.


 It didn't work.
 
 Hmm... Can you try running 'ant -diagnostics', and see what gives? It  
 will give you a lot of details about the internal state, used JVM  
 etc... Hopefully, this will provide you with a clue.
 
 
 Cheers
 
 Andreas
 

Under System properties I see:
java.runtime.name : Java(TM) SE Runtime Environment
sun.boot.library.path : c:\program files\java\jre1.6.0_03\bin

Whenever a java directory appears in any of the other system properties
it is always the jre directory. I will uninstall all Java software, and install
only the JDK. That should fix it. Unfortunately, I don't have a saved copy
of the JDK installation, and the Java website is offline for maintenance
right now. If, for whatever reason, they both need to be installed,
then I will install the JDK lst. That should make it the default Java 
installaion.
_
Connect and share in new ways with Windows Live.
http://www.windowslive.com/share.html?ocid=TXT_TAGHM_Wave2_sharelife_012008
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Cannot build simple DocBook document with fop svn 637076; works with 0.94

2008-03-15 Thread John Brown



Andreas Delmelle wrote:

 On Mar 15, 2008, at 12:21, John Brown wrote:

 Hi

 I tried to convert the .fo to PDF with fop-0.94 and fop-trunk. My
 installed packages are:

 DocBook DTD 4.1.2
 DocBook XSL Stylesheets 1.62.0
 JDK 1.6.0_03
 fop-0.94 and fop svn (revision 637380)
 xsltproc - Using libxml 20627, libxslt 10120 and libexslt 813

 It works with fop-0.94, but fop-trunk gives the following errors:
 C:\Downloads\Utils\fopfop c:\msys\tmp\book2.fo c:\msys\tmp\book2.pdf
 Mar 15, 2008 5:56:56 AM org.apache.fop.cli.Main startFOP
 SEVERE: Exception
 java.io.FileNotFoundException: c:\msys\tmp\book2.pdf (The process
 cannot access
 the file because it is being used by another process)

 This seems like a familiar issue to me. Did you have the PDF open in
 another application, perhaps?

Oops. Yes, Acrobat Reader locked the file. I was concerned about the
Illegal State exceptions, which seemed to be complaining about the FO.


 
 SEVERE: Exception
 java.lang.IllegalStateException: Flow 'xsl-region-body' does not
 map to the regi
 on-body in page-master 'blank'. FOP presently does not support this.

 Also a familiar one: in XSL-FO it is possible to define a page-master
 with a region-body with region-name other than the one to which the
 fo:flow maps, for blank pages. FOP currently has a small problem with
 that.


Not that it means anything to me; I'm still at the Hello world stage :),
but thanks anyway.

 How can I make xsltproc generate FO that will be accepted by fop
 trunk? Probably
 by upgrading my stylesheets?

 My experience with Docbook is severely limited I'm afraid, so
 unfortunately I cannot tell you how to make it behave this way...
 Upgrading to Docbook 1.7x seems like it's worth a shot.


Fop trunk works with the updated stylesheets. Book2.pdf was produced
with fop-0.94 and the FO from the old stylesheet without warnings.
Book2b.pdf was produced with fop trunk and the new stylesheet with the
following warnings:

Mar 15, 2008 8:27:58 AM org.apache.fop.fonts.FontInfo notifyFontReplacement
WARNING: Font 'Symbol,normal,700' not found. Substituting with 'Symbol,normal,40
0'.
Mar 15, 2008 8:27:58 AM org.apache.fop.fonts.FontInfo notifyFontReplacement
WARNING: Font 'ZapfDingbats,normal,700' not found. Substituting with 'ZapfDingba
ts,normal,400'.

Recently, I saw some messages about font configuration, so between the archives
and the FOP documentation, I should be able to understand the warnings.

I have attached both PDF files. Note that book2.pdf has 5 pages (one is blank)
while book2b.pdf has 4 pages. I am not sure which one, if any, is what the
author intended. The author did not provide a PDF.

I think that, assuming duplex printing,  the Table of Contents,as well as each
chapter, should start on an odd-numbered page. Neither PDF meets this
requirement. Still, it is a minimal example, and maybe it is up to the author
to specifically insert blank pages.



_
Climb to the top of the charts! Play the word scramble challenge with star 
power.
http://club.live.com/star_shuffle.aspx?icid=starshuffle_wlmailtextlink_jan

book2.pdf
Description: Adobe PDF document


book2b.pdf
Description: Adobe PDF document
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

RE: Ant unable to locate tools.jar when building FOP trunk

2008-03-15 Thread John Brown

Andreas Delmelle wrote:


 On Mar 15, 2008, at 13:59, John Brown wrote:

 Hi John,


 Can you try running 'ant -diagnostics', and see what gives? It
 will give you a lot of details about the internal state, used JVM
 etc... Hopefully, this will provide you with a clue.

 Under System properties I see:
 java.runtime.name : Java(TM) SE Runtime Environment
 sun.boot.library.path : c:\program files\java\jre1.6.0_03\bin

 Whenever a java directory appears in any of the other system
 properties
 it is always the jre directory. I will uninstall all Java software...


 In the meantime, I re-tested the setup on my Windows machine, and the
 only way in which I was able to reproduce your issue was when the
 JAVA_HOME was set to a folder that actually did not contain the JDK

[snip]

 So (no offense), can you re-check? Are you *absolutely* sure the
 JAVA_HOME variable points to an existing JDK location (no typos
 whatsoever?).


 Cheers

 Andreas


I thought of that, but that's not it:

C:\Downloads\Utils\fopdir %JAVA_HOME%
 Volume in drive C has no label.
 Volume Serial Number is A8F9-5B90

 Directory of c:\program files\java\jdk1.6.0_03

26/10/2007  01:58 PM  .
26/10/2007  01:58 PM  ..
26/10/2007  01:58 PM  bin
25/09/2007  01:33 AM 2,539 COPYRIGHT
26/10/2007  01:58 PM  db
26/10/2007  01:57 PM  include
26/10/2007  01:58 PM  jre
26/10/2007  01:58 PM  lib
26/10/2007  01:57 PM13,471 LICENSE
26/10/2007  01:57 PM19,780 LICENSE.rtf
26/10/2007  01:58 PM 7,665 PATCH.ERR
24/09/2007  11:20 PM26,650 README.html
24/09/2007  11:20 PM24,572 README_ja.html
24/09/2007  11:20 PM18,764 README_zh_CN.html
24/09/2007  11:20 PM   180,676 THIRDPARTYLICENSEREADME.txt
   8 File(s)294,117 bytes
   7 Dir(s)  11,805,831,168 bytes free

C:\Downloads\Utils\fop

The quotes around %java_home% are necessary because of the spaces
in the path, but as you can see, it is pointing to the right place.

I will probably ask the Ant people about it.
_
Helping your favorite cause is as easy as instant messaging. You IM, we give.
http://im.live.com/Messenger/IM/Home/?source=text_hotmail_join
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Cannot convert MS Word HTML to PDF with fop-0.94; fop-0.20.5 worked

2007-11-02 Thread John Brown

Hello All,

First of all, I know nothing about Xalan, FOP, etc.  I'm probably breaking
all your posting rules. Maybe the list server figured that out and that's why
it rejected my post via Gmane as spam.  Anyway, I'm just trying
to convert a Microsoft Word HTML file to PDF.

The following article in the JavaWorld Forums:

http://www.javaworld.com/javaworld/jw-04-2006/jw-0410-html.html

explains how to convert HTML to PDF by using JTidy, Xalan and Apache FOP.
The steps are as follows:

1) HTML - XHTML using jtidy-04aug2000r7-dev
2) XHTML - XML-FO using xalan-j 2.7.0 and xhtml2fo.xsl donwloaded from:
http://www.antennahouse.com/XSLsample/sample-xsl-xhtml2fo/xhtml2fo.xsl
3) XML-FO - PDF using Apache fop-0.20.5

I have JRE and JDK 1.6 installed in default locations on Windows XP.

The results are not quite satisfactory:

1) I had to change the left and right margins the stylesheet to 0.0in to
avoid truncation of certain paragraph headings.

2) Certain GIF images were not rendered correctly. These were very small
(1.4K - 3.19K, C++ class hierarchy diagrams, text in boxes), but in
terms of dimensions were similar in size to other images that were
rendered correctly.

3) Chapters don't start on a new page. I assume  that they do in the
original Word document, but I do not know that for a fact.

I wanted to try FOP-0.94, but I get these messages:

C:\progra~1\utils\fop-0.94\fop.bat temp.fo temp.pdf

Nov 2, 2007 9:22:58 AM org.apache.fop.cli.Main startFOP
SEVERE: Exception
javax.xml.transform.TransformerException: org.apache.fop.fo.Validation
Exception:
file:/C:/Documents%20and%20Settings/johnbrown105/MYDOCU~1/TICPP_vol2/
html/temp.fo:4:591:
Error(4/591): fo:block, Error processing foreign attribute:
http://www.w3.org/XML/1998/namespace/@xml:lang
at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:168)
at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:115)
at org.apache.fop.cli.Main.startFOP(Main.java:166)
at org.apache.fop.cli.Main.main(Main.java:197)

-

javax.xml.transform.TransformerException: org.apache.fop.fo.ValidationException:
file:/C:/Documents%20and%20Settings/johnbrown105/MYDOCU~1/TICPP_vol2/
html/temp.fo:4:591:
Error(4/591): fo:block, Error processing foreign attribute:
http://www.w3.org/XML/1998/namespace/@xml:lang
at
org.apache.xalan.transformer.TransformerIdentityImpl.transform
(TransformerIdentityImpl.java:501)
at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:165)
at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:115)
at org.apache.fop.cli.Main.startFOP(Main.java:166)
at org.apache.fop.cli.Main.main(Main.java:197)
Caused by: org.apache.fop.fo.ValidationException:
file:/C:/Documents%20and%20Settings/johnbrown105/MYDOCU~1/TICPP_vol2/
html/temp.fo:4:591:
Error(4/591): fo:block, Error processing foreign attribute:
http://www.w3.org/XML/1998/namespace/@xml:lang
at org.apache.fop.fo.FONode.attributeError(FONode.java:330)
at 
org.apache.fop.fo.PropertyList.handleInvalidProperty(PropertyList.java:469)
at 
org.apache.fop.fo.PropertyList.addAttributesToList(PropertyList.java:328)
at org.apache.fop.fo.FObj.processNode(FObj.java:121)
at
org.apache.fop.fo.FOTreeBuilder$MainFOHandler.startElement(FOTreeBuilder.
java:320)
at org.apache.fop.fo.FOTreeBuilder.startElement(FOTreeBuilder.java:185)
at
org.apache.xalan.transformer.TransformerIdentityImpl.startElement
(TransformerIdentityImpl.java:1072)
at org.apache.xerces.parsers.AbstractSAXParser.startElement
(Unknown Source)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement
(Unknown Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContent
Dispatcher.dispatch(UnknownSource)
at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown
Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at
org.apache.xalan.transformer.TransformerIdentityImpl.transform
(TransformerIdentityImpl.java:484)
... 4 more
-
org.apache.fop.fo.ValidationException:
file:/C:/Documents%20and%20Settings/johnbrown105/MYDOCU~1/TICPP_vol2/
html/temp.fo:4:591:
Error(4/591): fo:block, Error processing foreign attribute:
http://www.w3.org/XML/1998/namespace/@xml:lang
at org.apache.fop.fo.FONode.attributeError(FONode.java:330)
at 
org.apache.fop.fo.PropertyList.handleInvalidProperty(PropertyList.java:469)
at 
org.apache.fop.fo.PropertyList.addAttributesToList(PropertyList.java:328)
at org.apache.fop.fo.FObj.processNode(FObj.java:121)
at
org.apache.fop.fo.FOTreeBuilder$MainFOHandler.startElement(FOTreeBuilder.