Bug report for Fop [2007/05/27]

2007-05-28 Thread bugzilla
+---+
| Bugzilla Bug ID   |
| +-+
| | Status: UNC=Unconfirmed NEW=New ASS=Assigned|
| | OPN=ReopenedVER=Verified(Skipped Closed/Resolved)   |
| |   +-+
| |   | Severity: BLK=Blocker CRI=CriticalMAJ=Major |
| |   |   MIN=Minor   NOR=Normal  ENH=Enhancement   |
| |   |   +-+
| |   |   | Date Posted |
| |   |   |  +--+
| |   |   |  | Description  |
| |   |   |  |  |
| 1063|New|Nor|2001-03-21|fop does not handle large fo files|
| 2150|Ass|Maj|2001-06-13|New page with  a table-header but without any tabl|
| 2909|New|Maj|2001-07-30|Gradient render error |
| 2988|New|Maj|2001-08-03|0.19: list-item-label does not stick to list-item-|
| 3280|New|Nor|2001-08-27|PCL Renderer doesn't work |
| 3497|New|Cri|2001-09-07|id already exists error when using span=all attr|
| 3824|New|Blk|2001-09-25|MIF option with tables|
| 4030|New|Nor|2001-10-08|IOException creating Postscript with graphics on S|
| 4535|New|Maj|2001-10-31|PCL renderer 1.13 not rendering SVG   |
| 4767|New|Nor|2001-11-09|SVG text is distored in PDF output|
| 5010|New|Enh|2001-11-21|Better error reporting needed |
| 5124|New|Maj|2001-11-27|fo:block-container is not rendered properly using |
| 6094|Opn|Maj|2002-01-29|0.20.3rc hangs in endless loop|
| 6237|Opn|Nor|2002-02-05|#xFB01 (fi ligature) produces a sharp? |
| 6305|New|Nor|2002-02-07|Using fo:table-and-caption results in empty output|
| 6427|New|Enh|2002-02-13|Adding additional Type 1 fonts problem|
| 6437|New|Maj|2002-02-13|Tables without fo:table-column don't render   |
| 6483|New|Nor|2002-02-15|Table, Loop, footer could not fit on page, moving|
| 6997|New|Nor|2002-03-09|[PATCH] Row-spanned row data breaks over a page wi|
| 7241|New|Nor|2002-03-19|keep-with-previous, keep-with-next only working on|
| 7283|New|Nor|2002-03-20|Table border misaligned when using margin-left in |
| 7337|New|Nor|2002-03-21|border around external image leaves empty space   |
| 7487|New|Nor|2002-03-26|break-before=page for table inserts empty page  |
| 7496|New|Nor|2002-03-26|The table header borders are not adjusted to the b|
| 7525|New|Cri|2002-03-27|table with spans inside a list-block  |
| 7919|New|Cri|2002-04-10|problem to use attribute linefeed-treatment and li|
| 8003|Ass|Maj|2002-04-12|FopImageFactory never releases cached images  |
| 8463|New|Nor|2002-04-24|SVG clipping in external.fo example doc when rende|
| 8767|Ass|Min|2002-05-03|Image and solid colour background rectangle sizes |
| 8819|New|Nor|2002-05-06|Footnotes lost|
| 9054|Opn|Maj|2002-05-14|PDF Tc Text operator BUG  |
| 9379|New|Nor|2002-05-24|MIF Renderer generates incorrect MIF code |
| 9569|New|Maj|2002-06-03|break does not work on block-container|
| 9864|New|Nor|2002-06-14|fo:list-item-label at the end of line |
| 9885|New|Nor|2002-06-14|link in pdf to another pdf through url doesn't wor|
|10379|New|Enh|2002-07-01|Improvement to FOP Classloader|
|11032|New|Min|2002-07-22|Height of table-cell is calculated incorrect when |
|11783|New|Maj|2002-08-16|fo:block background-color=xtext/fo:block gen|
|12262|New|Min|2002-09-03|Lacking detection of endless loops|
|12300|New|Nor|2002-09-04|letter-spacing problem on sequencing pages|
|12448|New|Nor|2002-09-09|Height of lines set by line-height are too short. |
|12494|New|Nor|2002-09-10|fop produces pdf file which Acrobat Reader refuses|
|12610|New|Enh|2002-09-13|[PATCH] onLoad Action for PDF documents or how to |
|13450|New|Cri|2002-10-09|FOP0.20.4 embedded rendering throws exception |
|13464|Opn|Nor|2002-10-09|part of word missing when broken across pages |
|13586|New|Blk|2002-10-13|fop will not work on linux alpha because jre is br|
|13592|New|Nor|2002-10-14|Converting a FO document with PNG images into PS  |
|13734|New|Nor|2002-10-17|Hyphenation does not work correctly on long string|
|13807|New|Nor|2002-10-21|list-block in table-cell  |
|14248|New|Enh|2002-11-05|51-page FO example, could be added to the samples |
|14352|New|Enh|2002-11-07|It would be nice if FOP could be plugged into popu|

