You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Warren Young <wa...@etr-usa.com> on 2008/01/03 14:51:00 UTC

Noisy output when formatting DocBook despite -q

I'm trying to fix or suppress the warnings I'm getting from FOP 0.94 in 
formatting MySQL++'s (http://tangentsoft.net/mysql++/) user manual.  (To 
try it yourself, download MySQL++, then go in to doc/userman and say 
"make pdf".)

I get 1800+ lines of errors, but there are just a few types:

- fo:table, table-layout="auto" is currently not supported by FOP

I've tried disabling this one by trying to set the default table width 
to 100% in my fo.xsl customization layer, but it doesn't help.  I'm 
aware that I could probably turn on FOP extensions to suppress it, but 
I'd rather use a standard method.

- Line 1 of a paragraph overflows the available area. (fo:block, 
location: 2/33495)

- The contents of row 1 are taller than they should be

Are these problems due to the DocBook stylesheets (using 1.69.1 here) or 
are they problems in FOP?  Can I suppress these without just redirecting 
stderr to /dev/null?  I actually used to do that, but it also suppresses 
true errors like Java stack traces when I crash FOP.

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


Re: Noisy output when formatting DocBook despite -q

Posted by Warren Young <wa...@etr-usa.com>.
J.Pietschmann wrote:
> 
>> Are these problems due to the DocBook stylesheets (using 1.69.1 here) 
>> or are they problems in FOP?
> 
> I don't know. I'd have to take a look at the generated FO files.

For what it's worth, most of the errors were due to DocBook stylesheets 
that were...shall we say, "heavily customized" by Red Hat.  They caused 
the FO output to default to table column widths of 1%, which may work 
fine with a FO processor that can do automatic table layout, but which 
really annoys FOP.

More details in a related thread on the DocBook users' mailing list.

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


Re: Noisy output when formatting DocBook despite -q

Posted by "J.Pietschmann" <j3...@yahoo.de>.
Warren Young wrote:
> I'm trying to fix or suppress the warnings I'm getting from FOP 0.94 in 
> formatting MySQL++'s (http://tangentsoft.net/mysql++/) user manual.

I'm afraid you wont have much luck...

...
> - fo:table, table-layout="auto" is currently not supported by FOP
> 
> I've tried disabling this one by trying to set the default table width 
> to 100% in my fo.xsl customization layer, but it doesn't help.

You can fix this by adding an attribute table-layout="fixed" to every
table in your customization layer. If there is no such attribute, FOP
uses the default table-layout="auto", but automatic table layout isn't
supported yet, alas. The error message doesn't have anything to do with
the table width.


> - Line 1 of a paragraph overflows the available area. (fo:block, 
> location: 2/33495)
> 
> - The contents of row 1 are taller than they should be

I don't think you can easily silence these messages without overriding
the FOP logger.

> Are these problems due to the DocBook stylesheets (using 1.69.1 here) or 
> are they problems in FOP?

I don't know. I'd have to take a look at the generated FO files.

> Can I suppress these without just redirecting 
> stderr to /dev/null? I actually used to do that, but it also suppresses 
> true errors like Java stack traces when I crash FOP.

Indeed.

J.Pietschmann

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


Re: Noisy output when formatting DocBook despite -q

Posted by Warren Young <wa...@etr-usa.com>.
Vincent Hennebert wrote:
>>
>> It seems to have no effect.  I've tried setting it two ways.  First, in
>> the command that does .dbx to .fo processing:
>>
>>     xsltproc --stringparam fop1.extensions 1 ....
> 
> Well it does have an effect if I add it to the fo.xsl customization 
> file, and by using at least the 1.72.0 stylesheets. It might well be 
> that this will work only with recent releases of the stylesheets.

Okay.  I'm trying to avoid upgrading the stylesheets for testing 
reasons, because other things on this system generate DocBook, so if 
we're not using what we ship to customers...  It's the old dogfood problem.

> To avoid the other warning (‘... falling back to proportional- 
> column-width(1)’), I had to modify the DocBook source and put two 
> colspec with a colwidth attribute, instead of only one colspec:
>     <colspec colsep="1" rowsep="1" colwidth="*"/>
>     <colspec colsep="1" rowsep="1" colwidth="*"/>

This one I don't see, but it's probably a 1.72 thing.  I'll keep this in 
mind for when I do decide to upgrade.

