RE: Null Pointer Exception with Footnotes

2007-10-03 Thread Pascal Sancho
Hi,

After some further tests, this NPE is caused by a fo:footnote within a 
fo:block-container in absolute position and/or with a specified height.

1/ You should fill in a bug for that.

2/ why do you need a footnote in a fo:block-container in absolute position?
Since you control the posistion of its content, I think you shoud use the same 
thing for the note, and put it in a fo:block-container in absolute position...
WDYT?

Pascal


 -Message d'origine-
 De : Mark Zuneska [mailto:[EMAIL PROTECTED] 
 Envoyé : 2007-09-28 19:13
 À : fop-users@xmlgraphics.apache.org
 Objet : Re: Null Pointer Exception with Footnotes
 
 Actually the table is absolutly positioned near the top of 
 the page and there are several other absolutly positioned 
 block-container elements (with empty blocks currently) on the 
 page as well. This is also the only footnote on the page. I 
 tried adding the space-after attribute to several different 
 elements around the table and that didn't seem to make a difference. 
 
 On 9/28/07, Iskren Pushkarov [EMAIL PROTECTED] wrote: 
 
   Hi Mark,
   
   I've had similar exceptions regarding 
 PageBreakingAlgorithm.java in specific
   layout situation, not only in 0.94 but also in 0.93.
   
   I can guess your table (the code above footnote) 
 appears near the bottom of
   the page. Is it right?
   Do you have some footnotes one after another?
   When I had 4, 5, 6 footnotes in a group, this always results in 
   PageBreakingAlgorithm exception.
   
   As some kind of workaround I suggest you to add some 
 space-after (or
   space-before) attributes to one or more elements that 
 precede the trouble
   footnote.
   Try with different values (10, 20, 40, 50pt..), the 
 idea is to move the 
   footnote(s) to the next page.
   
   Regards,
   Iskren
   
   -Original Message-
   From: news [mailto:[EMAIL PROTECTED] On Behalf Of Mark
   Sent: Thursday, September 27, 2007 9:28 PM 
   
   I'm getting a null pointer exception when trying to add 
 a footnote to a 
   specific aspect of my page. I'm using version 0.94 of 
 FOP. I am including
   the
   stack trace I receive for the exception. I'm also 
 including a skimmed down
   version of my fo file. If this does not provide enough 
 context, I can paste 
   in
   the whole thing. Thanks for any help.
   
   Sep 27, 2007 1:59:37 PM org.apache.fop.cli.Main startFOP
   SEVERE: Exception
   java.lang.NullPointerException
  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)
   
   -
   
   java.lang.NullPointerException at
   org.apache.fop.layoutmgr.PageBreakingAlgorithm.handleFootnotes
   (PageBreakingAlgorithm.java:248)
   at org.apache.fop.layoutmgr.PageBreakingAlgorithm.handleBox
   (PageBreakingAlgorithm.java:220)
   at org.apache.fop.layoutmgr.BreakingAlgorithm.findBreakingPoints
   (BreakingAlgorithm.java:462)
   at org.apache.fop.layoutmgr.BreakingAlgorithm.findBreakingPoints
   (BreakingAlgorithm.java :403)
   at
   
 org.apache.fop.layoutmgr.AbstractBreaker.doLayout(AbstractBrea
 ker.java:338)
   at
   
 org.apache.fop.layoutmgr.BlockContainerLayoutManager.getNextKn
 uthElementsAbs
   olu
   te(BlockContainerLayoutManager.java :509)
   at 
 org.apache.fop.layoutmgr.BlockContainerLayoutManager.getNextKn
 uthElements
   (BlockContainerLayoutManager.java:195)
   at 
 org.apache.fop.layoutmgr.BlockStackingLayoutManager.getNextKnu
 thElements
   (BlockStackingLayoutManager.java :284)
   at 
 org.apache.fop.layoutmgr.BlockLayoutManager.getNextKnuthElements
   (BlockLayoutManager.java:113)
   at 
 org.apache.fop.layoutmgr.FlowLayoutManager.getNextKnuthElements
   (FlowLayoutManager.java:106)
   at org.apache.fop.layoutmgr.PageBreaker.getNextKnuthElements 
   (PageBreaker.java:145)
   at org.apache.fop.layoutmgr.AbstractBreaker.getNextBlockList
   (AbstractBreaker.java:551)
   at
   
 org.apache.fop.layoutmgr.PageBreaker.getNextBlockList(PageBrea
 ker.java:137)
   at
   org.apache.fop.layoutmgr.AbstractBreaker.doLayout 
 (AbstractBreaker.java:301)
   at
   
 org.apache.fop.layoutmgr.AbstractBreaker.doLayout(AbstractBrea
 ker.java:263)
   at 
 org.apache.fop.layoutmgr.PageSequenceLayoutManager.activateLayout
   (PageSequenceLayoutManager.java:144) 
   at org.apache.fop.area.AreaTreeHandler.endPageSequence
   (AreaTreeHandler.java:233)
   at
   
 org.apache.fop.fo.pagination.PageSequence.endOfNode(PageSequen
 ce.java:145)
   at 

RE: Wrong font for bold

2007-10-03 Thread Pascal Sancho
Hi,

You can give the same name for all font-triplet.

If not, you have to exlpicitely give the font-name of the relevant triplet 
(using the font-family property), depending if you are using a bold or regular 
font.

In addition, you should specify 2 other triplets if you want to use italic 
fonts:
normal+italic and bold+italic

Pascal

 -Message d'origine-
 De : Daniel Baptista [mailto:[EMAIL PROTECTED] 
 Envoyé : 2007-10-02 18:29
 À : fop-users@xmlgraphics.apache.org
 Objet : Re: Wrong font for bold
 
 Thanks for the response Adrian, I've set the fontBaseDir 
 property (where it wasn't set before) and the result is the 
 same, there are no complaints from FOP regarding missing 
 fonts in either case. I'll upgrade to 0.94 and see if that 
 yields any better results.
 
 Thanks again,
 Dan.
 
 Adrian Cumiskey wrote:
  Hi Dan,
 
  Firstly, you may want to check your font-base/ and/or base/ 
  settings to make sure they refer to an absolute path.
 
  I'm trying to go easy here, but if possible I'd strongly recommend 
  that you try and upgrade to using 0.94.  0.20.5 is getting 
 pretty old 
  now and isn't really supported.  FOP configuration checks are much 
  stricter and tighter in 0.94 and you should be able to 
 immediately see 
  any problems found with your configuration.
 
  Adrian.
 
  Daniel Baptista wrote:
  Hi all,
 
  I'm sorry if this question has been asked before but I 
 cant seem to 
  find an answer for it so I thought I'd mail the list.
 
  I'm trying to generate a PDF from a DocBook using FOP 
 0.20.5 however 
  I can't seem to get the any bold text to appear in the 
 correct font.
  I think I have correctly registered the font with FOP via the 
  userconfig.xml because the non-bold text is in the correct font, I 
  have included the relevant section from the userconfig.xml below.
 
  fonts
  font metrics-file=FrutigerLTStd-Bold.ttf.xml kerning=yes 
  embed-file=FrutigerLTStd-Bold.ttf
  font-triplet name=FrutigerLTStd-Light_Norm_Bold 
  style=normal weight=bold/
  /font
 
  font metrics-file=FrutigerLTStd-Light-vox.ttf.xml 
  kerning=yes embed-file=FrutigerLTStd-Light-vox.ttf
  font-triplet name=FrutigerLTStd-Light-vox_Norm_Norm 
  style=normal weight=normal/
  /font
  /fonts
 
  Can anyone see what I've done incorrectly?  (Go easy on me 
 I'm new to 
  this :) )
 
  Thanks in advance,
  Dan.
 


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



Re: Null Pointer Exception with Footnotes

2007-10-03 Thread Vincent Hennebert
Hi,

Pascal Sancho a écrit :
 Hi,
 
 After some further tests, this NPE is caused by a fo:footnote within a 
 fo:block-container in absolute position and/or with a specified height.
 
 1/ You should fill in a bug for that.
 
 2/ why do you need a footnote in a fo:block-container in absolute position?
 Since you control the posistion of its content, I think you shoud use the 
 same thing for the note, and put it in a fo:block-container in absolute 
 position...

Moreover, a footnote is not allowed to appear in an 
absolutely-positioned block-container. See XSL-FO 1.1, section 6.12.3.

That said, that’s not a reason why FOP should throw a NPE, so please 
still file a bug report.

Thanks,
Vincent

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



Re: Wrong font for bold

2007-10-03 Thread Daniel Baptista

Thanks Pascal, this solves my problem.
Dan.

Pascal Sancho wrote:

Hi,

You can give the same name for all font-triplet.

If not, you have to exlpicitely give the font-name of the relevant triplet 
(using the font-family property), depending if you are using a bold or regular 
font.

In addition, you should specify 2 other triplets if you want to use italic 
fonts:
normal+italic and bold+italic

Pascal

  

-Message d'origine-
De : Daniel Baptista [mailto:[EMAIL PROTECTED] 
Envoyé : 2007-10-02 18:29

À : fop-users@xmlgraphics.apache.org
Objet : Re: Wrong font for bold

Thanks for the response Adrian, I've set the fontBaseDir 
property (where it wasn't set before) and the result is the 
same, there are no complaints from FOP regarding missing 
fonts in either case. I'll upgrade to 0.94 and see if that 
yields any better results.


Thanks again,
Dan.

Adrian Cumiskey wrote:


Hi Dan,

Firstly, you may want to check your font-base/ and/or base/ 
settings to make sure they refer to an absolute path.


I'm trying to go easy here, but if possible I'd strongly recommend 
that you try and upgrade to using 0.94.  0.20.5 is getting 
  
pretty old 

now and isn't really supported.  FOP configuration checks are much 
stricter and tighter in 0.94 and you should be able to 
  
immediately see 


any problems found with your configuration.

Adrian.

Daniel Baptista wrote:
  

Hi all,

I'm sorry if this question has been asked before but I 

cant seem to 


find an answer for it so I thought I'd mail the list.

I'm trying to generate a PDF from a DocBook using FOP 

0.20.5 however 

I can't seem to get the any bold text to appear in the 


correct font.

I think I have correctly registered the font with FOP via the 
userconfig.xml because the non-bold text is in the correct font, I 
have included the relevant section from the userconfig.xml below.


fonts
font metrics-file=FrutigerLTStd-Bold.ttf.xml kerning=yes 
embed-file=FrutigerLTStd-Bold.ttf
font-triplet name=FrutigerLTStd-Light_Norm_Bold 
style=normal weight=bold/

/font

font metrics-file=FrutigerLTStd-Light-vox.ttf.xml 
kerning=yes embed-file=FrutigerLTStd-Light-vox.ttf
font-triplet name=FrutigerLTStd-Light-vox_Norm_Norm 
style=normal weight=normal/

/font
/fonts

Can anyone see what I've done incorrectly?  (Go easy on me 

I'm new to 


this :) )

Thanks in advance,
Dan.





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

  


--
*VoxSurf Limited*
Registered  principal office:
2nd Floor
Elme House
133 Long Acre
London WC2E 9DT
United Kingdom
Company No (England):  4051448

http://www.voxsurf.com/

Email disclaimer: This can be viewed at http://www.voxsurf.com/disclaimer.html 



RE: Null Pointer Exception with Footnotes

2007-10-03 Thread Pascal Sancho
 -Message d'origine-
 De : Vincent Hennebert [mailto:[EMAIL PROTECTED] 
 Envoyé : 2007-10-03 10:08
 
 Moreover, a footnote is not allowed to appear in an 
 absolutely-positioned block-container. See XSL-FO 1.1, section 6.12.3.

I've looked for this small line, but not found it... Thx;)

Pascal


Re: 0.93/0.94 and tables

2007-10-03 Thread Andreas L Delmelle

On Oct 3, 2007, at 03:53, Steve Ebersole wrote:

  [Me:]

Well, in the meantime, I did end up copy/pasting the entire
configuration.xml into the location of the xi:include node, fiddled
some more, and I see the problem now. Starting from Table 1.3 onward,
correct?


Correct




OK, managed to trim it down. For the interested parties, the FO in  
attach reproduces the issue.


It's caused by the keep-together on the table's containing block.
Remove that property and the table gets rendered very nicely. Would  
look even slightly better with a keep-together on the rows, I think.





test.fo
Description: Binary data




Cheers

Andreas


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

Re: 0.93/0.94 and tables

2007-10-03 Thread Steve Ebersole
On Wednesday 03 October 2007 02:47:04 pm Andreas L Delmelle wrote:
 On Oct 3, 2007, at 03:53, Steve Ebersole wrote:

[Me:]

  Well, in the meantime, I did end up copy/pasting the entire
  configuration.xml into the location of the xi:include node, fiddled
  some more, and I see the problem now. Starting from Table 1.3 onward,
  correct?
 
  Correct

 OK, managed to trim it down. For the interested parties, the FO in
 attach reproduces the issue.

 It's caused by the keep-together on the table's containing block.
 Remove that property and the table gets rendered very nicely. Would
 look even slightly better with a keep-together on the rows, I think.

Awesome!  Thank you so much.

I know you are not trying to, but at some point you switched to speaking a 
language I do not understand ;)

But I did a search.  Is something this what you mean? 
http://sourceware.org/ml/docbook-apps/2004-q1/msg00232.html

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



Re: 0.93/0.94 and tables

2007-10-03 Thread Steve Ebersole
On Wednesday 03 October 2007 02:47:04 pm Andreas L Delmelle wrote:
 On Oct 3, 2007, at 03:53, Steve Ebersole wrote:

[Me:]

  Well, in the meantime, I did end up copy/pasting the entire
  configuration.xml into the location of the xi:include node, fiddled
  some more, and I see the problem now. Starting from Table 1.3 onward,
  correct?
 
  Correct

 OK, managed to trim it down. For the interested parties, the FO in
 attach reproduces the issue.

 It's caused by the keep-together on the table's containing block.
 Remove that property and the table gets rendered very nicely. Would
 look even slightly better with a keep-together on the rows, I think.

Also, I do not set the keep-together on the table's containing block (I don't 
think so anyway), so how would I remove it?

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



Re: 0.93/0.94 and tables

2007-10-03 Thread Andreas L Delmelle

On Oct 3, 2007, at 21:53, Steve Ebersole wrote:


snip /
I know you are not trying to, but at some point you switched to  
speaking a

language I do not understand ;)

But I did a search.


Good thinking. :-)


  Is something this what you mean?
http://sourceware.org/ml/docbook-apps/2004-q1/msg00232.html


Indeed. That should work fine here.


Cheers

Andreas


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