DO NOT REPLY [Bug 41831] - [PATCH] Refactored configuration, font detection and caching, url resolution

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

http://issues.apache.org/bugzilla/show_bug.cgi?id=41831





--- Additional Comments From [EMAIL PROTECTED]  2007-05-28 02:07 ---
Wow, it took me a lot longer to thoroughly review this patch than I anticipated.
I'm almost ready to commit. I only have to test the PDFTrancoder and
PDFDocumentGraphics2D. Here are the issues I found and what I did about them:

- Javadocs: Still some issues there. I fixed the most important locations.
- FopCache: I did a double-check on that to see if I've done anything wrong, but
after applying the patch the cache file was always empty. The writing methods
were simply not referenced anywhere in the code. Therefore the font lookup
performance wasn't improved. I also wondered why it has to be done in such a
complicated way (writing and parsing XML using custom code) just for a cache
file. So since the code didn't work as expected I simply tore it out (Sorry,
Adrian) and used Java's Serializable mechanism. That has the elegant side-effect
that there's a lot less code to maintain and it's probably faster. And I renamed
FopCache to FontCache and moved it into the fonts package. I didn't like all
this cache stuff cluttering the apps package. Now on my machine the speed-up is
from 1200ms for the first run, to 70ms with the cache despite over 150 fonts
being registered. Another issue in that area was the use of the singleton
pattern for the FontCache. I have now attached the FontCache to the FopFactory
like every other cache we have. Furthermore, the default location of the cache
file is changed to user-home/.fop/fop-fonts.cache. I did this because the font
auto-detection also checks user directories so this made sense to me. I have not
yet added a configuration item to define the cache location and I removed the
command-line argument for the cache location as it had no counterpart for
embedded use. We can add that later when we see a need for it.
- TrueType Collections (*.ttc)and OpenType fonts with an .otf extension are
currently not found. I'll add that after applying the patch.
- TrueType Collections are not properly supported with the auto-detection
mechanism. ATM, if someone wants to use a TTC, he has to configure it using a
XML font metric file as before. We can improve that later.
- The same applies to fonts that should only be referenced but not embedded. For
certain environments you have all the fonts already installed on the production
printers and you may want to reference those. But I guess that's becoming less
important nowadays.
- The whole font configuration stuff got lost for PDFDocumentGraphics2D. I've
addressed that and took the opportunity to remove some of the Avalon
dependencies, too. This as a preparation for the move to Commons/Batik.
- I addressed a small problem when the font base URL is no file URL. The font
auto-detection will then be skipped for the font base URL.
- The RendererContextInfo stuff was quite confusing to me (especially the
somewhat abstract naming). I eventually managed to simplify it which resulted in
removing RendererContextInfo* and everything that's necessary is now in
XMLHanderConfigurator because RendererContextInfoConfigurator really configured
the XMLHandler, not the RendererContext.
- Another case where I thought I was doing something wrong: Type 1 fonts simply
didn't work. All fonts failed because the auto-detection code was accessing the
PFB file instead of the PFM. I fixed that.
- I made the font code a little less verbose on the log as with auto-detection
I'm not really interested in all the details. That's another case where dividing
developer feedback from user feedback will be helpful.

While working on this patch, I kept thinking that there's still some room (and
necessity) for improvement with the whole font handling (not directly related to
this patch). The big issue: The whole font configuration is currently triggered
during the renderer setup. That means it is done each time a new renderer is
created. Plus we still have a font config per renderer which is not beautiful. I
keep ending up with my font source idea I had back when I discussed the whole
font thing with Victor. I guess I will tackle that one day now that we've
decided not to work with FOrayFont...

Plus another few notes for the future:
- A facility for font subsitution is getting more important to have with
auto-detection since you don't specify the font names yourself anymore. Suppose
you have an FO file that uses StandardGrotesk but the actual font is
registered by auto-detection as StandardGroteskBSK-Regular. But part of the
problem is our lack of parser for AFM files which contains font family
information in contrast to the PFM file. FOrayFont has an advantage here.
- Suppose you have a font set 

DO NOT REPLY [Bug 41831] - [PATCH] Refactored configuration, font detection and caching, url resolution

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

http://issues.apache.org/bugzilla/show_bug.cgi?id=41831


[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED




--- Additional Comments From [EMAIL PROTECTED]  2007-05-28 07:33 ---
Patch applied: http://svn.apache.org/viewvc?view=revrev=542237

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.