> In your particular case this is caused by the program 
> listings, which have too long lines. I managed to reduce the number of 
> warnings to only 3 by adding font-size="80%" to the 
> ‘monospace.verbatim.properties’ attribute set, but this is perhaps not 
> what you want. 

No, in fact, that's perfect.  I've actually removed all of these 
warnings with font-size=85% here.

> Or you may implement the line-wrapping in 
> your source code extraction tool.

Our coding style has a line length limit, so if this warning crops back 
up again, it's a good thing, because it means someone's not following 
the rules.

Thanks for the help!

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


Re: Noisy output when formatting DocBook despite -q

Posted by Vincent Hennebert <vi...@anyware-tech.com>.
Hi Warren,

Warren Young wrote:
> Vincent Hennebert wrote:
>>> - fo:table, table-layout="auto" is currently not supported by FOP
>>>
>>> I've tried disabling this one by trying to set the default table width
>>> to 100% in my fo.xsl customization layer, but it doesn't help.  I'm
>>> aware that I could probably turn on FOP extensions to suppress it, but
>>> I'd rather use a standard method.
>>
>> You mean the ‘fop1.extensions’ stylesheet parameter? 
> 
> Yes.
> 
> It seems to have no effect.  I've tried setting it two ways.  First, in
> the command that does .dbx to .fo processing:
> 
>     xsltproc --stringparam fop1.extensions 1 ....
> 
> and in my fo.xsl file, which is a customization layer for the above
> process, so this should be equivalent:
> 
>     <xsl:param name="fop1.extensions" select="1"/>

Well it does have an effect if I add it to the fo.xsl customization 
file, and by using at least the 1.72.0 stylesheets. It might well be 
that this will work only with recent releases of the stylesheets.

To avoid the other warning (‘... falling back to proportional- 
column-width(1)’), I had to modify the DocBook source and put two 
colspec with a colwidth attribute, instead of only one colspec:
    <colspec colsep="1" rowsep="1" colwidth="*"/>
    <colspec colsep="1" rowsep="1" colwidth="*"/>


>>> - Line 1 of a paragraph overflows the available area. (fo:block,
>>> location: 2/33495)
>>
>> Not sure you want to ignore this one. This usually means that some
>> content goes in the margin, possibly resulting in text being clipped.
> 
> Given that I'm using DocBook and not generating FO myself, why would
> this happen?

Simply because there is no possibility to break the text over several 
lines/pages. This is not dependent on the toolchain but rather on the 
input document. In your particular case this is caused by the program 
listings, which have too long lines. I managed to reduce the number of 
warnings to only 3 by adding font-size="80%" to the 
‘monospace.verbatim.properties’ attribute set, but this is perhaps not 
what you want. You may let FOP automatically wrap the text, by removing 
the wrap-option="no-wrap" from the same attribute set —but honestly the 
result won’t look very good. Or you may implement the line-wrapping in 
your source code extraction tool.

HTH,
Vincent


-- 
Vincent Hennebert                            Anyware Technologies
http://people.apache.org/~vhennebert         http://www.anyware-tech.com
Apache FOP Committer                         FOP Development/Consulting

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


Re: Noisy output when formatting DocBook despite -q

Posted by Warren Young <wa...@etr-usa.com>.
Vincent Hennebert wrote:
>> - fo:table, table-layout="auto" is currently not supported by FOP
>>
>> I've tried disabling this one by trying to set the default table width
>> to 100% in my fo.xsl customization layer, but it doesn't help.  I'm
>> aware that I could probably turn on FOP extensions to suppress it, but
>> I'd rather use a standard method.
> 
> You mean the ‘fop1.extensions’ stylesheet parameter? 

Yes.

It seems to have no effect.  I've tried setting it two ways.  First, in 
the command that does .dbx to .fo processing:

	xsltproc --stringparam fop1.extensions 1 ....

and in my fo.xsl file, which is a customization layer for the above 
process, so this should be equivalent:

	<xsl:param name="fop1.extensions" select="1"/>

The complaint about table-layout="auto" appears regardless.

>> - Line 1 of a paragraph overflows the available area. (fo:block,
>> location: 2/33495)
> 
> Not sure you want to ignore this one. This usually means that some 
> content goes in the margin, possibly resulting in text being clipped.

