You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-commits@xmlgraphics.apache.org by ac...@apache.org on 2008/07/31 18:23:57 UTC

svn commit: r681410 [1/2] - in /xmlgraphics/fop/branches/Temp_AFPGOCAResources: ./ lib/ src/documentation/ src/documentation/content/xdocs/ src/documentation/content/xdocs/0.95/ src/documentation/content/xdocs/trunk/ src/java/org/apache/fop/fo/flow/ sr...

Author: acumiskey
Date: Thu Jul 31 09:23:51 2008
New Revision: 681410

URL: http://svn.apache.org/viewvc?rev=681410&view=rev
Log:
Merged revisions 681296,681307 via svnmerge from 
https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk

................
  r681296 | jeremias | 2008-07-31 09:07:42 +0100 (Thu, 31 Jul 2008) | 12 lines
  
  Blocked revisions 681286,681291 via svnmerge
  
  ........
    r681286 | jeremias | 2008-07-31 09:15:23 +0200 (Do, 31 Jul 2008) | 1 line
    
    Move to XML Graphics Commons 1.3.1.
  ........
    r681291 | jeremias | 2008-07-31 09:45:13 +0200 (Do, 31 Jul 2008) | 1 line
    
    Increase version number.
  ........
................
  r681307 | jeremias | 2008-07-31 10:06:10 +0100 (Thu, 31 Jul 2008) | 149 lines
  
  Merged revisions 636407-637074,637076-637118,637120-637790,637792-637856,637858-637992,637994-638047,638049-638307,638309-638315,638318-638936,638938-640888,640890-642905,642907-647402,647404-647536,647538-648983,648985-649005,649007-649013,649015-650549,650551-651301,651303-653536,653538-654452,654454-656285,656287-656523,656525-657519,657521-661579,661581-663481,663483-664691,664693-681285,681287-681290,681292-681298 via svnmerge from 
  https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/fop-0_95
  
  ........
    r666635 | jeremias | 2008-06-11 14:18:53 +0200 (Mi, 11 Jun 2008) | 1 line
    
    Fixed resolution handling inside AWT preview dialog.
  ........
    r666662 | jeremias | 2008-06-11 15:33:20 +0200 (Mi, 11 Jun 2008) | 1 line
    
    Some notes on RTF and print output.
  ........
    r668533 | jeremias | 2008-06-17 09:57:55 +0200 (Di, 17 Jun 2008) | 2 lines
    
    Bugzilla #45151:
    Note on the "compiling" page that Ant 1.7 is required. The README file already points to this page.
  ........
    r668534 | jeremias | 2008-06-17 09:58:40 +0200 (Di, 17 Jun 2008) | 2 lines
    
    Update known issues.
    Remove ApacheConEU logo.
  ........
    r668550 | jeremias | 2008-06-17 10:05:22 +0200 (Di, 17 Jun 2008) | 2 lines
    
    Bugzilla #45146:
    Removed duplicate LICENSE.txt and Notice.txt from the JAR.
  ........
    r668570 | jeremias | 2008-06-17 10:54:07 +0200 (Di, 17 Jun 2008) | 1 line
    
    Wrong line number reported in the case of a line overflow.
  ........
    r668641 | jeremias | 2008-06-17 14:59:25 +0200 (Di, 17 Jun 2008) | 1 line
    
    Fixed potential NPE.
  ........
    r669118 | jeremias | 2008-06-18 11:02:45 +0200 (Mi, 18 Jun 2008) | 4 lines
    
    Bugzilla #44412:
    Regression fix for empty pages caused by multiple collapsible breaks.
    No more empty block areas if a break-before occurs on the first child of an FO to match the behaviour of tables and other FO implementations (clarification by XSL WG pending).
    Added an accessor interface for break-before/-after to avoid long if..else lists in BlockStackingLayoutManager.
  ........
    r669173 | jeremias | 2008-06-18 16:07:27 +0200 (Mi, 18 Jun 2008) | 7 lines
    
    Bugzilla #44887:
    Fixed potential multi-threading problem concerning the use of DecimalFormat.
    
    Results from performance measurements in a separate test (operation repeated 100'000 times, exemplary):
    shared static variable: ~220ms (old choice, problematic!)
    always create new instance: ~480ms
    ThreadLocal: ~220ms (new choice)
  ........
    r669478 | jeremias | 2008-06-19 15:03:57 +0200 (Do, 19 Jun 2008) | 4 lines
    
    Bugzilla #44412:
    Improvements after Vincent's feedback:
    Removal of the somewhat ugly Reference.
    getBreakBefore() reduced to private visibility.
  ........
    r670551 | jeremias | 2008-06-23 14:54:27 +0200 (Mo, 23 Jun 2008) | 3 lines
    
    Use configured source and target resolution for foreign objects in RTF output.
    Fixed intrinsic size calculation for SVG images when source resolution is not 72 dpi.
    Fixed calculation of px2mm values in the SVG to G2D converter (used by RTF output).
  ........
    r673750 | adelmelle | 2008-07-03 20:25:01 +0200 (Do, 03 Jul 2008) | 1 line
    
    Fix for Bugzilla 45295 (already committed to the trunk with r672010, r672495 and r672496)
  ........
    r674304 | jeremias | 2008-07-06 17:09:10 +0200 (So, 06 Jul 2008) | 18 lines
    
    Bugzilla #43606:
    column-width accepts percent values (proportional-column-width and % working)
    Table width accepts percent values (100% of the page width as standard)
    Nested tables are working
    It is also possible to make nested tables with a higher depth than 3 without causing word to crash
    Submitted by: Maximilan Aster <maximilian.aster.at.boc-eu.com>
    
    Changes to the patch by Jeremias:
    - Patch simplified (reuse of ColumnSetup from the layoutmgr package)
    - Percentages and proportional-column-width didn't work properly in my tests -> fixed
    - Adjustments for FOP code conventions
    
    Bugzilla #43824:
    page-number-citation working but has to be refreshed inside word to show the correct values
    Submitted by: Maximilan Aster <maximilian.aster.at.boc-eu.com>
    
    Changes to the patch by Jeremias:
    - Adjustments for FOP code conventions
  ........
    r674314 | jeremias | 2008-07-06 18:40:08 +0200 (So, 06 Jul 2008) | 7 lines
    
    Bugzilla #43825:
    leader supports fixed percent values for leader-length, most other properties
    use-content, leader-pattern-width not implemented
    Submitted by: Maximilan Aster <maximilian.aster.at.boc-eu.com>
    
    Changes to the patch by Jeremias:
    - Adjustments for FOP code conventions
  ........
    r674317 | jeremias | 2008-07-06 18:44:43 +0200 (So, 06 Jul 2008) | 1 line
    
    Doc update after RTF changes.
  ........
    r675106 | jeremias | 2008-07-09 09:03:46 +0200 (Mi, 09 Jul 2008) | 2 lines
    
    Bugzilla #45366:
    Document missing feature.
  ........
    r675150 | jeremias | 2008-07-09 14:56:41 +0200 (Mi, 09 Jul 2008) | 2 lines
    
    Bugzilla #39980:
    Fixed image scaling for RTF output.
  ........
    r675151 | jeremias | 2008-07-09 14:57:06 +0200 (Mi, 09 Jul 2008) | 1 line
    
    Removed unused code.
  ........
    r675152 | jeremias | 2008-07-09 14:58:18 +0200 (Mi, 09 Jul 2008) | 1 line
    
    Don't generate commands for default values.
  ........
    r675707 | jeremias | 2008-07-10 21:58:27 +0200 (Do, 10 Jul 2008) | 1 line
    
    Bugfix: -imagein didn't work because the stylesheet didn't get copied into fop.jar.
  ........
    r680715 | jeremias | 2008-07-29 16:37:10 +0200 (Di, 29 Jul 2008) | 1 line
    
    Found a surplus "pop state" which somehow causes a regression (fill color doesn't get properly reset) between 0.94 and 0.95. Shows in Barcode4J's fop-extension-demo.fo. The line has already been there in 0.94 but only shows in 0.95 probably due to an additional save/restore state pair added in PDFRenderer for reference areas after the block-container area refactoring.
  ........
    r680820 | jeremias | 2008-07-29 22:02:14 +0200 (Di, 29 Jul 2008) | 2 lines
    
    Bugzilla #41306:
    The AWT Renderer is really not out-of-order capable.
  ........
    r681284 | jeremias | 2008-07-31 08:47:49 +0200 (Do, 31 Jul 2008) | 1 line
    
    Some updates to status.xml (I was not the only one working on the final release).
  ........
    r681290 | jeremias | 2008-07-31 09:44:51 +0200 (Do, 31 Jul 2008) | 2 lines
    
    Website updates for the 0.95 release.
    The projectInfo plug-in of Forrest is not ideal for doing a bugfix release. It's not possible to combine the changes for two releases.
  ........
    r681292 | jeremias | 2008-07-31 09:47:13 +0200 (Do, 31 Jul 2008) | 1 line
    
    Disabling the ApacheCon ad for the release build.
  ........
................

Added:
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/properties/BreakPropertySet.java
      - copied unchanged from r681307, xmlgraphics/fop/trunk/src/java/org/apache/fop/fo/properties/BreakPropertySet.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfLeader.java
      - copied unchanged from r681307, xmlgraphics/fop/trunk/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfLeader.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/rtflib/tools/PercentContext.java
      - copied unchanged from r681307, xmlgraphics/fop/trunk/src/java/org/apache/fop/render/rtf/rtflib/tools/PercentContext.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/test/layoutengine/standard-testcases/block_break-before_bug44412_2.xml
      - copied unchanged from r681307, xmlgraphics/fop/trunk/test/layoutengine/standard-testcases/block_break-before_bug44412_2.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/test/resources/images/circles.svg
      - copied unchanged from r681307, xmlgraphics/fop/trunk/test/resources/images/circles.svg
Modified:
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/   (props changed)
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/README
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/build.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/known-issues.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/lib/avalon-framework-4.2.0.jar
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/0.95/compiling.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/0.95/output.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/knownissues.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/site.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/tabs.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/trunk/compiling.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/trunk/output.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/skinconf.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/Block.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/BlockContainer.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/ListBlock.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/ListItem.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/Table.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/TableAndCaption.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/TableRow.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fonts/MultiByteFont.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/image/loader/batik/ImageConverterSVG2G2D.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/image/loader/batik/PreloaderSVG.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/BlockContainerLayoutManager.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/BlockStackingLayoutManager.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/LayoutContext.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/table/ColumnSetup.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/table/TableLayoutManager.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/pdf/PDFNumber.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/awt/viewer/PreviewDialog.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/awt/viewer/PreviewPanel.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/pdf/PDFGraphics2DAdapter.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/BorderAttributesConverter.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/FoUnitsConverter.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/PageAttributesConverter.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/RTFHandler.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/TextAttributesConverter.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfAttributes.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfExternalGraphic.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfPage.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfPageNumberCitation.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfTable.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfTableRow.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfTextrun.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/util/BreakUtil.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/status.xml
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/test/java/org/apache/fop/image/loader/batik/ImageLoaderTestCase.java
    xmlgraphics/fop/branches/Temp_AFPGOCAResources/test/layoutengine/standard-testcases/block_break-before_bug44412.xml

Propchange: xmlgraphics/fop/branches/Temp_AFPGOCAResources/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Thu Jul 31 09:23:51 2008
@@ -1 +1 @@
-/xmlgraphics/fop/trunk:1-680645
+/xmlgraphics/fop/trunk:1-681407

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/README
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/README?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/README (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/README Thu Jul 31 09:23:51 2008
@@ -90,11 +90,11 @@
   RELEASE NOTES
 ==============================================================================
 
-Version 0.95beta
-================
+Version 0.95
+============
 
-This is a pre-version of the third production grade release of the new FOP
-codebase. It contains many bug fixes and new features. See below for details.
+This is a production grade release of Apache FOP.
+It contains many bug fixes and new features. See below for details.
 
 Compliance
 ----------
@@ -128,6 +128,10 @@
 The long list of changes in this and earlier releases is available at
 http://xmlgraphics.apache.org/fop/changes.html.
 
+Changes since Version 0.95beta
+------------------------------
+Please refer to the list of changes on the web:
+http://xmlgraphics.apache.org/fop/changes.html
 
 
 Version 0.94

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/build.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/build.xml?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/build.xml (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/build.xml Thu Jul 31 09:23:51 2008
@@ -401,6 +401,7 @@
         <include name="**/*.icm"/>
         <include name="**/*.xml"/>
         <include name="**/*.LICENSE.txt"/>
+        <include name="**/*.xsl"/>
       </fileset>
       <fileset dir="${build.gensrc.dir}">
         <include name="**/*.xml"/>

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/known-issues.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/known-issues.xml?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/known-issues.xml (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/known-issues.xml Thu Jul 31 09:23:51 2008
@@ -21,8 +21,9 @@
         MIF and SVG output support have not been restored, yet.
       </known-issue>
       <known-issue>
-        Java2D/AWT support has been improved, but some problems remain,
-        for example with block-containers.
+        RTF output is inferior to other output formats supported by FOP.
+        For details, please see the "Output Targets" page of the release
+        you're using.
       </known-issue>
       <known-issue>
         Auto table layout is not implemented, yet.
@@ -81,10 +82,6 @@
         table-body, table-header, table-footer and table-row.
       </known-issue>
       <known-issue>
-        The backgrounds of table-body, table-header, table-footer and 
-        table-column are not painted, yet.
-      </known-issue>
-      <known-issue>
         Border and padding conditionality are not supported on table-cells, yet.
       </known-issue>
       <known-issue>

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/lib/avalon-framework-4.2.0.jar
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/lib/avalon-framework-4.2.0.jar?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
Binary files - no diff available.

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/0.95/compiling.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/0.95/compiling.xml?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/0.95/compiling.xml (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/0.95/compiling.xml Thu Jul 31 09:23:51 2008
@@ -66,7 +66,7 @@
       <section id="env-ant">
         <title>Apache Ant</title>
         <p>
-          <a href="ext:ant">Apache Ant</a> must be installed in order to
+          <a href="ext:ant">Apache Ant</a> (Version 1.7 or later) must be installed in order to
           build FOP. Following best practices we don't include Ant with FOP anymore. You can find the
           <a href="ext:ant/manual/">instructions to install Ant in the Ant manual</a> on the web.
         </p>

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/0.95/output.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/0.95/output.xml?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/0.95/output.xml (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/0.95/output.xml Thu Jul 31 09:23:51 2008
@@ -703,6 +703,24 @@
   <note>RTF output is currently unmaintained and lacks many features compared to other output
     formats. Using other editable formats like Open Document Format, instead of producing XSL-FO
     then RTF through FOP, might give better results.</note>
+  <p>
+    These are some known restrictions compared to other supported output formats (not a complete list):
+  </p>
+  <ul>
+    <li>
+      Not supported/implemented:
+      <ul>
+        <li>break-before/after (supported by the RTF library but not tied into the RTFHandler)</li>
+        <li>fo:page-number-citation-last</li>
+        <li>keeps (supported by the RTF library but not tied into the RTFHandler)</li>
+        <li>region-start/end (RTF limitation)</li>
+        <li>multiple columns</li>
+      </ul>
+    </li>
+    <li>Only a single page-master is supported</li>
+    <li>Not all variations of fo:leader are supported (RTF limitation)</li>
+    <li>percentages are not supported everywhere</li>
+  </ul>
 </section>
 <section id="xml">
   <title>XML (Area Tree XML)</title>
@@ -735,6 +753,16 @@
     It is possible to directly print the document from the command line.
     This is done with the same code that renders to the Java2D/AWT renderer.
   </p>
+  <section id="print-issues">
+    <title>Known issues</title>
+    <p>
+      If you run into the problem that the printed output is incomplete on Windows:
+      this often happens to users printing to a PCL printer.
+      There seems to be an incompatibility between Java and certain PCL printer drivers
+      on Windows. Since most network-enabled laser printers support PostScript, try
+      switching to the PostScript printer driver for that printer model.
+    </p>
+  </section>
 </section>
 <section id="bitmap">
   <title>Bitmap (TIFF/PNG)</title>

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/knownissues.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/knownissues.xml?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/knownissues.xml (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/knownissues.xml Thu Jul 31 09:23:51 2008
@@ -66,6 +66,7 @@
   <section>
     <title>Other known issues</title>
     <p>This section lists other known issues.</p>
+    <!-- See <root>/known-issues.xml for the source document of this section! -->
     <xi:include href="cocoon://knownissues-raw-static.xml#xpointer(/document/body/*)"/>
   </section>
 </section>

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/site.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/site.xml?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/site.xml (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/site.xml Thu Jul 31 09:23:51 2008
@@ -96,10 +96,11 @@
   <!--
   BEGIN Version 0.95 documentation tab
   -->
-  <trunk label="FOP 0.95beta" href="0.95/" tab="stableversion">
+  <trunk label="FOP 0.95" href="0.95/" tab="stableversion">
     <about label="About" href="index.html"/>
-    <release label="Release Notes" href="releaseNotes_0.95beta.html"/>
-    <changes label="Changes" href="changes_0.95beta.html"/>
+    <release label="Release Notes" href="releaseNotes_0.95.html"/>
+    <changes label="Changes (0.95)" href="changes_0.95.html"/>
+    <changes-beta label="Changes (0.95beta)" href="changes_0.95beta.html"/>
     <knownissues label="Known Issues" href="knownissues_overview.html"/>
     <upgrading label="Upgrading" href="upgrading.html"/>
     

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/tabs.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/tabs.xml?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/tabs.xml (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/tabs.xml Thu Jul 31 09:23:51 2008
@@ -22,7 +22,7 @@
 <tabs software="FOP" title="FOP" copyright="@year@ The Apache Software Foundation" xmlns:xlink="http://www.w3.org/1999/xlink">
   <tab label="Home" dir=""/>
   <tab label="Version 0.94" dir="0.94/"/>
-  <tab label="Version 0.95beta" dir="0.95/"/>
+  <tab label="Version 0.95" dir="0.95/"/>
   <tab label="FOP Trunk" dir="trunk/"/>
   <tab label="Development" dir="dev/"/>
 </tabs>

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/trunk/compiling.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/trunk/compiling.xml?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/trunk/compiling.xml (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/trunk/compiling.xml Thu Jul 31 09:23:51 2008
@@ -66,7 +66,7 @@
       <section id="env-ant">
         <title>Apache Ant</title>
         <p>
-          <a href="ext:ant">Apache Ant</a> must be installed in order to
+          <a href="ext:ant">Apache Ant</a> (Version 1.7 or later) must be installed in order to
           build FOP. Following best practices we don't include Ant with FOP anymore. You can find the
           <a href="ext:ant/manual/">instructions to install Ant in the Ant manual</a> on the web.
         </p>

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/trunk/output.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/trunk/output.xml?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/trunk/output.xml (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/content/xdocs/trunk/output.xml Thu Jul 31 09:23:51 2008
@@ -754,6 +754,24 @@
   <note>RTF output is currently unmaintained and lacks many features compared to other output
     formats. Using other editable formats like Open Document Format, instead of producing XSL-FO
     then RTF through FOP, might give better results.</note>
+  <p>
+    These are some known restrictions compared to other supported output formats (not a complete list):
+  </p>
+  <ul>
+    <li>
+      Not supported/implemented:
+      <ul>
+        <li>break-before/after (supported by the RTF library but not tied into the RTFHandler)</li>
+        <li>fo:page-number-citation-last</li>
+        <li>keeps (supported by the RTF library but not tied into the RTFHandler)</li>
+        <li>region-start/end (RTF limitation)</li>
+        <li>multiple columns</li>
+      </ul>
+    </li>
+    <li>Only a single page-master is supported</li>
+    <li>Not all variations of fo:leader are supported (RTF limitation)</li>
+    <li>percentages are not supported everywhere</li>
+  </ul>
 </section>
 <section id="xml">
   <title>XML (Area Tree XML)</title>
@@ -786,6 +804,16 @@
     It is possible to directly print the document from the command line.
     This is done with the same code that renders to the Java2D/AWT renderer.
   </p>
+  <section id="print-issues">
+    <title>Known issues</title>
+    <p>
+      If you run into the problem that the printed output is incomplete on Windows:
+      this often happens to users printing to a PCL printer.
+      There seems to be an incompatibility between Java and certain PCL printer drivers
+      on Windows. Since most network-enabled laser printers support PostScript, try
+      switching to the PostScript printer driver for that printer model.
+    </p>
+  </section>
 </section>
 <section id="bitmap">
   <title>Bitmap (TIFF/PNG)</title>
@@ -937,3 +965,4 @@
 </document>
 
 
+

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/skinconf.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/skinconf.xml?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/skinconf.xml (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/documentation/skinconf.xml Thu Jul 31 09:23:51 2008
@@ -378,6 +378,7 @@
       <height>125</height>
     </credit>
     -->
+    <!--
     <credit box-location="alt2">
       <name>ApacheCon US 2008</name>
       <url>http://us.apachecon.com/</url>
@@ -385,6 +386,7 @@
       <width>125</width>
       <height>125</height>
     </credit>
+    -->
     
     <credit role="pdf">
       <name>PDF created by Apache FOP</name>

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/Block.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/Block.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/Block.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/Block.java Thu Jul 31 09:23:51 2008
@@ -32,6 +32,7 @@
 import org.apache.fop.fo.NullCharIterator;
 import org.apache.fop.fo.PropertyList;
 import org.apache.fop.fo.ValidationException;
+import org.apache.fop.fo.properties.BreakPropertySet;
 import org.apache.fop.fo.properties.CommonBorderPaddingBackground;
 import org.apache.fop.fo.properties.CommonFont;
 import org.apache.fop.fo.properties.CommonHyphenation;
@@ -44,7 +45,7 @@
   * Class modelling the <a href="http://www.w3.org/TR/xsl/#fo_block">
   * <code>fo:block object</code></a>.
   */
-public class Block extends FObjMixed {
+public class Block extends FObjMixed implements BreakPropertySet {
 
     // used for FO validation
     private boolean blockOrInlineItemFound = false;

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/BlockContainer.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/BlockContainer.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/BlockContainer.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/BlockContainer.java Thu Jul 31 09:23:51 2008
@@ -28,6 +28,7 @@
 import org.apache.fop.fo.FObj;
 import org.apache.fop.fo.PropertyList;
 import org.apache.fop.fo.ValidationException;
+import org.apache.fop.fo.properties.BreakPropertySet;
 import org.apache.fop.fo.properties.CommonAbsolutePosition;
 import org.apache.fop.fo.properties.CommonBorderPaddingBackground;
 import org.apache.fop.fo.properties.CommonMarginBlock;
@@ -38,7 +39,7 @@
  * Class modelling the <a href="http://www.w3.org/TR/xsl/#fo_block-container">
  * <code>fo:block-container</code></a> object.
  */
-public class BlockContainer extends FObj {
+public class BlockContainer extends FObj implements BreakPropertySet {
     // The value of properties relevant for fo:block-container.
     private CommonAbsolutePosition commonAbsolutePosition;
     private CommonBorderPaddingBackground commonBorderPaddingBackground;

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/ListBlock.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/ListBlock.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/ListBlock.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/ListBlock.java Thu Jul 31 09:23:51 2008
@@ -27,6 +27,7 @@
 import org.apache.fop.fo.FObj;
 import org.apache.fop.fo.PropertyList;
 import org.apache.fop.fo.ValidationException;
+import org.apache.fop.fo.properties.BreakPropertySet;
 import org.apache.fop.fo.properties.CommonBorderPaddingBackground;
 import org.apache.fop.fo.properties.CommonMarginBlock;
 import org.apache.fop.fo.properties.KeepProperty;
@@ -35,7 +36,7 @@
  * Class modelling the <a href=http://www.w3.org/TR/xsl/#fo_list-block">
  * <code>fo:list-block</code></a> object.
  */
-public class ListBlock extends FObj {
+public class ListBlock extends FObj implements BreakPropertySet {
     // The value of properties relevant for fo:list-block.
     private CommonBorderPaddingBackground commonBorderPaddingBackground;
     private CommonMarginBlock commonMarginBlock;

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/ListItem.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/ListItem.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/ListItem.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/ListItem.java Thu Jul 31 09:23:51 2008
@@ -26,6 +26,7 @@
 import org.apache.fop.fo.FObj;
 import org.apache.fop.fo.PropertyList;
 import org.apache.fop.fo.ValidationException;
+import org.apache.fop.fo.properties.BreakPropertySet;
 import org.apache.fop.fo.properties.CommonBorderPaddingBackground;
 import org.apache.fop.fo.properties.CommonMarginBlock;
 import org.apache.fop.fo.properties.KeepProperty;
@@ -34,7 +35,7 @@
  * Class modelling the <a href=http://www.w3.org/TR/xsl/#fo_list-item">
  * <code>fo:list-item</code></a> object.
  */
-public class ListItem extends FObj {
+public class ListItem extends FObj implements BreakPropertySet {
     // The value of properties relevant for fo:list-item.
     private CommonBorderPaddingBackground commonBorderPaddingBackground;
     private CommonMarginBlock commonMarginBlock;

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/Table.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/Table.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/Table.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/Table.java Thu Jul 31 09:23:51 2008
@@ -31,6 +31,7 @@
 import org.apache.fop.fo.PropertyList;
 import org.apache.fop.fo.StaticPropertyList;
 import org.apache.fop.fo.ValidationException;
+import org.apache.fop.fo.properties.BreakPropertySet;
 import org.apache.fop.fo.properties.CommonBorderPaddingBackground;
 import org.apache.fop.fo.properties.CommonMarginBlock;
 import org.apache.fop.fo.properties.KeepProperty;
@@ -42,7 +43,7 @@
  * Class modelling the <a href="http://www.w3.org/TR/xsl/#fo_table">
  * <code>fo:table</code></a> object.
  */
-public class Table extends TableFObj implements ColumnNumberManagerHolder {
+public class Table extends TableFObj implements ColumnNumberManagerHolder, BreakPropertySet {
 
     /** properties */
     private CommonBorderPaddingBackground commonBorderPaddingBackground;

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/TableAndCaption.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/TableAndCaption.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/TableAndCaption.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/TableAndCaption.java Thu Jul 31 09:23:51 2008
@@ -32,7 +32,7 @@
  * <code>fo:table-and-caption</code></a> property.
  * @todo needs implementation
  */
-public class TableAndCaption extends FObj {
+public class TableAndCaption extends FObj /*implements BreakPropertySet*/ {
     // The value of properties relevant for fo:table-and-caption.
     // Unused but valid items, commented out for performance:
     //     private CommonAccessibility commonAccessibility;

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/TableRow.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/TableRow.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/TableRow.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fo/flow/table/TableRow.java Thu Jul 31 09:23:51 2008
@@ -27,6 +27,7 @@
 import org.apache.fop.fo.FONode;
 import org.apache.fop.fo.PropertyList;
 import org.apache.fop.fo.ValidationException;
+import org.apache.fop.fo.properties.BreakPropertySet;
 import org.apache.fop.fo.properties.CommonBorderPaddingBackground;
 import org.apache.fop.fo.properties.KeepProperty;
 import org.apache.fop.fo.properties.LengthRangeProperty;
@@ -35,7 +36,7 @@
  * Class modelling the <a href="http://www.w3.org/TR/xsl/#fo_table-row">
  * <code>fo:table-row</code></a> object.
  */
-public class TableRow extends TableCellContainer {
+public class TableRow extends TableCellContainer implements BreakPropertySet {
     // The value of properties relevant for fo:table-row.
     private LengthRangeProperty blockProgressionDimension;
     private CommonBorderPaddingBackground commonBorderPaddingBackground;

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fonts/MultiByteFont.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fonts/MultiByteFont.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fonts/MultiByteFont.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/fonts/MultiByteFont.java Thu Jul 31 09:23:51 2008
@@ -29,7 +29,6 @@
 public class MultiByteFont extends CIDFont {
 
     private static int uniqueCounter = -1;
-    private static final DecimalFormat COUNTER_FORMAT = new DecimalFormat("00000");
 
     private String ttcName = null;
     private String encoding = "Identity-H";
@@ -58,7 +57,8 @@
                 uniqueCounter = 0; //We need maximum 5 character then we start again
             }
         }
-        String cntString = COUNTER_FORMAT.format(uniqueCounter);
+        DecimalFormat counterFormat = new DecimalFormat("00000");
+        String cntString = counterFormat.format(uniqueCounter);
 
         //Subset prefix as described in chapter 5.5.3 of PDF 1.4
         StringBuffer sb = new StringBuffer("E");

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/image/loader/batik/ImageConverterSVG2G2D.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/image/loader/batik/ImageConverterSVG2G2D.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/image/loader/batik/ImageConverterSVG2G2D.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/image/loader/batik/ImageConverterSVG2G2D.java Thu Jul 31 09:23:51 2008
@@ -68,10 +68,10 @@
         }
 
         //Prepare
-        float pxToMillimeter = (float)UnitConv.mm2in(72); //default: 72dpi
+        float pxToMillimeter = UnitConv.IN2MM / 72; //default: 72dpi
         Number ptm = (Number)hints.get(ImageProcessingHints.SOURCE_RESOLUTION);
         if (ptm != null) {
-            pxToMillimeter = (float)UnitConv.mm2in(ptm.doubleValue());
+            pxToMillimeter = (float)(UnitConv.IN2MM / ptm.doubleValue());
         }
         UserAgent ua = createBatikUserAgent(pxToMillimeter);
         GVTBuilder builder = new GVTBuilder();

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/image/loader/batik/PreloaderSVG.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/image/loader/batik/PreloaderSVG.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/image/loader/batik/PreloaderSVG.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/image/loader/batik/PreloaderSVG.java Thu Jul 31 09:23:51 2008
@@ -46,6 +46,7 @@
 import org.apache.xmlgraphics.image.loader.impl.ImageXMLDOM;
 import org.apache.xmlgraphics.image.loader.util.ImageUtil;
 import org.apache.xmlgraphics.util.MimeConstants;
+import org.apache.xmlgraphics.util.UnitConv;
 
 import org.apache.fop.svg.SimpleSVGUserAgent;
 import org.apache.fop.util.UnclosableInputStream;
@@ -119,7 +120,7 @@
                     in.mark(length + 1);
                     SAXSVGDocumentFactory factory = new SAXSVGDocumentFactory(
                             getParserName());
-                    doc = (SVGDocument) factory.createSVGDocument(src.getSystemId(), in);
+                    doc = factory.createSVGDocument(src.getSystemId(), in);
                 }
                 ImageInfo info = createImageInfo(uri, context, doc);
 
@@ -154,7 +155,7 @@
 
         private ImageInfo createImageInfo(String uri, ImageContext context, SVGDocument doc) {
             Element e = doc.getRootElement();
-            float pxUnitToMillimeter = 25.4f / context.getSourceResolution();
+            float pxUnitToMillimeter = UnitConv.IN2MM / context.getSourceResolution();
             UserAgent userAg = new SimpleSVGUserAgent(pxUnitToMillimeter,
                         new AffineTransform()) {
 
@@ -184,9 +185,12 @@
             float height = UnitProcessor.svgVerticalLengthToUserSpace(
                     s, SVGOMDocument.SVG_HEIGHT_ATTRIBUTE, uctx);
 
+            int widthMpt = (int)Math.round(px2mpt(width, context.getSourceResolution()));
+            int heightMpt = (int)Math.round(px2mpt(height, context.getSourceResolution()));
+
             ImageInfo info = new ImageInfo(uri, MimeConstants.MIME_SVG);
             ImageSize size = new ImageSize();
-            size.setSizeInMillipoints(Math.round(width * 1000), Math.round(height * 1000));
+            size.setSizeInMillipoints(widthMpt, heightMpt);
             //Set the resolution to that of the FOUserAgent
             size.setResolution(context.getSourceResolution());
             size.calcPixelsFromSize();
@@ -210,4 +214,8 @@
 
     }
 
+    private static double px2mpt(double px, double resolution) {
+        return px * 1000 * UnitConv.IN2PT / resolution;
+    }
+
 }

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/BlockContainerLayoutManager.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/BlockContainerLayoutManager.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/BlockContainerLayoutManager.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/BlockContainerLayoutManager.java Thu Jul 31 09:23:51 2008
@@ -251,12 +251,11 @@
         List returnList = new LinkedList();
 
         if (!breakBeforeServed) {
-            try {
+            breakBeforeServed = true;
+            if (!context.suppressBreakBefore()) {
                 if (addKnuthElementsForBreakBefore(returnList, context)) {
                     return returnList;
                 }
-            } finally {
-                breakBeforeServed = true;
             }
         }
 
@@ -281,6 +280,10 @@
                 childLC.setStackLimitBP(MinOptMax.subtract(context.getStackLimitBP(), stackLimit));
                 childLC.setRefIPD(relDims.ipd);
                 childLC.setWritingMode(getBlockContainerFO().getWritingMode());
+                if (curLM == this.childLMs.get(0)) {
+                    childLC.setFlags(LayoutContext.SUPPRESS_BREAK_BEFORE);
+                    //Handled already by the parent (break collapsing, see above)
+                }
 
                 // get elements from curLM
                 returnedList = curLM.getNextKnuthElements(childLC, alignment);

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/BlockStackingLayoutManager.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/BlockStackingLayoutManager.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/BlockStackingLayoutManager.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/BlockStackingLayoutManager.java Thu Jul 31 09:23:51 2008
@@ -31,11 +31,13 @@
 import org.apache.fop.area.Block;
 import org.apache.fop.area.BlockParent;
 import org.apache.fop.fo.FObj;
+import org.apache.fop.fo.properties.BreakPropertySet;
 import org.apache.fop.fo.properties.CommonBorderPaddingBackground;
 import org.apache.fop.fo.properties.SpaceProperty;
 import org.apache.fop.layoutmgr.inline.InlineLayoutManager;
 import org.apache.fop.layoutmgr.inline.LineLayoutManager;
 import org.apache.fop.traits.MinOptMax;
+import org.apache.fop.util.BreakUtil;
 import org.apache.fop.util.ListUtil;
 
 /**
@@ -255,12 +257,11 @@
         List returnList = new LinkedList();
 
         if (!breakBeforeServed) {
-            try {
+            breakBeforeServed = true;
+            if (!context.suppressBreakBefore()) {
                 if (addKnuthElementsForBreakBefore(returnList, context)) {
                     return returnList;
                 }
-            } finally {
-                breakBeforeServed = true;
             }
         }
 
@@ -294,6 +295,10 @@
                 childLC.setStackLimitBP(context.getStackLimitBP());
                 childLC.setRefIPD(referenceIPD);
             }
+            if (curLM == this.childLMs.get(0)) {
+                childLC.setFlags(LayoutContext.SUPPRESS_BREAK_BEFORE);
+                //Handled already by the parent (break collapsing, see above)
+            }
 
             // get elements from curLM
             returnedList = curLM.getNextKnuthElements(childLC, alignment);
@@ -1004,18 +1009,7 @@
      */
     protected boolean addKnuthElementsForBreakBefore(List returnList,
             LayoutContext context) {
-        int breakBefore = -1;
-        if (fobj instanceof org.apache.fop.fo.flow.Block) {
-            breakBefore = ((org.apache.fop.fo.flow.Block) fobj).getBreakBefore();
-        } else if (fobj instanceof org.apache.fop.fo.flow.BlockContainer) {
-            breakBefore = ((org.apache.fop.fo.flow.BlockContainer) fobj).getBreakBefore();
-        } else if (fobj instanceof org.apache.fop.fo.flow.ListBlock) {
-            breakBefore = ((org.apache.fop.fo.flow.ListBlock) fobj).getBreakBefore();
-        } else if (fobj instanceof org.apache.fop.fo.flow.ListItem) {
-            breakBefore = ((org.apache.fop.fo.flow.ListItem) fobj).getBreakBefore();
-        } else if (fobj instanceof org.apache.fop.fo.flow.table.Table) {
-            breakBefore = ((org.apache.fop.fo.flow.table.Table) fobj).getBreakBefore();
-        }
+        int breakBefore = getBreakBefore();
         if (breakBefore == EN_PAGE
                 || breakBefore == EN_COLUMN
                 || breakBefore == EN_EVEN_PAGE
@@ -1030,6 +1024,27 @@
     }
 
     /**
+     * Returns the break-before value of the current formatting object.
+     * @return the break-before value (Constants.EN_*)
+     */
+    private int getBreakBefore() {
+        int breakBefore = EN_AUTO;
+        if (fobj instanceof BreakPropertySet) {
+            breakBefore = ((BreakPropertySet)fobj).getBreakBefore();
+        }
+        if (true /* uncomment to only partially merge: && breakBefore != EN_AUTO*/) {
+            LayoutManager lm = getChildLM();
+            //It is assumed this is only called when the first LM is active.
+            if (lm instanceof BlockStackingLayoutManager) {
+                BlockStackingLayoutManager bslm = (BlockStackingLayoutManager)lm;
+                breakBefore = BreakUtil.compareBreakClasses(
+                        breakBefore, bslm.getBreakBefore());
+            }
+        }
+        return breakBefore;
+    }
+    
+    /**
      * Creates Knuth elements for break-after and adds them to the return list.
      * @param returnList return list to add the additional elements to
      * @param context the layout context
@@ -1038,16 +1053,8 @@
     protected boolean addKnuthElementsForBreakAfter(List returnList,
             LayoutContext context) {
         int breakAfter = -1;
-        if (fobj instanceof org.apache.fop.fo.flow.Block) {
-            breakAfter = ((org.apache.fop.fo.flow.Block) fobj).getBreakAfter();
-        } else if (fobj instanceof org.apache.fop.fo.flow.BlockContainer) {
-            breakAfter = ((org.apache.fop.fo.flow.BlockContainer) fobj).getBreakAfter();
-        } else if (fobj instanceof org.apache.fop.fo.flow.ListBlock) {
-            breakAfter = ((org.apache.fop.fo.flow.ListBlock) fobj).getBreakAfter();
-        } else if (fobj instanceof org.apache.fop.fo.flow.ListItem) {
-            breakAfter = ((org.apache.fop.fo.flow.ListItem) fobj).getBreakAfter();
-        } else if (fobj instanceof org.apache.fop.fo.flow.table.Table) {
-            breakAfter = ((org.apache.fop.fo.flow.table.Table) fobj).getBreakAfter();
+        if (fobj instanceof BreakPropertySet) {
+            breakAfter = ((BreakPropertySet)fobj).getBreakAfter();
         }
         if (breakAfter == EN_PAGE
                 || breakAfter == EN_COLUMN

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/LayoutContext.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/LayoutContext.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/LayoutContext.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/LayoutContext.java Thu Jul 31 09:23:51 2008
@@ -47,12 +47,10 @@
     public static final int CHECK_REF_AREA = 0x08;
 
     /**
-     * If this flag is set, it indicates that any leading fo:character
-     * objects with suppress-at-line-break="suppress" should not generate
-     * areas. This is the case at the beginning of each new LineArea
-     * except the first.
+     * If this flag is set, it indicates that any break-before values other than "auto" should
+     * not cause a mandatory break as this break was already handled by a parent layout manager.
      */
-    public static final int SUPPRESS_LEADING_SPACE = 0x10;
+    public static final int SUPPRESS_BREAK_BEFORE = 0x10;
     public static final int FIRST_AREA = 0x20;
     public static final int TRY_HYPHENATE = 0x40;
     public static final int LAST_AREA = 0x80;
@@ -227,8 +225,8 @@
         return ((this.flags & LAST_AREA) != 0);
     }
 
-    public boolean suppressLeadingSpace() {
-        return ((this.flags & SUPPRESS_LEADING_SPACE) != 0);
+    public boolean suppressBreakBefore() {
+        return ((this.flags & SUPPRESS_BREAK_BEFORE) != 0);
     }
 
     /**
@@ -655,7 +653,7 @@
         + "\nSpace Adjust: \t" + getSpaceAdjust()
         + "\nIPD Adjust: \t" + getIPDAdjust()
         + "\nResolve Leading Space: \t" + resolveLeadingSpace()
-        + "\nSuppress Leading Space: \t" + suppressLeadingSpace()
+        + "\nSuppress Break Before: \t" + suppressBreakBefore()
         + "\nIs First Area: \t" + isFirstArea()
         + "\nStarts New Area: \t" + startsNewArea()
         + "\nIs Last Area: \t" + isLastArea()

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java Thu Jul 31 09:23:51 2008
@@ -197,12 +197,11 @@
         List returnList = new LinkedList();
 
         if (!breakBeforeServed) {
-            try {
+            breakBeforeServed = true;
+            if (!context.suppressBreakBefore()) {
                 if (addKnuthElementsForBreakBefore(returnList, context)) {
                     return returnList;
                 }
-            } finally {
-                breakBeforeServed = true;
             }
         }
 

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/table/ColumnSetup.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/table/ColumnSetup.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/table/ColumnSetup.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/table/ColumnSetup.java Thu Jul 31 09:23:51 2008
@@ -184,10 +184,22 @@
      * @return the computed base unit (in millipoint)
      */
     protected double computeTableUnit(TableLayoutManager tlm) {
+        return computeTableUnit(tlm, tlm.getContentAreaIPD());
+    }
+
+    /**
+     * Works out the base unit for resolving proportional-column-width()
+     * [p-c-w(x) = x * base_unit_ipd]
+     *
+     * @param percentBaseContext the percent base context for relative values
+     * @param contentAreaIPD the IPD of the available content area
+     * @return the computed base unit (in millipoints)
+     */
+    public float computeTableUnit(PercentBaseContext percentBaseContext, int contentAreaIPD) {
 
         int sumCols = 0;
         float factors = 0;
-        double unit = 0;
+        float unit = 0;
 
         /* calculate the total width (specified absolute/percentages),
          * and work out the total number of factors to use to distribute
@@ -196,7 +208,7 @@
         for (Iterator i = colWidths.iterator(); i.hasNext();) {
             Length colWidth = (Length) i.next();
             if (colWidth != null) {
-                sumCols += colWidth.getValue(tlm);
+                sumCols += colWidth.getValue(percentBaseContext);
                 if (colWidth instanceof RelativeNumericProperty) {
                     factors += ((RelativeNumericProperty) colWidth).getTableUnits();
                 } else if (colWidth instanceof TableColLength) {
@@ -209,8 +221,8 @@
          * factors (if any)
          */
         if (factors > 0) {
-            if (sumCols < tlm.getContentAreaIPD()) {
-                unit = (tlm.getContentAreaIPD() - sumCols) / factors;
+            if (sumCols < contentAreaIPD) {
+                unit = (contentAreaIPD - sumCols) / factors;
             } else {
                 log.warn("No space remaining to distribute over columns.");
             }

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/table/TableLayoutManager.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/table/TableLayoutManager.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/table/TableLayoutManager.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/layoutmgr/table/TableLayoutManager.java Thu Jul 31 09:23:51 2008
@@ -267,12 +267,14 @@
         }
         addKnuthElementsForSpaceAfter(returnList, alignment);
 
-        //addKnuthElementsForBreakBefore(returnList, context);
-        int breakBefore = BreakUtil.compareBreakClasses(getTable().getBreakBefore(),
-                childLC.getBreakBefore());
-        if (breakBefore != Constants.EN_AUTO) {
-            returnList.add(0, new BreakElement(getAuxiliaryPosition(), 0,
-                    -KnuthElement.INFINITE, breakBefore, context));
+        if (!context.suppressBreakBefore()) {
+            //addKnuthElementsForBreakBefore(returnList, context);
+            int breakBefore = BreakUtil.compareBreakClasses(getTable().getBreakBefore(),
+                    childLC.getBreakBefore());
+            if (breakBefore != Constants.EN_AUTO) {
+                returnList.add(0, new BreakElement(getAuxiliaryPosition(), 0,
+                        -KnuthElement.INFINITE, breakBefore, context));
+            }
         }
 
         //addKnuthElementsForBreakAfter(returnList, context);

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/pdf/PDFNumber.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/pdf/PDFNumber.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/pdf/PDFNumber.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/pdf/PDFNumber.java Thu Jul 31 09:23:51 2008
@@ -67,11 +67,33 @@
         return doubleOut(doubleDown, 6);
     }
 
-    // Static cache. Possible concurrency implications. See comment in doubleOut(double, int).
-    private static DecimalFormat[] decimalFormatCache = new DecimalFormat[17];
-
     private static final String BASE_FORMAT = "0.################";
 
+    private static class DecimalFormatThreadLocal extends ThreadLocal {
+        
+        private int dec;
+        
+        public DecimalFormatThreadLocal(int dec) {
+            this.dec = dec;
+        }
+        
+        protected synchronized Object initialValue() {
+            String s = "0";
+            if (dec > 0) {
+                s = BASE_FORMAT.substring(0, dec + 2);
+            }
+            DecimalFormat df = new DecimalFormat(s, new DecimalFormatSymbols(Locale.US));
+            return df;
+        }
+    };
+    //DecimalFormat is not thread-safe!
+    private static final ThreadLocal[] DECIMAL_FORMAT_CACHE = new DecimalFormatThreadLocal[17];
+    static {
+        for (int i = 0, c = DECIMAL_FORMAT_CACHE.length; i < c; i++) {
+            DECIMAL_FORMAT_CACHE[i] = new DecimalFormatThreadLocal(i);
+        }
+    }
+    
     /**
      * Output a double value to a string suitable for PDF.
      * In this method it is possible to set the maximum
@@ -82,29 +104,15 @@
      * @return the value as a string
      */
     public static String doubleOut(double doubleDown, int dec) {
-        if (dec < 0 || dec >= decimalFormatCache.length) {
+        if (dec < 0 || dec >= DECIMAL_FORMAT_CACHE.length) {
             throw new IllegalArgumentException("Parameter dec must be between 1 and "
-                    + (decimalFormatCache.length + 1));
+                    + (DECIMAL_FORMAT_CACHE.length + 1));
         }
-        if (decimalFormatCache[dec] == null) {
-            //We don't care about the rare case where a DecimalFormat might be replaced in
-            //a multi-threaded environment, so we don't synchronize the access to the static
-            //array (mainly for performance reasons). After all, the DecimalFormat instances
-            //read-only objects so it doesn't matter which instance is used as long as one
-            //is available.
-            String s = "0";
-            if (dec > 0) {
-                s = BASE_FORMAT.substring(0, dec + 2);
-            }
-            DecimalFormat df = new DecimalFormat(s, new DecimalFormatSymbols(Locale.US));
-            decimalFormatCache[dec] = df;
-        }
-        return decimalFormatCache[dec].format(doubleDown);
+        DecimalFormat df = (DecimalFormat)DECIMAL_FORMAT_CACHE[dec].get();
+        return df.format(doubleDown);
     }
 
-    /**
-     * {@inheritDoc}
-     */
+    /** {@inheritDoc} */
     protected String toPDFString() {
         if (getNumber() == null) {
             throw new IllegalArgumentException(

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/awt/viewer/PreviewDialog.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/awt/viewer/PreviewDialog.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/awt/viewer/PreviewDialog.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/awt/viewer/PreviewDialog.java Thu Jul 31 09:23:51 2008
@@ -38,7 +38,6 @@
 import java.awt.event.WindowEvent;
 import java.awt.print.PrinterException;
 import java.awt.print.PrinterJob;
-
 import java.text.DecimalFormat;
 import java.text.DecimalFormatSymbols;
 import java.util.Locale;
@@ -60,8 +59,8 @@
 import javax.swing.KeyStroke;
 import javax.swing.SwingUtilities;
 
-import org.apache.fop.apps.FOUserAgent;
 import org.apache.fop.apps.FOPException;
+import org.apache.fop.apps.FOUserAgent;
 import org.apache.fop.render.awt.AWTRenderer;
 
 /**
@@ -76,6 +75,8 @@
     protected AWTRenderer renderer;
     /** The FOUserAgent associated with this window */
     protected FOUserAgent foUserAgent;
+    /** The originally configured target resolution */
+    protected float configuredTargetResolution;
     /**
      * Renderable instance that can be used to reload and re-render a document after
      * modifications.
@@ -107,6 +108,7 @@
     public PreviewDialog(FOUserAgent foUserAgent, Renderable renderable) {
         renderer = (AWTRenderer) foUserAgent.getRendererOverride();
         this.foUserAgent = foUserAgent;
+        this.configuredTargetResolution = this.foUserAgent.getTargetResolution();
         this.renderable = renderable;
         translator = new Translator();
 
@@ -551,23 +553,23 @@
     }
 
     private void scaleActionPerformed(ActionEvent e) {
-        try {
-            int index = scale.getSelectedIndex();
-            if (index == 0) {
-                setScale(previewPanel.getScaleToFitWindow() * 100);
-            } else if (index == 1) {
-                setScale(previewPanel.getScaleToFitWidth() * 100);
-            } else {
-                String item = (String)scale.getSelectedItem();
-                setScale(Double.parseDouble(item.substring(0, item.indexOf('%'))));
-            }
-        } catch (FOPException fopEx) {
-            fopEx.printStackTrace();
+        int index = scale.getSelectedIndex();
+        if (index == 0) {
+            setScaleToFitWindow();
+        } else if (index == 1) {
+            setScaleToFitWidth();
+        } else {
+            String item = (String)scale.getSelectedItem();
+            setScale(Double.parseDouble(item.substring(0, item.indexOf('%'))));
         }
     }
 
     /** Prints the document */
     public void startPrinterJob(boolean showDialog) {
+        //Restore originally configured target resolution
+        float saveResolution = foUserAgent.getTargetResolution();
+        foUserAgent.setTargetResolution(this.configuredTargetResolution);
+        
         PrinterJob pj = PrinterJob.getPrinterJob();
         pj.setPageable(renderer);
         if (!showDialog || pj.printDialog()) {
@@ -577,6 +579,8 @@
                 e.printStackTrace();
             }
         }
+        
+        foUserAgent.setTargetResolution(saveResolution);
     }
 
     /**

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/awt/viewer/PreviewPanel.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/awt/viewer/PreviewPanel.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/awt/viewer/PreviewPanel.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/awt/viewer/PreviewPanel.java Thu Jul 31 09:23:51 2008
@@ -23,6 +23,7 @@
 import java.awt.Dimension;
 import java.awt.GridLayout;
 import java.awt.Point;
+import java.awt.Toolkit;
 import java.awt.event.MouseEvent;
 import java.awt.event.MouseListener;
 import java.awt.event.MouseMotionListener;
@@ -36,11 +37,12 @@
 import javax.swing.SwingUtilities;
 import javax.swing.border.EmptyBorder;
 
+import org.apache.xmlgraphics.util.UnitConv;
+
 import org.apache.fop.apps.FOPException;
 import org.apache.fop.apps.FOUserAgent;
 import org.apache.fop.apps.MimeConstants;
 import org.apache.fop.area.PageViewport;
-
 import org.apache.fop.render.awt.AWTRenderer;
 
 
@@ -155,6 +157,8 @@
         this.renderable = renderable;
         this.renderer = renderer;
         this.foUserAgent = foUserAgent;
+        //Override target resolution for the computer screen
+        this.foUserAgent.setTargetResolution(Toolkit.getDefaultToolkit().getScreenResolution());
 
         gridPanel = new JPanel();
         gridPanel.setLayout(new GridLayout(0, 1)); // rows, cols
@@ -393,8 +397,10 @@
     public double getScaleToFit(double viewWidth, double viewHeight) throws FOPException {
         PageViewport pageViewport = renderer.getPageViewport(currentPage);
         Rectangle2D pageSize = pageViewport.getViewArea();
-        double widthScale = viewWidth / (pageSize.getWidth() / 1000f);
-        double heightScale = viewHeight / (pageSize.getHeight() / 1000f);
+        float screenResolution = Toolkit.getDefaultToolkit().getScreenResolution();
+        float screenFactor = screenResolution / UnitConv.IN2PT;
+        double widthScale = viewWidth / (pageSize.getWidth() / 1000f) / screenFactor;
+        double heightScale = viewHeight / (pageSize.getHeight() / 1000f) / screenFactor;
         return Math.min(displayMode == CONT_FACING ? widthScale / 2 : widthScale, heightScale);
     }
 

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/pdf/PDFGraphics2DAdapter.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/pdf/PDFGraphics2DAdapter.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/pdf/PDFGraphics2DAdapter.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/pdf/PDFGraphics2DAdapter.java Thu Jul 31 09:23:51 2008
@@ -115,7 +115,6 @@
 
         pdfInfo.currentStream.add(graphics.getString());
         renderer.restoreGraphicsState();
-        pdfInfo.pdfState.pop();
     }
 
     /** {@inheritDoc} */

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/BorderAttributesConverter.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/BorderAttributesConverter.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/BorderAttributesConverter.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/BorderAttributesConverter.java Thu Jul 31 09:23:51 2008
@@ -75,10 +75,12 @@
 
             // Add padding to corresponding space (space-before or space-after)
             // if side == START or END, do nothing
-            if (side == CommonBorderPaddingBackground.BEFORE) {
-                attributes.addIntegerValue(padding, RtfText.SPACE_BEFORE);
-            } else if (side == CommonBorderPaddingBackground.AFTER) {
-                attributes.addIntegerValue(padding, RtfText.SPACE_AFTER);
+            if (padding != 0) {
+                if (side == CommonBorderPaddingBackground.BEFORE) {
+                    attributes.addIntegerValue(padding, RtfText.SPACE_BEFORE);
+                } else if (side == CommonBorderPaddingBackground.AFTER) {
+                    attributes.addIntegerValue(padding, RtfText.SPACE_AFTER);
+                }
             }
         }
     }

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/FoUnitsConverter.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/FoUnitsConverter.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/FoUnitsConverter.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/FoUnitsConverter.java Thu Jul 31 09:23:51 2008
@@ -19,10 +19,9 @@
 
 package org.apache.fop.render.rtf;
 
-import java.util.Map;
 import java.util.HashMap;
+import java.util.Map;
 
-//FOP
 import org.apache.fop.apps.FOPException;
 import org.apache.fop.fo.properties.FixedLength;
 
@@ -143,4 +142,8 @@
         // RTF font size units are in half-points
         return (int)(result * 2.0);
     }
+
+    public float convertMptToTwips(int width) {
+        return width * POINT_TO_TWIPS / 1000;
+    }
 }

Modified: xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/PageAttributesConverter.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/PageAttributesConverter.java?rev=681410&r1=681409&r2=681410&view=diff
==============================================================================
--- xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/PageAttributesConverter.java (original)
+++ xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/render/rtf/PageAttributesConverter.java Thu Jul 31 09:23:51 2008
@@ -21,6 +21,7 @@
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.impl.SimpleLog;
+
 import org.apache.fop.datatypes.Length;
 import org.apache.fop.fo.Constants;
 import org.apache.fop.fo.expr.NumericOp;
@@ -58,6 +59,8 @@
 
             attrib.setTwips(RtfPage.PAGE_WIDTH, pagemaster.getPageWidth());
             attrib.setTwips(RtfPage.PAGE_HEIGHT, pagemaster.getPageHeight());
+            //Sets the document level property
+            attrib.set(RtfPage.ITAP, "0");
 
             Object widthRaw = attrib.getValue(RtfPage.PAGE_WIDTH);
             Object heightRaw = attrib.getValue(RtfPage.PAGE_HEIGHT);
@@ -102,7 +105,7 @@
             if (after != null) {
                 afterBottom = (Length) NumericOp.addition(pageBottom, after.getExtent());
             }
-            attrib.setTwips(RtfPage.FOOTERY, beforeTop);
+            attrib.setTwips(RtfPage.FOOTERY, afterBottom);
         } catch (Exception e) {
             log.error("Exception in convertPageAttributes: "
                 + e.getMessage() + "- page attributes ignored");



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