Given that I'm using DocBook and not generating FO myself, why would 
this happen?

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


Re: Noisy output when formatting DocBook despite -q

Posted by Vincent Hennebert <vi...@anyware-tech.com>.
Hi Warren,


Warren Young wrote:
> I'm trying to fix or suppress the warnings I'm getting from FOP 0.94 in
> formatting MySQL++'s (http://tangentsoft.net/mysql++/) user manual.  (To
> try it yourself, download MySQL++, then go in to doc/userman and say
> "make pdf".)
> 
> I get 1800+ lines of errors, but there are just a few types:
> 
> - fo:table, table-layout="auto" is currently not supported by FOP
> 
> I've tried disabling this one by trying to set the default table width
> to 100% in my fo.xsl customization layer, but it doesn't help.  I'm
> aware that I could probably turn on FOP extensions to suppress it, but
> I'd rather use a standard method.

You mean the ‘fop1.extensions’ stylesheet parameter? Well, that’s 
already what this parameter is doing actually. Anyway, AFAIK this 
parameter doesn’t really introduce FOP extensions, but rather tweaks the 
output to make FOP handle it more nicely, by using plain XSL-FO tricks. 
So I think it’s safe enabling it.

As to this particular problem:
- you should first upgrade to the newest 1.73.2 stylesheets, the 1.69.1 
  are really old now.
- I’ve experienced that enabling the ‘fop1.extensions’ parameter is not 
  sufficient if you don’t specify column widths in the DocBook source. 
  Well the warning will be different: “table-layout="fixed" and 
  column-width unspecified => falling back to 
  proportional-column-width(1)”
  If you add colspec elements in the source you should be ok.

> - Line 1 of a paragraph overflows the available area. (fo:block,
> location: 2/33495)

Not sure you want to ignore this one. This usually means that some 
content goes in the margin, possibly resulting in text being clipped.


> - The contents of row 1 are taller than they should be

This is because a table row has a specified height but its content 
overflows it. You may want to determine how those heights are introduced 
(probably the default stylesheets, but it’s a bit surprising), and 
remove them. That said, appart from the annoying warning, the output 
will be fine.


HTH,
Vincent


-- 
Vincent Hennebert                            Anyware Technologies
http://people.apache.org/~vhennebert         http://www.anyware-tech.com
Apache FOP Committer                         FOP Development/Consulting

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


Re: How to put batch process into background on Mac OS

Posted by Terry Ofner <to...@comcast.net>.
James,

Your suggestion works. I have no idea where the vm arguments are in  
the fop script. So I changed my script to invoke the jar directly,  
adding the headless argument. I had to move all the jar files in fop/ 
lib to the build directory to get this to work:

java -Djava.awt.headless=true -jar /Applications/fop-0.94/build/ 
fop.jar -fo $foo -pdf ../pdf_files/$state.pdf

Thanks for the tip.

Terry

On Jan 3, 2008, at 12:35 PM, James Howard wrote:

> Actually that probably won't do what you want.  Adding - 
> Djava.awt.headless=true to the vm arguments in the fop script  
> probably will work.
>
> On Jan 3, 2008, at 8:36 AM, Steve Quirk <sq...@ieee.org> wrote:
>
>>
>> Use 'nice' to run it.  Alter the script so that the fop execution  
>> looks like:
>>
>> nice /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
>>
>> You can check the man page for nice for more info.
>>
>> Steve
>>
>> On Thu, 3 Jan 2008, Terry Ofner wrote:
>>
>>> This is not a huge matter. More on the line of an annoyance. And  
>>> I may need to take this question to a java list rather than this  
>>> list. If so, just point me in the right direction.
>>>
>>> At any rate, I have an XSLT stylesheet that produces 50+ separate  
>>> fo documents. I then run the shell script below to batch produce  
>>> the pdf documents:
>>>
>>> #!/bin/sh
>>> for foo in *.fo
>>> do
>>> state=`basename $foo .fo`
>>> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
>>> done
>>>
>>> When I run this script on my Mac (OS X 10.4.11, java version  
>>> "1.5.0_13" fop-0.94), org.apache.fop.cli.main takes control of  
>>> the desktop, stopping whatever it is I am doing for about 5  
>>> seconds. I gain control again for about 5 seconds until fop pumps  
>>> out another pdf document. I basically have to step away from the  
>>> computer for the 8 minutes that the batch process takes. Adding &  
>>> and wait to the main line of the script does not seem to work:
>>>
>>> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf &
>>> wait
>>> done
>>>
>>> The first script above on Ubuntu linux runs in the background  
>>> without interrupting other running process.
>>>
>>> Any simple solutions?
>>>
>>> Terry Ofner
>>>
>>> -------------------------------------------------------------------- 
>>> -
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users- 
>>> help@xmlgraphics.apache.org
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users- 
>> help@xmlgraphics.apache.org
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>


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


Re: How to put batch process into background on Mac OS

Posted by Terry Ofner <to...@comcast.net>.
Steve,

Yep. That works too. On 0.94 the fop_exec_command is near the bottom  
of the fop script and looks like this:

fop_exec_command="exec \"$JAVACMD\" -Djava.awt.headless=true  
$LOGCHOICE $LOGLEVEL -classpath \"$LOCALCLASSPATH\" $FOP_OPTS  
org.apache.fop.cli.Main $fop_exec_args"

Note: The -Djava.awt.headless=true was originally missing.

The only problem with changing the fop script is that it will only  
impact my installation. If I ever pass this process off to someone  
else (or update my version of fop), I will have to remember to change  
the exec command. I suppose that I would have to mess with something  
either way. (I would have to move all the jar files to the build  
directory.)

Either way, all is well now.

Thanks.

Terry




On Jan 3, 2008, at 1:14 PM, Steve Quirk wrote:

>
> I had looked at the fop script I had and saw it there.  I wasn't  
> sure that I had made the change or not.  In any case, if it's  
> helpful, it should look like:
>
> fop_exec_command="exec \"$JAVACMD\" ${ENDORSED} - 
> Djava.awt.headless=true $LOGCHOICE $LOGLEVEL -classpath  
> \"$LOCALCLASSPATH\" $FOP_OPTS org.apache.fop.cli.Main $fop_exec_args"
>
> (I'm using 0.93, so it might be slightly different).
>
> That should avoid any icons or desktop interaction.
>
> steve
>
> On Thu, 3 Jan 2008, James Howard wrote:
>
>> Actually that probably won't do what you want.  Adding - 
>> Djava.awt.headless=true to the vm arguments in the fop script  
>> probably will work.
>>
>> On Jan 3, 2008, at 8:36 AM, Steve Quirk <sq...@ieee.org> wrote:
>>
>>> Use 'nice' to run it.  Alter the script so that the fop execution  
>>> looks like:
>>> nice /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/ 
>>> $state.pdf
>>> You can check the man page for nice for more info.
>>> Steve
>>> On Thu, 3 Jan 2008, Terry Ofner wrote:
>>>> This is not a huge matter. More on the line of an annoyance. And  
>>>> I may need to take this question to a java list rather than this  
>>>> list. If so, just point me in the right direction.
>>>> At any rate, I have an XSLT stylesheet that produces 50+  
>>>> separate fo documents. I then run the shell script below to  
>>>> batch produce the pdf documents:
>>>> #!/bin/sh
>>>> for foo in *.fo
>>>> do
>>>> state=`basename $foo .fo`
>>>> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
>>>> done
>>>> When I run this script on my Mac (OS X 10.4.11, java version  
>>>> "1.5.0_13" fop-0.94), org.apache.fop.cli.main takes control of  
>>>> the desktop, stopping whatever it is I am doing for about 5  
>>>> seconds. I gain control again for about 5 seconds until fop  
>>>> pumps out another pdf document. I basically have to step away  
>>>> from the computer for the 8 minutes that the batch process  
>>>> takes. Adding & and wait to the main line of the script does not  
>>>> seem to work:
>>>> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf &
>>>> wait
>>>> done
>>>> The first script above on Ubuntu linux runs in the background  
>>>> without interrupting other running process.
>>>> Any simple solutions?
>>>> Terry Ofner
>>>> ------------------------------------------------------------------- 
>>>> --
>>>> To unsubscribe, e-mail: fop-users- 
>>>> unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users- 
>>>> help@xmlgraphics.apache.org
>>> -------------------------------------------------------------------- 
>>> -
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users- 
>>> help@xmlgraphics.apache.org
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users- 
>> help@xmlgraphics.apache.org
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>


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


Re: How to put batch process into background on Mac OS

Posted by Steve Quirk <sq...@ieee.org>.
I had looked at the fop script I had and saw it there.  I wasn't sure that 
I had made the change or not.  In any case, if it's helpful, it should 
look like:

fop_exec_command="exec \"$JAVACMD\" ${ENDORSED} -Djava.awt.headless=true 
$LOGCHOICE $LOGLEVEL -classpath \"$LOCALCLASSPATH\" $FOP_OPTS 
org.apache.fop.cli.Main $fop_exec_args"

(I'm using 0.93, so it might be slightly different).

That should avoid any icons or desktop interaction.

steve

On Thu, 3 Jan 2008, James Howard wrote:

> Actually that probably won't do what you want.  Adding 
> -Djava.awt.headless=true to the vm arguments in the fop script probably will 
> work.
>
> On Jan 3, 2008, at 8:36 AM, Steve Quirk <sq...@ieee.org> wrote:
>
>> 
>> Use 'nice' to run it.  Alter the script so that the fop execution looks 
>> like:
>> 
>> nice /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
>> 
>> You can check the man page for nice for more info.
>> 
>> Steve
>> 
>> On Thu, 3 Jan 2008, Terry Ofner wrote:
>> 
>>> This is not a huge matter. More on the line of an annoyance. And I may 
>>> need to take this question to a java list rather than this list. If so, 
>>> just point me in the right direction.
>>> 
>>> At any rate, I have an XSLT stylesheet that produces 50+ separate fo 
>>> documents. I then run the shell script below to batch produce the pdf 
>>> documents:
>>> 
>>> #!/bin/sh
>>> for foo in *.fo
>>> do
>>> state=`basename $foo .fo`
>>> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
>>> done
>>> 
>>> When I run this script on my Mac (OS X 10.4.11, java version "1.5.0_13" 
>>> fop-0.94), org.apache.fop.cli.main takes control of the desktop, stopping 
>>> whatever it is I am doing for about 5 seconds. I gain control again for 
>>> about 5 seconds until fop pumps out another pdf document. I basically have 
>>> to step away from the computer for the 8 minutes that the batch process 
>>> takes. Adding & and wait to the main line of the script does not seem to 
>>> work:
>>> 
>>> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf &
>>> wait
>>> done
>>> 
>>> The first script above on Ubuntu linux runs in the background without 
>>> interrupting other running process.
>>> 
>>> Any simple solutions?
>>> 
>>> Terry Ofner
>>> 
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>> 
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>

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


Re: How to put batch process into background on Mac OS

Posted by James Howard <ja...@mac.com>.
Actually that probably won't do what you want.  Adding - 
Djava.awt.headless=true to the vm arguments in the fop script probably  
will work.

On Jan 3, 2008, at 8:36 AM, Steve Quirk <sq...@ieee.org> wrote:

>
> Use 'nice' to run it.  Alter the script so that the fop execution  
> looks like:
>
> nice /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
>
> You can check the man page for nice for more info.
>
> Steve
>
> On Thu, 3 Jan 2008, Terry Ofner wrote:
>
>> This is not a huge matter. More on the line of an annoyance. And I  
>> may need to take this question to a java list rather than this  
>> list. If so, just point me in the right direction.
>>
>> At any rate, I have an XSLT stylesheet that produces 50+ separate  
>> fo documents. I then run the shell script below to batch produce  
>> the pdf documents:
>>
>> #!/bin/sh
>> for foo in *.fo
>> do
>> state=`basename $foo .fo`
>> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
>> done
>>
>> When I run this script on my Mac (OS X 10.4.11, java version  
>> "1.5.0_13" fop-0.94), org.apache.fop.cli.main takes control of the  
>> desktop, stopping whatever it is I am doing for about 5 seconds. I  
>> gain control again for about 5 seconds until fop pumps out another  
>> pdf document. I basically have to step away from the computer for  
>> the 8 minutes that the batch process takes. Adding & and wait to  
>> the main line of the script does not seem to work:
>>
>> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf &
>> wait
>> done
>>
>> The first script above on Ubuntu linux runs in the background  
>> without interrupting other running process.
>>
>> Any simple solutions?
>>
>> Terry Ofner
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users- 
>> help@xmlgraphics.apache.org
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>

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


Re: How to put batch process into background on Mac OS

Posted by Terry Ofner <to...@comcast.net>.
nice does not seem to change the outcome. It only changes the  
priority of the process. When it runs, it still places fop in the  
foreground. Here is what I have tried:

nice /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf &
nice -n 20 /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/ 
$state.pdf &

I have also added & at the command line:

./createPDF.sh &

Any other options?




On Jan 3, 2008, at 11:36 AM, Steve Quirk wrote:

>
> Use 'nice' to run it.  Alter the script so that the fop execution  
> looks like:
>
> nice /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
>
> You can check the man page for nice for more info.
>
> Steve
>
> On Thu, 3 Jan 2008, Terry Ofner wrote:
>
>> This is not a huge matter. More on the line of an annoyance. And I  
>> may need to take this question to a java list rather than this  
>> list. If so, just point me in the right direction.
>>
>> At any rate, I have an XSLT stylesheet that produces 50+ separate  
>> fo documents. I then run the shell script below to batch produce  
>> the pdf documents:
>>
>> #!/bin/sh
>> for foo in *.fo
>> do
>> state=`basename $foo .fo`
>> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
>> done
>>
>> When I run this script on my Mac (OS X 10.4.11, java version  
>> "1.5.0_13" fop-0.94), org.apache.fop.cli.main takes control of the  
>> desktop, stopping whatever it is I am doing for about 5 seconds. I  
>> gain control again for about 5 seconds until fop pumps out another  
>> pdf document. I basically have to step away from the computer for  
>> the 8 minutes that the batch process takes. Adding & and wait to  
>> the main line of the script does not seem to work:
>>
>> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf &
>> wait
>> done
>>
>> The first script above on Ubuntu linux runs in the background  
>> without interrupting other running process.
>>
>> Any simple solutions?
>>
>> Terry Ofner
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users- 
>> help@xmlgraphics.apache.org
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>


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


Re: How to put batch process into background on Mac OS

Posted by Steve Quirk <sq...@ieee.org>.
Use 'nice' to run it.  Alter the script so that the fop execution looks 
like:

nice /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf

You can check the man page for nice for more info.

Steve

On Thu, 3 Jan 2008, Terry Ofner wrote:

> This is not a huge matter. More on the line of an annoyance. And I may need 
> to take this question to a java list rather than this list. If so, just point 
> me in the right direction.
>
> At any rate, I have an XSLT stylesheet that produces 50+ separate fo 
> documents. I then run the shell script below to batch produce the pdf 
> documents:
>
> #!/bin/sh
> for foo in *.fo
> do
> state=`basename $foo .fo`
> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
> done
>
> When I run this script on my Mac (OS X 10.4.11, java version "1.5.0_13" 
> fop-0.94), org.apache.fop.cli.main takes control of the desktop, stopping 
> whatever it is I am doing for about 5 seconds. I gain control again for about 
> 5 seconds until fop pumps out another pdf document. I basically have to step 
> away from the computer for the 8 minutes that the batch process takes. Adding 
> & and wait to the main line of the script does not seem to work:
>
> /Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf &
> wait
> done
>
> The first script above on Ubuntu linux runs in the background without 
> interrupting other running process.
>
> Any simple solutions?
>
> Terry Ofner
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>

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


How to put batch process into background on Mac OS

Posted by Terry Ofner <to...@comcast.net>.
This is not a huge matter. More on the line of an annoyance. And I  
may need to take this question to a java list rather than this list.  
If so, just point me in the right direction.

At any rate, I have an XSLT stylesheet that produces 50+ separate fo  
documents. I then run the shell script below to batch produce the pdf  
documents:

#!/bin/sh
for foo in *.fo
do
state=`basename $foo .fo`
/Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf
done

When I run this script on my Mac (OS X 10.4.11, java version  
"1.5.0_13" fop-0.94), org.apache.fop.cli.main takes control of the  
desktop, stopping whatever it is I am doing for about 5 seconds. I  
gain control again for about 5 seconds until fop pumps out another  
pdf document. I basically have to step away from the computer for the  
8 minutes that the batch process takes. Adding & and wait to the main  
line of the script does not seem to work:

/Applications/fop-0.94/fop -fo $foo -pdf ../pdf_files/$state.pdf &
wait
done

The first script above on Ubuntu linux runs in the background without  
interrupting other running process.

Any simple solutions?

Terry Ofner

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