aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWilliam Victor Mote <vmote@apache.org>2002-11-29 23:18:59 +0000
committerWilliam Victor Mote <vmote@apache.org>2002-11-29 23:18:59 +0000
commit0438236a2c06687ddf27e63b2e020b3014dcc463 (patch)
tree1cda14fd91a2e97be7490b1994b88d2f5eda15bf
parentdbd6d2d0a69d1cab2b30efc4680177c350efc473 (diff)
downloadxmlgraphics-fop-0438236a2c06687ddf27e63b2e020b3014dcc463.tar.gz
xmlgraphics-fop-0438236a2c06687ddf27e63b2e020b3014dcc463.zip
white-space and line-ending fixes
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@195677 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r--src/codegen/Symbol.xml2
-rw-r--r--src/codegen/ZapfDingbats.xml2
-rw-r--r--src/codegen/charlist.xml32
-rw-r--r--src/codegen/enumgen.xsl32
-rw-r--r--src/codegen/font-file.xsl8
-rw-r--r--src/codegen/foproperties.xml396
-rw-r--r--src/codegen/properties.dtd66
-rw-r--r--src/codegen/properties.xsl184
-rw-r--r--src/codegen/propinc.xsl32
-rw-r--r--src/codegen/propmaker.xsl2
-rw-r--r--src/codegen/propmap.xsl2
-rw-r--r--src/codegen/t1font-file.xsl24
-rw-r--r--src/codegen/ttffontfile.xsl24
-rw-r--r--src/org/apache/fop/apps/Driver.java4
-rw-r--r--src/org/apache/fop/apps/PrintStarter.java4
-rw-r--r--src/org/apache/fop/area/Area.java6
-rw-r--r--src/org/apache/fop/area/AreaTree.java2
-rw-r--r--src/org/apache/fop/area/CachedRenderPagesModel.java2
-rw-r--r--src/org/apache/fop/area/PageViewport.java2
-rw-r--r--src/org/apache/fop/area/RegionReference.java6
-rw-r--r--src/org/apache/fop/area/Trait.java2
-rw-r--r--src/org/apache/fop/fo/AbstractCharIterator.java2
-rw-r--r--src/org/apache/fop/fo/OneCharIterator.java2
-rw-r--r--src/org/apache/fop/fo/flow/Inline.java10
-rw-r--r--src/org/apache/fop/fo/flow/ListBlock.java4
-rw-r--r--src/org/apache/fop/fo/flow/ListItem.java2
-rw-r--r--src/org/apache/fop/fo/flow/TableCell.java4
-rw-r--r--src/org/apache/fop/fo/flow/TableRow.java4
-rw-r--r--src/org/apache/fop/fo/pagination/LayoutMasterSet.java2
-rw-r--r--src/org/apache/fop/fonts/FontFileReader.java42
-rw-r--r--src/org/apache/fop/fonts/Glyphs.java20
-rw-r--r--src/org/apache/fop/fonts/TTFCmapEntry.java2
-rw-r--r--src/org/apache/fop/fonts/TTFDirTabEntry.java10
-rw-r--r--src/org/apache/fop/fonts/TTFFile.java76
-rw-r--r--src/org/apache/fop/fonts/TTFMtxEntry.java10
-rw-r--r--src/org/apache/fop/fonts/TTFSubSetFile.java10
-rw-r--r--src/org/apache/fop/fonts/apps/FontPostProcess.xsl30
-rw-r--r--src/org/apache/fop/fonts/apps/FontPostProcessSort.xsl16
-rw-r--r--src/org/apache/fop/image/AbstractFopImage.java4
-rw-r--r--src/org/apache/fop/image/ImageFactory.java4
-rw-r--r--src/org/apache/fop/layoutmgr/AbstractLayoutManager.java12
-rw-r--r--src/org/apache/fop/layoutmgr/BlockContainerLayoutManager.java2
-rw-r--r--src/org/apache/fop/layoutmgr/BlockLayoutManager.java2
-rw-r--r--src/org/apache/fop/layoutmgr/FlowLayoutManager.java4
-rw-r--r--src/org/apache/fop/layoutmgr/LineLayoutManager.java4
-rw-r--r--src/org/apache/fop/layoutmgr/PageLayoutManager.java4
-rw-r--r--src/org/apache/fop/layoutmgr/StaticContentLayoutManager.java8
-rw-r--r--src/org/apache/fop/layoutmgr/list/Item.java2
-rw-r--r--src/org/apache/fop/layoutmgr/list/ListBlockLayoutManager.java6
-rw-r--r--src/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java2
-rw-r--r--src/org/apache/fop/layoutmgr/table/Row.java8
-rw-r--r--src/org/apache/fop/layoutmgr/table/TableLayoutManager.java2
-rw-r--r--src/org/apache/fop/mif/MIFHandler.java2
-rw-r--r--src/org/apache/fop/pdf/DCTFilter.java2
-rw-r--r--src/org/apache/fop/pdf/PDFColorSpace.java4
-rw-r--r--src/org/apache/fop/pdf/PDFDocument.java18
-rw-r--r--src/org/apache/fop/pdf/PDFFunction.java10
-rw-r--r--src/org/apache/fop/pdf/PDFICCStream.java10
-rw-r--r--src/org/apache/fop/pdf/PDFOutline.java2
-rw-r--r--src/org/apache/fop/pdf/PDFPage.java4
-rw-r--r--src/org/apache/fop/pdf/PDFResourceContext.java2
-rw-r--r--src/org/apache/fop/render/pdf/FontSetup.java2
-rw-r--r--src/org/apache/fop/render/pdf/FopPDFImage.java4
-rw-r--r--src/org/apache/fop/render/pdf/PDFRenderer.java10
-rw-r--r--src/org/apache/fop/render/pdf/fonts/LazyFont.java56
-rw-r--r--src/org/apache/fop/rtf/renderer/RTFHandler.java4
-rw-r--r--src/org/apache/fop/svg/PDFANode.java2
-rw-r--r--src/org/apache/fop/svg/PDFDocumentGraphics2D.java4
-rw-r--r--src/org/apache/fop/svg/PDFGraphics2D.java12
-rw-r--r--src/org/apache/fop/viewer/GoToPageDialog.java2
-rw-r--r--src/org/apache/fop/viewer/PreviewDialog.java10
-rw-r--r--src/org/apache/fop/viewer/Translator.java12
72 files changed, 658 insertions, 658 deletions
diff --git a/src/codegen/Symbol.xml b/src/codegen/Symbol.xml
index 0776bee01..d3f52c363 100644
--- a/src/codegen/Symbol.xml
+++ b/src/codegen/Symbol.xml
@@ -2,7 +2,7 @@
<font-name>Symbol</font-name>
<class-name>Symbol</class-name>
<encoding>SymbolEncoding</encoding>
- <cap-height>1010</cap-height>
+ <cap-height>1010</cap-height>
<x-height>520</x-height>
<ascender>1010</ascender>
<descender>-293</descender>
diff --git a/src/codegen/ZapfDingbats.xml b/src/codegen/ZapfDingbats.xml
index 25b61871c..39fbb7141 100644
--- a/src/codegen/ZapfDingbats.xml
+++ b/src/codegen/ZapfDingbats.xml
@@ -2,7 +2,7 @@
<font-name>ZapfDingbats</font-name>
<class-name>ZapfDingbats</class-name>
<encoding>ZapfDingbatsEncoding</encoding>
- <cap-height>820</cap-height>
+ <cap-height>820</cap-height>
<x-height>426</x-height>
<ascender>820</ascender>
<descender>-143</descender>
diff --git a/src/codegen/charlist.xml b/src/codegen/charlist.xml
index 9c9854a7e..691d2f6d7 100644
--- a/src/codegen/charlist.xml
+++ b/src/codegen/charlist.xml
@@ -439,7 +439,7 @@
<map adobe-name="a189" win-ansi="0x00FC" unicode="0x27BC" unicodeName="WEDGE-TAILED RIGHTWARDS ARROW"/>
<map adobe-name="a190" win-ansi="0x00FD" unicode="0x27BD" unicodeName="HEAVY WEDGE-TAILED RIGHTWARDS ARROW"/>
<map adobe-name="a191" win-ansi="0x00FE" unicode="0x27BE" unicodeName="OPEN-OUTLINED RIGHTWARDS ARROW"/>
- <!-- the following mappings are used for the Symbol font
+ <!-- the following mappings are used for the Symbol font
TBD: remove doublettes -->
<map adobe-name="universal" win-ansi="0x22" unicode="0x2200"/>
<map adobe-name="existential" win-ansi="0x24" unicode="0x2203"/>
@@ -592,21 +592,21 @@
</font-mappings>
<!-- I couldn't find the following characters in the unicode tables -->
<!--
- <map adobe-name="center" win-ansi="-1" unicode=""/>
- <map adobe-name="dectab" win-ansi="-1" unicode=""/>
- <map adobe-name="down" win-ansi="-1" unicode=""/>
- <map adobe-name="format" win-ansi="-1" unicode=""/>
- <map adobe-name="graybox" win-ansi="-1" unicode=""/>
- <map adobe-name="indent" win-ansi="-1" unicode=""/>
- <map adobe-name="largebullet" win-ansi="-1" unicode=""/>
- <map adobe-name="left" win-ansi="-1" unicode=""/>
- <map adobe-name="ll" win-ansi="-1" unicode=""/>
- <map adobe-name="LL" win-ansi="-1" unicode=""/>
- <map adobe-name="merge" win-ansi="-1" unicode=""/>
- <map adobe-name="notegraphic" win-ansi="-1" unicode=""/>
- <map adobe-name="overscore" win-ansi="-1" unicode=""/>
- <map adobe-name="prescription" win-ansi="-1" unicode=""/>
- <map adobe-name="return" win-ansi="-1" unicode=""/>
+ <map adobe-name="center" win-ansi="-1" unicode=""/>
+ <map adobe-name="dectab" win-ansi="-1" unicode=""/>
+ <map adobe-name="down" win-ansi="-1" unicode=""/>
+ <map adobe-name="format" win-ansi="-1" unicode=""/>
+ <map adobe-name="graybox" win-ansi="-1" unicode=""/>
+ <map adobe-name="indent" win-ansi="-1" unicode=""/>
+ <map adobe-name="largebullet" win-ansi="-1" unicode=""/>
+ <map adobe-name="left" win-ansi="-1" unicode=""/>
+ <map adobe-name="ll" win-ansi="-1" unicode=""/>
+ <map adobe-name="LL" win-ansi="-1" unicode=""/>
+ <map adobe-name="merge" win-ansi="-1" unicode=""/>
+ <map adobe-name="notegraphic" win-ansi="-1" unicode=""/>
+ <map adobe-name="overscore" win-ansi="-1" unicode=""/>
+ <map adobe-name="prescription" win-ansi="-1" unicode=""/>
+ <map adobe-name="return" win-ansi="-1" unicode=""/>
<map adobe-name="square" win-ansi="-1" unicode=""/>
<map adobe-name="stop" win-ansi="-1" unicode=""/>
<map adobe-name="tab" win-ansi="-1" unicode=""/>
diff --git a/src/codegen/enumgen.xsl b/src/codegen/enumgen.xsl
index 6a538e590..a9898f551 100644
--- a/src/codegen/enumgen.xsl
+++ b/src/codegen/enumgen.xsl
@@ -25,10 +25,10 @@
</xsl:choose>
</xsl:variable>
<xsl:variable name="bEnum">
- <xsl:call-template name="hasEnum"/>
+ <xsl:call-template name="hasEnum"/>
</xsl:variable>
<xsl:variable name="bSubpropEnum">
- <xsl:call-template name="hasSubpropEnum"/>
+ <xsl:call-template name="hasSubpropEnum"/>
</xsl:variable>
<xsl:if test="$bEnum='true' or contains($bSubpropEnum, 'true')">
@@ -38,7 +38,7 @@ package org.apache.fop.fo.properties;
<!-- Handle enumeration values -->
public interface <xsl:value-of select="$classname"/>
<xsl:if test="use-generic and $bEnum='true'">
- extends <xsl:value-of select="use-generic"/>.Enums
+ extends <xsl:value-of select="use-generic"/>.Enums
</xsl:if>{
<xsl:for-each select="enumeration/value">
public final static int <xsl:value-of select="@const"/> = Constants.<xsl:value-of select="@const"/>;
@@ -69,18 +69,18 @@ package org.apache.fop.fo.properties;
</xsl:call-template>
</xsl:when>
<xsl:when test="$prop/compound/subproperty/use-generic">
- <!-- generate "interface <subprop> extends <gensubprop>.Enums" -->
- <xsl:for-each select="$prop/compound/subproperty[use-generic]">
- <xsl:variable name="bSpEnum">
- <xsl:call-template name="hasEnum">
- <xsl:with-param name="prop"
- select="key('genericref', use-generic)"/>
+ <!-- generate "interface <subprop> extends <gensubprop>.Enums" -->
+ <xsl:for-each select="$prop/compound/subproperty[use-generic]">
+ <xsl:variable name="bSpEnum">
+ <xsl:call-template name="hasEnum">
+ <xsl:with-param name="prop"
+ select="key('genericref', use-generic)"/>
</xsl:call-template>
- </xsl:variable>
- <xsl:if test="$bSpEnum='true'">
- public interface <xsl:value-of select="name"/> extends <xsl:value-of select="use-generic"/>.Enums { }
- </xsl:if>
- </xsl:for-each>
+ </xsl:variable>
+ <xsl:if test="$bSpEnum='true'">
+ public interface <xsl:value-of select="name"/> extends <xsl:value-of select="use-generic"/>.Enums { }
+ </xsl:if>
+ </xsl:for-each>
</xsl:when>
<xsl:otherwise>false</xsl:otherwise>
</xsl:choose>
@@ -100,7 +100,7 @@ package org.apache.fop.fo.properties;
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
- <!-- generate "interface <subprop> extends <genprop>.<subprop>" -->
+ <!-- generate "interface <subprop> extends <genprop>.<subprop>" -->
<xsl:for-each select="$prop/compound/subproperty[enumeration]">
<xsl:variable name="spname">
<xsl:call-template name="makeClassName">
@@ -110,7 +110,7 @@ package org.apache.fop.fo.properties;
public interface <xsl:value-of select="$spname"/> extends <xsl:value-of select="$generic_name"/>.Enums.<xsl:value-of select="$spname"/> {
}
</xsl:for-each>
-
+
<xsl:if test="$prop/use-generic">
<xsl:call-template name="inhspenums">
<xsl:with-param name="prop" select="key('genericref', $prop/use-generic)"/>
diff --git a/src/codegen/font-file.xsl b/src/codegen/font-file.xsl
index 7167c5b54..f1bb6b160 100644
--- a/src/codegen/font-file.xsl
+++ b/src/codegen/font-file.xsl
@@ -11,7 +11,7 @@
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="text"/>
-
+
<xsl:param name="encoding" select="/font-metrics/encoding"/>
<xsl:variable name="native-encoding" select="/font-metrics/encoding"/>
<xsl:variable name="glyphs" select="document('encodings.xml')/encoding-set/encoding[@id=$encoding]/glyph"/>
@@ -43,7 +43,7 @@ public class <xsl:value-of select="class-name"/> extends Font {
public String encoding() {
return encoding;
}
-
+
public String fontName() {
return fontName;
}
@@ -85,10 +85,10 @@ public class <xsl:value-of select="class-name"/> extends Font {
public char mapChar(char c) {
char d = mapping.mapChar(c);
- if(d != 0)
+ if(d != 0)
return d;
else
- return '#';
+ return '#';
}
}
diff --git a/src/codegen/foproperties.xml b/src/codegen/foproperties.xml
index e66297968..688862727 100644
--- a/src/codegen/foproperties.xml
+++ b/src/codegen/foproperties.xml
@@ -1,212 +1,212 @@
<?xml version="1.0" standalone="yes" ?>
<property-list family="FO">
<generic-property-list>
- <property type="generic">
- <name>generic-color</name>
- <class-name>GenericColor</class-name>
- <datatype>ColorType</datatype>
- <extfile href="colorkw.xml"/>
+ <property type="generic">
+ <name>generic-color</name>
+ <class-name>GenericColor</class-name>
+ <datatype>ColorType</datatype>
+ <extfile href="colorkw.xml"/>
<!--
- <datatype-conversion from-type="String" varname="strval">
- new ColorType(strval)</datatype-conversion>
+ <datatype-conversion from-type="String" varname="strval">
+ new ColorType(strval)</datatype-conversion>
-->
- </property>
- <property type="generic">
- <name>generic-boolean</name>
- <class-name>GenericBoolean</class-name>
- <datatype>Enum</datatype>
- <enumeration>
- <value const="TRUE">true</value>
- <value const="FALSE">false</value>
- </enumeration>
- </property>
- <property type="generic">
- <name>generic-keep</name>
- <class-name>GenericKeep</class-name>
- <datatype>Keep</datatype> <!-- CompoundDatatype -->
- <compound>
- <subproperty set-by-shorthand="true">
- <name>within-page</name>
- <datatype>Number</datatype>
- <default>auto</default>
- <enumeration>
- <value const="AUTO">auto</value>
- <value const="ALWAYS">always</value>
- </enumeration>
- </subproperty>
- <subproperty set-by-shorthand="true">
- <name>within-line</name>
- <datatype>Number</datatype>
- <default>auto</default>
- <enumeration>
- <value const="AUTO">auto</value>
- <value const="ALWAYS">always</value>
- </enumeration>
- </subproperty>
- <subproperty set-by-shorthand="true">
- <name>within-column</name>
- <datatype>Number</datatype>
- <default>auto</default>
- <enumeration>
- <value const="AUTO">auto</value>
- <value const="ALWAYS">always</value>
- </enumeration>
- </subproperty>
- </compound>
- </property>
- <property type="generic">
- <name>conditional-length-template</name>
- <class-name>GenericCondLength</class-name>
- <datatype>CondLength</datatype>
- <compound>
- <subproperty set-by-shorthand="true">
- <name>length</name>
- <datatype>Length</datatype>
- </subproperty>
- <subproperty>
- <name>conditionality</name>
- <datatype>Enum</datatype>
- <enumeration>
- <value const="DISCARD">discard</value>
- <value const="RETAIN">retain</value>
- </enumeration>
- </subproperty>
- </compound>
- </property>
- <property type="generic">
- <name>padding-template</name>
- <class-name>GenericCondPadding</class-name>
- <use-generic>GenericCondLength</use-generic>
- <inherited>false</inherited>
- <default subproperty="length">0pt</default>
- </property>
- <property type="generic">
- <name>padding-template</name>
- <class-name>GenericPadding</class-name>
- <datatype>Length</datatype>
- <inherited>false</inherited>
- <default>0pt</default>
+ </property>
+ <property type="generic">
+ <name>generic-boolean</name>
+ <class-name>GenericBoolean</class-name>
+ <datatype>Enum</datatype>
+ <enumeration>
+ <value const="TRUE">true</value>
+ <value const="FALSE">false</value>
+ </enumeration>
+ </property>
+ <property type="generic">
+ <name>generic-keep</name>
+ <class-name>GenericKeep</class-name>
+ <datatype>Keep</datatype> <!-- CompoundDatatype -->
+ <compound>
+ <subproperty set-by-shorthand="true">
+ <name>within-page</name>
+ <datatype>Number</datatype>
+ <default>auto</default>
+ <enumeration>
+ <value const="AUTO">auto</value>
+ <value const="ALWAYS">always</value>
+ </enumeration>
+ </subproperty>
+ <subproperty set-by-shorthand="true">
+ <name>within-line</name>
+ <datatype>Number</datatype>
+ <default>auto</default>
+ <enumeration>
+ <value const="AUTO">auto</value>
+ <value const="ALWAYS">always</value>
+ </enumeration>
+ </subproperty>
+ <subproperty set-by-shorthand="true">
+ <name>within-column</name>
+ <datatype>Number</datatype>
+ <default>auto</default>
+ <enumeration>
+ <value const="AUTO">auto</value>
+ <value const="ALWAYS">always</value>
+ </enumeration>
+ </subproperty>
+ </compound>
+ </property>
+ <property type="generic">
+ <name>conditional-length-template</name>
+ <class-name>GenericCondLength</class-name>
+ <datatype>CondLength</datatype>
+ <compound>
+ <subproperty set-by-shorthand="true">
+ <name>length</name>
+ <datatype>Length</datatype>
+ </subproperty>
+ <subproperty>
+ <name>conditionality</name>
+ <datatype>Enum</datatype>
+ <enumeration>
+ <value const="DISCARD">discard</value>
+ <value const="RETAIN">retain</value>
+ </enumeration>
+ </subproperty>
+ </compound>
+ </property>
+ <property type="generic">
+ <name>padding-template</name>
+ <class-name>GenericCondPadding</class-name>
+ <use-generic>GenericCondLength</use-generic>
+ <inherited>false</inherited>
+ <default subproperty="length">0pt</default>
+ </property>
+ <property type="generic">
+ <name>padding-template</name>
+ <class-name>GenericPadding</class-name>
+ <datatype>Length</datatype>
+ <inherited>false</inherited>
+ <default>0pt</default>
<shorthand>padding</shorthand>
- </property>
+ </property>
<!-- Before, After, Start, End border width props -->
<!-- CondLength, but adds keyword values both to the "shorthand" setting
- and to the length component. So we redefine the components here,
- rather than doing a "use-generic" on GenericCondLength.
+ and to the length component. So we redefine the components here,
+ rather than doing a "use-generic" on GenericCondLength.
-->
- <property type="generic">
- <name>border-cond-width-template</name>
- <class-name>GenericCondBorderWidth</class-name>
- <keyword-equiv match="thin">0.5pt</keyword-equiv>
- <keyword-equiv match="medium">1pt</keyword-equiv>
- <keyword-equiv match="thick">2pt</keyword-equiv>
- <inherited>false</inherited>
- <datatype>CondLength</datatype>
- <compound>
- <subproperty set-by-shorthand="true">
- <name>length</name>
- <datatype>Length</datatype>
- <keyword-equiv match="thin">0.5pt</keyword-equiv>
- <keyword-equiv match="medium">1pt</keyword-equiv>
- <keyword-equiv match="thick">2pt</keyword-equiv>
- <default>medium</default>
- </subproperty>
- <subproperty>
- <datatype>Enum</datatype>
- <name>conditionality</name>
- <enumeration>
- <value const="DISCARD">discard</value>
- <value const="RETAIN">retain</value>
- </enumeration>
- </subproperty>
- </compound>
- </property>
+ <property type="generic">
+ <name>border-cond-width-template</name>
+ <class-name>GenericCondBorderWidth</class-name>
+ <keyword-equiv match="thin">0.5pt</keyword-equiv>
+ <keyword-equiv match="medium">1pt</keyword-equiv>
+ <keyword-equiv match="thick">2pt</keyword-equiv>
+ <inherited>false</inherited>
+ <datatype>CondLength</datatype>
+ <compound>
+ <subproperty set-by-shorthand="true">
+ <name>length</name>
+ <datatype>Length</datatype>
+ <keyword-equiv match="thin">0.5pt</keyword-equiv>
+ <keyword-equiv match="medium">1pt</keyword-equiv>
+ <keyword-equiv match="thick">2pt</keyword-equiv>
+ <default>medium</default>
+ </subproperty>
+ <subproperty>
+ <datatype>Enum</datatype>
+ <name>conditionality</name>
+ <enumeration>
+ <value const="DISCARD">discard</value>
+ <value const="RETAIN">retain</value>
+ </enumeration>
+ </subproperty>
+ </compound>
+ </property>
<!-- Left, Right, Top, Bottom borderwidth props -->
- <property type="generic">
- <name>border-width-template</name>
- <class-name>GenericBorderWidth</class-name>
- <datatype>Length</datatype>
- <keyword-equiv match="thin">0.5pt</keyword-equiv>
- <keyword-equiv match="medium">1pt</keyword-equiv>
- <keyword-equiv match="thick">2pt</keyword-equiv>
- <inherited>false</inherited>
- <default>0pt</default>
- <shorthand>border-width</shorthand>
- </property>
- <property type="generic">
- <name>border-style-template</name>
- <class-name>GenericBorderStyle</class-name>
- <inherited>false</inherited>
- <datatype>Enum</datatype>
- <enumeration>
- <value const="NONE">none</value>
- <value const="HIDDEN">hidden</value>
- <value const="DOTTED">dotted</value>
- <value const="DASHED">dashed</value>
- <value const="SOLID">solid</value>
- <value const="DOUBLE">double</value>
- <value const="GROOVE">groove</value>
- <value const="RIDGE">ridge</value>
- <value const="INSET">inset</value>
- <value const="OUTSET">outset</value>
- </enumeration>
- <default>none</default>
- <shorthand>border-style</shorthand>
- </property>
- <property type="generic">
- <name>break-template</name>
- <class-name>GenericBreak</class-name>
- <inherited>false</inherited>
- <datatype>Enum</datatype>
- <enumeration>
- <value const="AUTO">auto</value>
- <value const="COLUMN">column</value>
- <value const="PAGE">page</value>
- <value const="EVEN_PAGE">even-page</value>
- <value const="ODD_PAGE">odd-page</value>
- </enumeration>
- <default>auto</default>
- </property>
- <property type="generic">
- <name>generic-space</name>
- <class-name>GenericSpace</class-name>
- <inherited>false</inherited>
- <datatype>Space</datatype>
- <compound>
- <subproperty set-by-shorthand="true">
- <name>minimum</name>
- <datatype>Length</datatype>
- <default>0pt</default>
- </subproperty>
- <subproperty set-by-shorthand="true">
- <name>optimum</name>
- <datatype>Length</datatype>
- <default>0pt</default>
- </subproperty>
- <subproperty set-by-shorthand="true">
- <name>maximum</name>
- <datatype>Length</datatype>
- <default>0pt</default>
- </subproperty>
- <subproperty>
- <name>precedence</name>
- <datatype>Number</datatype>
- <enumeration>
- <value const="FORCE">force</value>
- </enumeration>
- <default>0</default>
- </subproperty>
- <subproperty>
- <name>conditionality</name>
- <datatype>Enum</datatype>
- <enumeration>
- <value const="DISCARD">discard</value>
- <value const="RETAIN">retain</value>
- </enumeration>
- <default>discard</default>
- </subproperty>
- </compound>
- </property>
+ <property type="generic">
+ <name>border-width-template</name>
+ <class-name>GenericBorderWidth</class-name>
+ <datatype>Length</datatype>
+ <keyword-equiv match="thin">0.5pt</keyword-equiv>
+ <keyword-equiv match="medium">1pt</keyword-equiv>
+ <keyword-equiv match="thick">2pt</keyword-equiv>
+ <inherited>false</inherited>
+ <default>0pt</default>
+ <shorthand>border-width</shorthand>
+ </property>
+ <property type="generic">
+ <name>border-style-template</name>
+ <class-name>GenericBorderStyle</class-name>
+ <inherited>false</inherited>
+ <datatype>Enum</datatype>
+ <enumeration>
+ <value const="NONE">none</value>
+ <value const="HIDDEN">hidden</value>
+ <value const="DOTTED">dotted</value>
+ <value const="DASHED">dashed</value>
+ <value const="SOLID">solid</value>
+ <value const="DOUBLE">double</value>
+ <value const="GROOVE">groove</value>
+ <value const="RIDGE">ridge</value>
+ <value const="INSET">inset</value>
+ <value const="OUTSET">outset</value>
+ </enumeration>
+ <default>none</default>
+ <shorthand>border-style</shorthand>
+ </property>
+ <property type="generic">
+ <name>break-template</name>
+ <class-name>GenericBreak</class-name>
+ <inherited>false</inherited>
+ <datatype>Enum</datatype>
+ <enumeration>
+ <value const="AUTO">auto</value>
+ <value const="COLUMN">column</value>
+ <value const="PAGE">page</value>
+ <value const="EVEN_PAGE">even-page</value>
+ <value const="ODD_PAGE">odd-page</value>
+ </enumeration>
+ <default>auto</default>
+ </property>
+ <property type="generic">
+ <name>generic-space</name>
+ <class-name>GenericSpace</class-name>
+ <inherited>false</inherited>
+ <datatype>Space</datatype>
+ <compound>
+ <subproperty set-by-shorthand="true">
+ <name>minimum</name>
+ <datatype>Length</datatype>
+ <default>0pt</default>
+ </subproperty>
+ <subproperty set-by-shorthand="true">
+ <name>optimum</name>
+ <datatype>Length</datatype>
+ <default>0pt</default>
+ </subproperty>
+ <subproperty set-by-shorthand="true">
+ <name>maximum</name>
+ <datatype>Length</datatype>
+ <default>0pt</default>
+ </subproperty>
+ <subproperty>
+ <name>precedence</name>
+ <datatype>Number</datatype>
+ <enumeration>
+ <value const="FORCE">force</value>
+ </enumeration>
+ <default>0</default>
+ </subproperty>
+ <subproperty>
+ <name>conditionality</name>
+ <datatype>Enum</datatype>
+ <enumeration>
+ <value const="DISCARD">discard</value>
+ <value const="RETAIN">retain</value>
+ </enumeration>
+ <default>discard</default>
+ </subproperty>
+ </compound>
+ </property>
<!-- Common Accessibility Properties -->
diff --git a/src/codegen/properties.dtd b/src/codegen/properties.dtd
index a8a6a9d79..fdb1af6a2 100644
--- a/src/codegen/properties.dtd
+++ b/src/codegen/properties.dtd
@@ -3,15 +3,15 @@
DTD for foproperties.xml and svgproperties.xml
-->
-<!DOCTYPE property-list [
+<!DOCTYPE property-list [
<!ELEMENT property-list (generic-property-list?, element-property-list*) >
-
+
<!-- This defines properties which are generic: meaning they are valid for
any formatting object in the namespace associated with this properties
file.
-->
<!ELEMENT generic-property-list (property+) >
-
+
<!-- This defines properties which are specific to a particular element.
The elements are specified in one or more localname elements. This
will generate code which can be used to set up element-specific
@@ -19,12 +19,12 @@ DTD for foproperties.xml and svgproperties.xml
-->
<!ELEMENT element-property-list (localname+, property+) >
<!ELEMENT localname (#PCDATA) >
-
+
<!-- Define a single property in the current namespace -->
<!ELEMENT property (name, (use-generic | datatype), class-name?, inherited?,
- default?, enumeration?, datatype-conversion*, compound?,
- keyword-equiv*, percent-ok?, auto-ok?, derive?, corresponding? ) >
-
+ default?, enumeration?, datatype-conversion*, compound?,
+ keyword-equiv*, percent-ok?, auto-ok?, derive?, corresponding? ) >
+
<!-- If type is set to "ref", then this is not a new property definition,
but rather a reference to a property allready defined (should be in
another namespace). The "family" attribute then indicates in which
@@ -43,18 +43,18 @@ DTD for foproperties.xml and svgproperties.xml
<!-- Sub-elements of property. -->
<!-- This gives the name of the attribute used to specify values for this
property in input FO or SVG files. It MUST be specified.
--->
+-->
<!ELEMENT name (#PCDATA) >
-
+
<!-- This gives the class name of the Java class which will be created to
represent values for this property. It doesn't need to be specified if
it can be deduced from the "name". The rule is that the first letter
of the property name and any name following a "-" are capitalized and
the "-" characters are removed. If you want to force a name, use the
class-name sub-element.
--->
+-->
<!ELEMENT class-name (#PCDATA) >
-
+
<!-- This indicates that this property is based on a generic property
datatype. This may be one hand-coded, such as SVGLengthProperty, or it
may be one which is created by a generic property definition in the
@@ -69,10 +69,10 @@ DTD for foproperties.xml and svgproperties.xml
only used for the SVG properties, because they don't have a
rule-based relationship between the actual Property class name
and the name of the datatype stored by objects of that class.
--->
+-->
<!ELEMENT use-generic (#PCDATA) >
<!ATTLIST use-generic
- ispropclass (true | false ) "false"
+ ispropclass (true | false ) "false"
>
<!-- This indicates whether the property is inherited or not. Use the value
@@ -81,12 +81,12 @@ DTD for foproperties.xml and svgproperties.xml
value of the property is inherited. An example is line-height, which
if specified using relative units or a percent, is recalculated
relative to the FONTSIZE of the current FO.
--->
+-->
<!ELEMENT inherited (#PCDATA) >
<!ATTLIST inherited
- type (specified | computed) "computed"
+ type (specified | computed) "computed"
>
-
+
<!-- This gives the datatype of the stored property values. It shouldn't be
specified if the property has a use-generic element. The value of this
element should be the name of either a basic Java class (String,
@@ -94,7 +94,7 @@ DTD for foproperties.xml and svgproperties.xml
NOTE: the value "Enum" is special and indicates an enumerated
datatype, stored as a Java "int". There is an EnumProperty class, but
no corresponding Enum class.
--->
+-->
<!ELEMENT datatype (#PCDATA) >
<!-- This element is used to specify the allowable values for enumerated
@@ -103,13 +103,13 @@ DTD for foproperties.xml and svgproperties.xml
each value is used to generate a public static constant value in the
class which can be referenced in code to test the property value. It
must be a legal Java identifier. By convention, use all caps.
--->
+-->
<!ELEMENT enumeration (value+) >
<!ELEMENT value (#PCDATA) >
-<!ATTLIST value
- const CDATA #REQUIRED
+<!ATTLIST value
+ const CDATA #REQUIRED
>
-
+
<!-- This gives the default value for a property if it is not specified on
a given FO. (The spec calls this the "initial" value.)
@@ -133,13 +133,13 @@ DTD for foproperties.xml and svgproperties.xml
for a particular component. For example, the border-end-width property
is based on GenericCondBorderWidth and specifies a specific default
for the "conditionality" component.
--->
+-->
<!ELEMENT default (#PCDATA) >
<!ATTLIST default
- contextdep (true | false) "false"
- subproperty CDATA #IMPLIED
+ contextdep (true | false) "false"
+ subproperty CDATA #IMPLIED
>
-
+
<!-- The datatype-conversion element(s) specify how to handle property
values which can be specified in several ways. For example, the
@@ -184,7 +184,7 @@ DTD for foproperties.xml and svgproperties.xml
An example is space-before.
-->
<!ELEMENT compound (subproperty+) >
-
+
<!-- Describe one component of a compound property. Only the name and the
datatype should be specified. For example, in the space-before
property, the optimum component has the name optimum and the datatype
@@ -210,8 +210,8 @@ DTD for foproperties.xml and svgproperties.xml
-->
<!ELEMENT keyword-equiv (#PCDATA) >
<!ATTLIST keyword-equiv
- match CDATA #REQUIRED
- eval (true|false) "true"
+ match CDATA #REQUIRED
+ eval (true|false) "true"
>
<!-- This element if present indicates that percent specifications are
@@ -231,7 +231,7 @@ DTD for foproperties.xml and svgproperties.xml
-->
<!ELEMENT percent-ok (#PCDATA) >
<!ATTLIST percent-ok
- base (FONTSIZE | INH-FONTSIZE | CONTAINING-BOX) #IMPLIED
+ base (FONTSIZE | INH-FONTSIZE | CONTAINING-BOX) #IMPLIED
>
<!-- This element if present indicates that a value of "auto" for a Length
@@ -239,7 +239,7 @@ DTD for foproperties.xml and svgproperties.xml
is created which holds a Length object of type "AUTO".
-->
<!ELEMENT auto-ok EMPTY >
-
+
<!-- This element if present indicates that the value of the property may
be computed (derived) from other properties if it isn't specified. It
assumes that the property is an Enum datatype. (Currently only used
@@ -253,11 +253,11 @@ DTD for foproperties.xml and svgproperties.xml
-->
<!ELEMENT derive (if+) >
<!ATTLIST derive
- from CDATA #REQUIRED
+ from CDATA #REQUIRED
>
<!ELEMENT if (#PCDATA) >
<!ATTLIST if
- match CDATA #REQUIRED
+ match CDATA #REQUIRED
>
<!-- This element indicates that the value of the property is the same as
@@ -300,7 +300,7 @@ DTD for foproperties.xml and svgproperties.xml
<!ELEMENT propval (wmrel2abs | wmabs2rel | #PCDATA)+ >
<!ELEMENT wmrel2abs EMPTY>
-<!ATTLIST wmrel2abs
+<!ATTLIST wmrel2abs
dir (BEFORE | AFTER | START | END | BLOCKPROGDIM | INLINEPROGDIM)
#REQUIRED
>
diff --git a/src/codegen/properties.xsl b/src/codegen/properties.xsl
index fb7e65be0..35a5d7b66 100644
--- a/src/codegen/properties.xsl
+++ b/src/codegen/properties.xsl
@@ -21,14 +21,14 @@
public PercentBase getPercentBase(final FObj fo, final PropertyList propertyList) {
<xsl:choose>
<xsl:when test="@base">
- return new LengthBase(fo, propertyList, LengthBase.<xsl:value-of select="@base"/>);
+ return new LengthBase(fo, propertyList, LengthBase.<xsl:value-of select="@base"/>);
</xsl:when>
<xsl:otherwise>
- return (new LengthBase(fo, propertyList, LengthBase.CUSTOM_BASE ) {
- public int getBaseLength() {
- return (<xsl:value-of select="."/>);
+ return (new LengthBase(fo, propertyList, LengthBase.CUSTOM_BASE ) {
+ public int getBaseLength() {
+ return (<xsl:value-of select="."/>);
}
- });
+ });
</xsl:otherwise>
</xsl:choose>
}
@@ -48,7 +48,7 @@
<xsl:with-param name="specvals" select="concat(.,' ')"/>
</xsl:call-template>
</xsl:for-each>
- return super.checkEnumValues(value);
+ return super.checkEnumValues(value);
}
</xsl:template>
@@ -58,15 +58,15 @@
// Initialize hashtable of keywords
static HashMap s_htKeywords;
static {
- s_htKeywords = new HashMap(<xsl:value-of select="count(../keyword-equiv)"/>);
+ s_htKeywords = new HashMap(<xsl:value-of select="count(../keyword-equiv)"/>);
<xsl:for-each select="../keyword-equiv">
- s_htKeywords.put("<xsl:value-of select="@match"/>", "<xsl:value-of select="."/>");
+ s_htKeywords.put("<xsl:value-of select="@match"/>", "<xsl:value-of select="."/>");
</xsl:for-each>
}
protected String checkValueKeywords(String keyword) {
String value = (String)s_htKeywords.get(keyword);
if (value == null) {
- return super.checkValueKeywords(keyword);
+ return super.checkValueKeywords(keyword);
}
else return value;
}
@@ -81,7 +81,7 @@
<xsl:when test="../compound">
<xsl:call-template name="propclass">
<xsl:with-param name="prop"
- select="../compound/subproperty[@set-by-shorthand]"/>
+ select="../compound/subproperty[@set-by-shorthand]"/>
</xsl:call-template>
</xsl:when><xsl:otherwise>
<xsl:call-template name="propclass">
@@ -92,23 +92,23 @@
</xsl:variable>
// See if other value types are acceptable
protected Property convertPropertyDatatype(Property p,
- PropertyList propertyList, FObj fo) {
+ PropertyList propertyList, FObj fo) {
<xsl:for-each select="../datatype-conversion">
{
<xsl:variable name="dtc">
<xsl:choose>
- <xsl:when test="@vartype">
- <xsl:value-of select="@vartype"/>
- </xsl:when><xsl:otherwise>
- <xsl:value-of select="@from-type"/>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:variable>
- <xsl:value-of select="$dtc"/><xsl:text> </xsl:text> <xsl:value-of select="@varname"/> =
- p.get<xsl:value-of select="@from-type"/>();
- if (<xsl:value-of select="@varname"/> != null) {
- return new <xsl:value-of select="$propclass"/>(
- <xsl:value-of select='.'/>);
+ <xsl:when test="@vartype">
+ <xsl:value-of select="@vartype"/>
+ </xsl:when><xsl:otherwise>
+ <xsl:value-of select="@from-type"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:variable>
+ <xsl:value-of select="$dtc"/><xsl:text> </xsl:text> <xsl:value-of select="@varname"/> =
+ p.get<xsl:value-of select="@from-type"/>();
+ if (<xsl:value-of select="@varname"/> != null) {
+ return new <xsl:value-of select="$propclass"/>(
+ <xsl:value-of select='.'/>);
}
}
</xsl:for-each>
@@ -121,12 +121,12 @@
<!-- generate getDefaultForXXX for property components -->
<xsl:template match="default[@subproperty]" priority="2">
<xsl:variable name="spname">
- <xsl:call-template name="makeClassName">
- <xsl:with-param name="propstr" select="@subproperty"/>
- </xsl:call-template>
+ <xsl:call-template name="makeClassName">
+ <xsl:with-param name="propstr" select="@subproperty"/>
+ </xsl:call-template>
</xsl:variable>
protected String getDefaultFor<xsl:value-of select='$spname'/>() {
- return "<xsl:value-of select='.'/>";
+ return "<xsl:value-of select='.'/>";
}
</xsl:template>
@@ -138,12 +138,12 @@
public Property make(PropertyList propertyList) throws FOPException {
<xsl:choose><xsl:when test='@contextdep="true"'>
return make(propertyList, "<xsl:value-of select='.'/>", propertyList.getParentFObj());
- </xsl:when><xsl:otherwise>
+ </xsl:when><xsl:otherwise>
if (m_defaultProp == null) {
m_defaultProp=make(propertyList, "<xsl:value-of select='.'/>", propertyList.getParentFObj());
- }
+ }
return m_defaultProp;
- </xsl:otherwise></xsl:choose>
+ </xsl:otherwise></xsl:choose>
}
</xsl:template>
@@ -223,7 +223,7 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
</xsl:for-each>
<xsl:for-each select="compound/subproperty[enumeration]">
<xsl:variable name="spname">
- <xsl:call-template name="makeClassName">
+ <xsl:call-template name="makeClassName">
<xsl:with-param name="propstr" select="name"/>
</xsl:call-template>
</xsl:variable>
@@ -253,7 +253,7 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
</xsl:variable>
<xsl:for-each select="compound/subproperty">
<xsl:variable name="spname">
- <xsl:call-template name="makeClassName">
+ <xsl:call-template name="makeClassName">
<xsl:with-param name="propstr" select="name"/>
</xsl:call-template>
</xsl:variable>
@@ -271,36 +271,36 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
<xsl:choose>
<xsl:when test='*[local-name(.)!="name" and local-name(.)!="datatype" and local-name(.)!="use-generic" and local-name(.)!="default"]'>
static private class SP_<xsl:value-of select="$spname"/>Maker
- extends <xsl:value-of select="$sp_superclass"/>
+ extends <xsl:value-of select="$sp_superclass"/>
<xsl:if test="enumeration"> implements <xsl:value-of select="$enumclass"/>.<xsl:value-of select="$spname"/></xsl:if> {
- SP_<xsl:value-of select="$spname"/>Maker(String sPropName) {
- super(sPropName);
+ SP_<xsl:value-of select="$spname"/>Maker(String sPropName) {
+ super(sPropName);
}
<xsl:for-each select="enumeration/value">
protected final static EnumProperty s_prop<xsl:value-of select="@const"/> = new EnumProperty(<xsl:value-of select="@const"/>);
</xsl:for-each>
- <xsl:apply-templates select="percent-ok|auto-ok|keyword-equiv|datatype-conversion|enumeration"/>
+ <xsl:apply-templates select="percent-ok|auto-ok|keyword-equiv|datatype-conversion|enumeration"/>
}
final private static Property.Maker s_<xsl:value-of select="$spname"/>Maker =
- new SP_<xsl:value-of select="$spname"/>Maker(
- "<xsl:value-of select='../../name'/>.<xsl:value-of select='name'/>");
+ new SP_<xsl:value-of select="$spname"/>Maker(
+ "<xsl:value-of select='../../name'/>.<xsl:value-of select='name'/>");
</xsl:when>
<xsl:otherwise>
final private static Property.Maker s_<xsl:value-of select="$spname"/>Maker =
- new <xsl:value-of select="$sp_superclass"/>(
- "<xsl:value-of select='../../name'/>.<xsl:value-of select='name'/>");
- </xsl:otherwise>
+ new <xsl:value-of select="$sp_superclass"/>(
+ "<xsl:value-of select='../../name'/>.<xsl:value-of select='name'/>");
+ </xsl:otherwise>
</xsl:choose>
</xsl:for-each>
</xsl:if>
static public Property.Maker maker(String propName) {
- return new <xsl:value-of select="$classname"/>(propName);
+ return new <xsl:value-of select="$classname"/>(propName);
}
protected <xsl:value-of select="$classname"/>(String name) {
- super(name);
+ super(name);
<xsl:if test="compound">
m_shorthandMaker= getSubpropMaker("<xsl:value-of select='compound/subproperty[@set-by-shorthand="true"]/name'/>");
</xsl:if>
@@ -310,7 +310,7 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
Property.Maker m_shorthandMaker;
public Property checkEnumValues(String value) {
- return m_shorthandMaker.checkEnumValues(value);
+ return m_shorthandMaker.checkEnumValues(value);
}
protected boolean isCompoundMaker() {
@@ -320,23 +320,23 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
protected Property.Maker getSubpropMaker(String subprop) {
<xsl:for-each select="compound/subproperty">
<xsl:variable name="spname">
- <xsl:call-template name="makeClassName">
+ <xsl:call-template name="makeClassName">
<xsl:with-param name="propstr" select="name"/>
</xsl:call-template>
</xsl:variable>
- if (subprop.equals("<xsl:value-of select='name'/>"))
- return s_<xsl:value-of select="$spname"/>Maker;
+ if (subprop.equals("<xsl:value-of select='name'/>"))
+ return s_<xsl:value-of select="$spname"/>Maker;
</xsl:for-each>
- return super.getSubpropMaker(subprop);
+ return super.getSubpropMaker(subprop);
}
protected Property setSubprop(Property baseProp, String subpropName,
- Property subProp) {
+ Property subProp) {
<xsl:value-of select="datatype"/> val = baseProp.get<xsl:value-of select="datatype"/>();
- // Do some type checking???
- // Check if one of our subproperties???
- val.setComponent(subpropName, subProp, false);
- return baseProp;
+ // Do some type checking???
+ // Check if one of our subproperties???
+ val.setComponent(subpropName, subProp, false);
+ return baseProp;
}
public Property getSubpropValue(Property baseProp, String subpropName) {
@@ -355,71 +355,71 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
public Property make(PropertyList propertyList) throws FOPException {
if (m_defaultProp == null) {
m_defaultProp=makeCompound(propertyList, propertyList.getParentFObj());
- }
+ }
return m_defaultProp;
}
</xsl:otherwise>
</xsl:choose>
protected Property makeCompound(PropertyList pList, FObj fo) throws FOPException {
- <xsl:value-of select="datatype"/> p = new <xsl:value-of select="datatype"/>();
- Property subProp;
+ <xsl:value-of select="datatype"/> p = new <xsl:value-of select="datatype"/>();
+ Property subProp;
<xsl:for-each select="compound/subproperty/name">
<xsl:variable name="spname">
- <xsl:call-template name="makeClassName">
- <xsl:with-param name="propstr" select="."/>
- </xsl:call-template>
+ <xsl:call-template name="makeClassName">
+ <xsl:with-param name="propstr" select="."/>
+ </xsl:call-template>
</xsl:variable>
- // set default for subprop <xsl:value-of select="."/>
- subProp = getSubpropMaker("<xsl:value-of select='.'/>").make(pList,
- getDefaultFor<xsl:value-of select='$spname'/>(), fo);
- p.setComponent("<xsl:value-of select='.'/>", subProp, true);
+ // set default for subprop <xsl:value-of select="."/>
+ subProp = getSubpropMaker("<xsl:value-of select='.'/>").make(pList,
+ getDefaultFor<xsl:value-of select='$spname'/>(), fo);
+ p.setComponent("<xsl:value-of select='.'/>", subProp, true);
</xsl:for-each>
- return new <xsl:value-of select="$propclass"/>(p);
+ return new <xsl:value-of select="$propclass"/>(p);
}
<!-- generate a "getDefaultForXXX" for each subproperty XXX -->
<xsl:for-each select="compound/subproperty">
<xsl:variable name="spname">
- <xsl:call-template name="makeClassName">
- <xsl:with-param name="propstr" select="name"/>
- </xsl:call-template>
+ <xsl:call-template name="makeClassName">
+ <xsl:with-param name="propstr" select="name"/>
+ </xsl:call-template>
</xsl:variable>
protected String getDefaultFor<xsl:value-of select='$spname'/>() {
<xsl:choose><xsl:when test="default">
- return "<xsl:value-of select='default'/>";
+ return "<xsl:value-of select='default'/>";
</xsl:when><xsl:when test="use-generic and key('genericref', use-generic)/default">
- return "<xsl:value-of select='key(&apos;genericref&apos;, use-generic)/default'/>";
+ return "<xsl:value-of select='key(&apos;genericref&apos;, use-generic)/default'/>";
</xsl:when><xsl:otherwise>
- return "";
- </xsl:otherwise>
+ return "";
+ </xsl:otherwise>
</xsl:choose>
}
</xsl:for-each>
/** Set the appropriate components when the "base" property is set. */
public Property convertProperty(Property p, PropertyList pList,FObj fo)
- throws FOPException
+ throws FOPException
{
if (p instanceof <xsl:value-of select="$propclass"/>) return p;
- if (! (p instanceof EnumProperty)) {
- // delegate to the subprop maker to do conversions
- p = m_shorthandMaker.convertProperty(p,pList,fo);
+ if (! (p instanceof EnumProperty)) {
+ // delegate to the subprop maker to do conversions
+ p = m_shorthandMaker.convertProperty(p,pList,fo);
}
- if (p != null) {
- Property prop = makeCompound(pList, fo);
+ if (p != null) {
+ Property prop = makeCompound(pList, fo);
- <xsl:value-of select="datatype"/> pval = prop.get<xsl:value-of select="datatype"/>();
+ <xsl:value-of select="datatype"/> pval = prop.get<xsl:value-of select="datatype"/>();
<xsl:for-each select="compound/subproperty[@set-by-shorthand='true']">
- pval.setComponent("<xsl:value-of select='name'/>", p, false);
+ pval.setComponent("<xsl:value-of select='name'/>", p, false);
</xsl:for-each>
return prop;
}
- else return null;
+ else return null;
<!--
else {
- // throw some kind of exception!
- throw new FOPException("Can't convert value to <xsl:value-of select='$spdt'/> type");
+ // throw some kind of exception!
+ throw new FOPException("Can't convert value to <xsl:value-of select='$spdt'/> type");
}
-->
}
@@ -433,7 +433,7 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
<!-- the default implementation returns false -->
<xsl:if test='inherited/@type="specified"'>
public boolean inheritsSpecified() {
- return true;
+ return true;
}
</xsl:if>
@@ -476,7 +476,7 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
Property p=null;
<xsl:choose><xsl:when test="corresponding/propexpr">
<xsl:apply-templates select="corresponding/propval"/>
- // Make sure the property is set before calculating it!
+ // Make sure the property is set before calculating it!
if (propertyList.getExplicitOrShorthand(sbExpr.toString()) == null) return p;
sbExpr.setLength(0);
<xsl:apply-templates select="corresponding/propexpr"/>
@@ -497,7 +497,7 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
<xsl:choose><xsl:when test="propexpr">
<xsl:apply-templates select="propexpr"/>
subprop= getSubpropMaker("<xsl:value-of select='../name'/>").
- make(propertyList, sbExpr.toString(), parentFO);
+ make(propertyList, sbExpr.toString(), parentFO);
</xsl:when><xsl:otherwise>
<xsl:apply-templates select="propval"/>
subprop= propertyList.getExplicitOrShorthand(sbExpr.toString());
@@ -517,7 +517,7 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
Property p = null;
ListProperty listprop;
<xsl:for-each select="shorthand">
- <xsl:variable name="shprop" select="."/>
+ <xsl:variable name="shprop" select="."/>
if (p == null) {
listprop = (ListProperty)propertyList.getExplicit("<xsl:value-of select='$shprop'/>");
if (listprop != null) {
@@ -572,12 +572,12 @@ public class <xsl:value-of select="$classname"/> extends <xsl:value-of select="
<xsl:param name="dtlist"/>
<xsl:variable name="dt"><xsl:value-of select='$dtlist[1]'/></xsl:variable>
<xsl:for-each select="$dtlist">
- <xsl:if test=". != $dt">
- <xsl:message>
- <xsl:text>Conflict between subproperty datatypes: </xsl:text>
- <xsl:value-of select='.'/> != <xsl:value-of select='$dt'/>
- </xsl:message>
- </xsl:if>
+ <xsl:if test=". != $dt">
+ <xsl:message>
+ <xsl:text>Conflict between subproperty datatypes: </xsl:text>
+ <xsl:value-of select='.'/> != <xsl:value-of select='$dt'/>
+ </xsl:message>
+ </xsl:if>
</xsl:for-each>
<xsl:value-of select='$dt'/>
</xsl:template>
diff --git a/src/codegen/propinc.xsl b/src/codegen/propinc.xsl
index f83945b3d..e97d21cba 100644
--- a/src/codegen/propinc.xsl
+++ b/src/codegen/propinc.xsl
@@ -9,7 +9,7 @@
<xsl:variable name="lcletters" select="'abcdefghijklmnopqrstuvwxyz'" />
<xsl:variable name="ucletters" select="'ABCDEFGHIJKLMNOPQRSTUVWXYZ'" />
<xsl:value-of select="concat(translate(substring($str, 1, 1),
- $lcletters, $ucletters), substring($str, 2))"/>
+ $lcletters, $ucletters), substring($str, 2))"/>
</xsl:template>
<xsl:template name="makeClassName">
@@ -44,15 +44,15 @@
<xsl:when test="$prop/use-generic">
<!-- If no datatype child, then the prop must use the same datatype as
its template. -->
- <xsl:call-template name="propclass">
- <xsl:with-param name="prop"
- select="key('genericref', $prop/use-generic)"/>
+ <xsl:call-template name="propclass">
+ <xsl:with-param name="prop"
+ select="key('genericref', $prop/use-generic)"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise>
<!-- ERROR -->
<xsl:message terminate="yes">
- No datatype found for property: <xsl:value-of select="$prop/name"/>
+ No datatype found for property: <xsl:value-of select="$prop/name"/>
</xsl:message>
</xsl:otherwise>
</xsl:choose>
@@ -66,9 +66,9 @@
<xsl:when test="$prop/use-generic">
<!-- If no datatype child, then the prop must use the same datatype as
its template. -->
- <xsl:call-template name="hasEnum">
- <xsl:with-param name="prop"
- select="key('genericref', $prop/use-generic)"/>
+ <xsl:call-template name="hasEnum">
+ <xsl:with-param name="prop"
+ select="key('genericref', $prop/use-generic)"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise>false</xsl:otherwise>
@@ -83,18 +83,18 @@
<xsl:when test="$prop/use-generic">
<!-- If no datatype child, then the prop must use the same datatype as
its template. -->
- <xsl:call-template name="hasSubpropEnum">
- <xsl:with-param name="prop"
- select="key('genericref', $prop/use-generic)"/>
+ <xsl:call-template name="hasSubpropEnum">
+ <xsl:with-param name="prop"
+ select="key('genericref', $prop/use-generic)"/>
</xsl:call-template>
</xsl:when>
<xsl:when test="$prop/compound/subproperty/use-generic">
- <xsl:for-each select="$prop/compound/subproperty[use-generic]">
- <xsl:call-template name="hasEnum">
- <xsl:with-param name="prop"
- select="key('genericref', use-generic)"/>
+ <xsl:for-each select="$prop/compound/subproperty[use-generic]">
+ <xsl:call-template name="hasEnum">
+ <xsl:with-param name="prop"
+ select="key('genericref', use-generic)"/>
</xsl:call-template>
- </xsl:for-each>
+ </xsl:for-each>
</xsl:when>
<xsl:otherwise>false</xsl:otherwise>
</xsl:choose>
diff --git a/src/codegen/propmaker.xsl b/src/codegen/propmaker.xsl
index 549693b14..88eb04d04 100644
--- a/src/codegen/propmaker.xsl
+++ b/src/codegen/propmaker.xsl
@@ -21,7 +21,7 @@
<xsl:template match="*//attribute">
<property>
- <name><xsl:apply-templates/></name>
+ <name><xsl:apply-templates/></name>
<use-generic ispropclass="true">SVGStringProperty</use-generic>
</property>
</xsl:template>
diff --git a/src/codegen/propmap.xsl b/src/codegen/propmap.xsl
index 28074223e..ab8b1a7d4 100644
--- a/src/codegen/propmap.xsl
+++ b/src/codegen/propmap.xsl
@@ -98,7 +98,7 @@ public class <xsl:value-of select="@family"/>PropertyMapping {
</xsl:when>
<xsl:when test="not(@type)">
<xsl:call-template name="genmaker">
- <xsl:with-param name="htname" select="$htname"/>
+ <xsl:with-param name="htname" select="$htname"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise/>
diff --git a/src/codegen/t1font-file.xsl b/src/codegen/t1font-file.xsl
index 7f306fb07..af385d17d 100644
--- a/src/codegen/t1font-file.xsl
+++ b/src/codegen/t1font-file.xsl
@@ -1,4 +1,4 @@
-<!--
+<!--
This files writes the class files for the Adobe Type 1 fonts.
It uses the information in the font description files (Courier.xml, Helvetica.xml) to this
In these font description files each character is referenced by its adobe name:
@@ -44,7 +44,7 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
};
private final static String embedFileName = <xsl:value-of select="embedFile"/>;
private final static String embedResourceName = <xsl:value-of select="embedResource"/>;
- private static PDFT1Stream embeddedFont=null;
+ private static PDFT1Stream embeddedFont=null;
private final static int flags = <xsl:value-of select="flags"/>;
private final static int stemV = <xsl:value-of select="stemv"/>;
private final static int italicAngle = <xsl:value-of select="italicangle"/>;
@@ -77,7 +77,7 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
public PDFStream getFontFile(int i) {
InputStream instream=null;
-
+
// Get file first
if (embedFileName!=null)
try {
@@ -85,7 +85,7 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
} catch (Exception e) {
System.out.println("Failed to embed fontfile: "+embedFileName);
}
-
+
// Get resource
if (instream==null &amp;&amp; embedResourceName!=null)
try {
@@ -93,10 +93,10 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
} catch (Exception e) {
System.out.println("Failed to embed fontresource: "+embedResourceName);
}
-
+
if (instream==null)
return (PDFStream)null;
-
+
// Read fontdata
byte[] file = new byte[128000];
int fsize = 0;
@@ -104,29 +104,29 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
try {
int l = instream.read(file, 0, 128000);
fsize += l;
-
+
if (l==128000) {
// More to read - needs to extend
byte[] tmpbuf;
-
+
while (l &gt; 0) {
tmpbuf = new byte[file.length + 64000];
System.arraycopy(file, 0, tmpbuf, 0, file.length);
l=instream.read(tmpbuf, file.length, 64000);
fsize += l;
file = tmpbuf;
-
+
if (l &lt; 64000) // whole file read. No need to loop again
l=0;
}
}
-
+
embeddedFont=new PDFT1Stream(i, fsize);
embeddedFont.addFilter("flate");
embeddedFont.addFilter("ascii-85");
embeddedFont.setData(file, fsize);
instream.close();
- } catch (Exception e) {}
+ } catch (Exception e) {}
return (PDFStream) embeddedFont;
}
@@ -134,7 +134,7 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
public String encoding() {
return encoding;
}
-
+
public String fontName() {
return fontName;
}
diff --git a/src/codegen/ttffontfile.xsl b/src/codegen/ttffontfile.xsl
index 5842d43dc..1dd1b8017 100644
--- a/src/codegen/ttffontfile.xsl
+++ b/src/codegen/ttffontfile.xsl
@@ -1,4 +1,4 @@
-<!--
+<!--
This files writes the class files for the Adobe Type 1 fonts.
It uses the information in the font description files (Courier.xml, Helvetica.xml) to this
In these font description files each character is referenced by its adobe name:
@@ -45,7 +45,7 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
private final static String embedFileName = <xsl:value-of select="embedFile"/>;
private final static String embedResourceName = <xsl:value-of select="embedResource"/>;
- private static PDFTTFStream embeddedFont=null;
+ private static PDFTTFStream embeddedFont=null;
private final static int flags = <xsl:value-of select="flags"/>;
private final static int stemV = <xsl:value-of select="stemv"/>;
private final static int italicAngle = <xsl:value-of select="italicangle"/>;
@@ -77,7 +77,7 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
}
public PDFStream getFontFile(int i) {
InputStream instream=null;
-
+
// Get file first
if (embedFileName!=null)
try {
@@ -85,7 +85,7 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
} catch (Exception e) {
System.out.println("Failed to embed fontfile: "+embedFileName);
}
-
+
// Get resource
if (instream==null &amp;&amp; embedResourceName!=null)
try {
@@ -93,10 +93,10 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
} catch (Exception e) {
System.out.println("Failed to embed fontresource: "+embedResourceName);
}
-
+
if (instream==null)
return (PDFStream)null;
-
+
// Read fontdata
byte[] file = new byte[128000];
int fsize = 0;
@@ -104,36 +104,36 @@ public class <xsl:value-of select="class-name"/> extends Font implements FontDes
try {
int l = instream.read(file, 0, 128000);
fsize += l;
-
+
if (l==128000) {
// More to read - needs to extend
byte[] tmpbuf;
-
+
while (l &gt; 0) {
tmpbuf = new byte[file.length + 64000];
System.arraycopy(file, 0, tmpbuf, 0, file.length);
l=instream.read(tmpbuf, file.length, 64000);
fsize += l;
file = tmpbuf;
-
+
if (l &lt; 64000) // whole file read. No need to loop again
l=0;
}
}
-
+
embeddedFont=new PDFTTFStream(i, fsize);
embeddedFont.addFilter("flate");
embeddedFont.addFilter("ascii-85");
embeddedFont.setData(file, fsize);
instream.close();
- } catch (Exception e) {}
+ } catch (Exception e) {}
return (PDFStream) embeddedFont;
}
public String encoding() {
return encoding;
}
-
+
public String fontName() {
return fontName;
}
diff --git a/src/org/apache/fop/apps/Driver.java b/src/org/apache/fop/apps/Driver.java
index 010f63a7f..ad50a33d4 100644
--- a/src/org/apache/fop/apps/Driver.java
+++ b/src/org/apache/fop/apps/Driver.java
@@ -467,10 +467,10 @@ public class Driver implements LogEnabled {
} else if(_rendererType == RENDER_RTF) {
structHandler = new org.apache.fop.rtf.renderer.RTFHandler(_stream);
} else {
- if (_renderer == null) throw new Error("_renderer not set when using standard structHandler");
+ if (_renderer == null) throw new Error("_renderer not set when using standard structHandler");
structHandler = new LayoutHandler(_stream, _renderer, true);
}
-
+
structHandler.enableLogging(getLogger());
_treeBuilder.setUserAgent(getUserAgent());
diff --git a/src/org/apache/fop/apps/PrintStarter.java b/src/org/apache/fop/apps/PrintStarter.java
index a9be6d853..7af154127 100644
--- a/src/org/apache/fop/apps/PrintStarter.java
+++ b/src/org/apache/fop/apps/PrintStarter.java
@@ -11,9 +11,9 @@ package org.apache.fop.apps;
* originally contributed by
* Stanislav Gorkhover: stanislav.gorkhover@jcatalog.com
* jCatalog Software AG
- *
+ *
* Updated by Mark Lillywhite, mark-fop@inomial.com. Modified to
- * handle the print job better, added -Ddialog option, removed
+ * handle the print job better, added -Ddialog option, removed
* (apparently) redundant copies code, generally cleaned up, and
* added interfaces to the new Render API.
*/
diff --git a/src/org/apache/fop/area/Area.java b/src/org/apache/fop/area/Area.java
index 06b907e7d..00daf045f 100644
--- a/src/org/apache/fop/area/Area.java
+++ b/src/org/apache/fop/area/Area.java
@@ -55,19 +55,19 @@ public class Area implements Serializable {
* Rotated 90 degrees clockwise
*/
public static final int ORIENT_90 = 1;
-
+
/**
* Rotate 180 degrees
*/
public static final int ORIENT_180 = 2;
-
+
/**
* Rotated 270 degrees clockwise
*/
public static final int ORIENT_270 = 3;
// area class values
-
+
/**
* Normal class
*/
diff --git a/src/org/apache/fop/area/AreaTree.java b/src/org/apache/fop/area/AreaTree.java
index 58c2a8b33..afb5c72e1 100644
--- a/src/org/apache/fop/area/AreaTree.java
+++ b/src/org/apache/fop/area/AreaTree.java
@@ -488,7 +488,7 @@ public class AreaTree {
endDocExt.add(ext);
break;
}
- }
+ }
private void renderExtensions(List list) {
for (int count = 0; count < list.size(); count++) {
diff --git a/src/org/apache/fop/area/CachedRenderPagesModel.java b/src/org/apache/fop/area/CachedRenderPagesModel.java
index c5afd0f03..f18c66967 100644
--- a/src/org/apache/fop/area/CachedRenderPagesModel.java
+++ b/src/org/apache/fop/area/CachedRenderPagesModel.java
@@ -101,7 +101,7 @@ public class CachedRenderPagesModel extends AreaTree.RenderPagesModel {
String fname = "page" + page.toString() + ".ser";
tempstream = new ObjectOutputStream(new BufferedOutputStream(
new FileOutputStream(fname)));
- page.savePage(tempstream);
+ page.savePage(tempstream);
tempstream.close();
pageMap.put(page, fname);
} catch (Exception e) {
diff --git a/src/org/apache/fop/area/PageViewport.java b/src/org/apache/fop/area/PageViewport.java
index 0ce0239b9..74c330824 100644
--- a/src/org/apache/fop/area/PageViewport.java
+++ b/src/org/apache/fop/area/PageViewport.java
@@ -13,7 +13,7 @@ import java.io.ObjectInputStream;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
-import java.util.HashMap;
+import java.util.HashMap;
import java.util.Iterator;
/**
diff --git a/src/org/apache/fop/area/RegionReference.java b/src/org/apache/fop/area/RegionReference.java
index f94d12495..bebd5d30c 100644
--- a/src/org/apache/fop/area/RegionReference.java
+++ b/src/org/apache/fop/area/RegionReference.java
@@ -25,17 +25,17 @@ public class RegionReference extends Area implements Cloneable {
* The start region.
*/
public static final int START = 1;
-
+
/**
* The body region.
*/
public static final int BODY = 2;
-
+
/**
* The end region.
*/
public static final int END = 3;
-
+
/**
* The after region.
*/
diff --git a/src/org/apache/fop/area/Trait.java b/src/org/apache/fop/area/Trait.java
index 62b771a2b..7a688aeba 100644
--- a/src/org/apache/fop/area/Trait.java
+++ b/src/org/apache/fop/area/Trait.java
@@ -266,7 +266,7 @@ public class Trait implements Serializable {
/**
* Make a trait value.
*
- * @param oCode
+ * @param oCode
*/
public static Object makeTraitValue(Object oCode, String sTraitValue) {
// Get the code from the name
diff --git a/src/org/apache/fop/fo/AbstractCharIterator.java b/src/org/apache/fop/fo/AbstractCharIterator.java
index 69d342dfd..d3b193633 100644
--- a/src/org/apache/fop/fo/AbstractCharIterator.java
+++ b/src/org/apache/fop/fo/AbstractCharIterator.java
@@ -10,7 +10,7 @@ package org.apache.fop.fo;
// FOP
import org.apache.fop.apps.FOPException;
import java.util.NoSuchElementException;
-
+
public abstract class AbstractCharIterator implements CharIterator, Cloneable {
public abstract boolean hasNext();
diff --git a/src/org/apache/fop/fo/OneCharIterator.java b/src/org/apache/fop/fo/OneCharIterator.java
index aea844eaa..0f31d3f9f 100644
--- a/src/org/apache/fop/fo/OneCharIterator.java
+++ b/src/org/apache/fop/fo/OneCharIterator.java
@@ -10,7 +10,7 @@ package org.apache.fop.fo;
import java.util.Iterator;
import java.util.NoSuchElementException;
-
+
public class OneCharIterator extends AbstractCharIterator {
private boolean bFirst=true;
diff --git a/src/org/apache/fop/fo/flow/Inline.java b/src/org/apache/fop/fo/flow/Inline.java
index 2e6d2f90f..fda2fec03 100644
--- a/src/org/apache/fop/fo/flow/Inline.java
+++ b/src/org/apache/fop/fo/flow/Inline.java
@@ -40,23 +40,23 @@ public class Inline extends FObjMixed {
// Common Accessibility Properties
AccessibilityProps mAccProps = propMgr.getAccessibilityProps();
-
- // Common Aural Properties
+
+ // Common Aural Properties
AuralProps mAurProps = propMgr.getAuralProps();
// Common Border, Padding, and Background Properties
BorderAndPadding bap = propMgr.getBorderAndPadding();
BackgroundProps bProps = propMgr.getBackgroundProps();
-
+
// Common Font Properties
//this.fontState = propMgr.getFontState(area.getFontInfo());
// Common Margin Properties-Inline
MarginInlineProps mProps = propMgr.getMarginInlineProps();
-
+
// Common Relative Position Properties
RelativePositionProps mRelProps = propMgr.getRelativePositionProps();
-
+
// this.properties.get("alignment-adjust");
// this.properties.get("alignment-baseline");
// this.properties.get("baseline-shift");
diff --git a/src/org/apache/fop/fo/flow/ListBlock.java b/src/org/apache/fop/fo/flow/ListBlock.java
index 638fdcc4e..df2cdf865 100644
--- a/src/org/apache/fop/fo/flow/ListBlock.java
+++ b/src/org/apache/fop/fo/flow/ListBlock.java
@@ -41,13 +41,13 @@ public class ListBlock extends FObj {
public void addLayoutManager(List list) {
ListBlockLayoutManager blm = new ListBlockLayoutManager(this);
list.add(blm);
- }
+ }
public void setup() throws FOPException {
// Common Accessibility Properties
AccessibilityProps mAccProps = propMgr.getAccessibilityProps();
-
+
// Common Aural Properties
AuralProps mAurProps = propMgr.getAuralProps();
diff --git a/src/org/apache/fop/fo/flow/ListItem.java b/src/org/apache/fop/fo/flow/ListItem.java
index af5db5880..78c4b40a6 100644
--- a/src/org/apache/fop/fo/flow/ListItem.java
+++ b/src/org/apache/fop/fo/flow/ListItem.java
@@ -95,7 +95,7 @@ public class ListItem extends FObj {
} else {
// error
}
- }
+ }
public boolean generatesInlineAreas() {
return false;
diff --git a/src/org/apache/fop/fo/flow/TableCell.java b/src/org/apache/fop/fo/flow/TableCell.java
index 02a444ad2..8fbef7eba 100644
--- a/src/org/apache/fop/fo/flow/TableCell.java
+++ b/src/org/apache/fop/fo/flow/TableCell.java
@@ -75,7 +75,7 @@ public class TableCell extends FObj {
// boolean setup = false;
boolean bSepBorders = true;
-
+
/**
* Set to true if all content completely laid out.
*/
@@ -295,7 +295,7 @@ public class TableCell extends FObj {
this.borderHeight = (borderBefore + borderAfter) / 2;
}
}
-
+
protected boolean containsMarkers() {
return true;
}
diff --git a/src/org/apache/fop/fo/flow/TableRow.java b/src/org/apache/fop/fo/flow/TableRow.java
index 8ee0df005..430416f73 100644
--- a/src/org/apache/fop/fo/flow/TableRow.java
+++ b/src/org/apache/fop/fo/flow/TableRow.java
@@ -53,7 +53,7 @@ public class TableRow extends FObj {
// Common Accessibility Properties
AccessibilityProps mAccProps = propMgr.getAccessibilityProps();
-
+
// this.properties.get("block-progression-dimension");
// Common Aural Properties
@@ -67,7 +67,7 @@ public class TableRow extends FObj {
// Common Relative Position Properties
RelativePositionProps mRelProps = propMgr.getRelativePositionProps();
-
+
// this.properties.get("break-before");
// this.properties.get("break-after");
setupID();
diff --git a/src/org/apache/fop/fo/pagination/LayoutMasterSet.java b/src/org/apache/fop/fo/pagination/LayoutMasterSet.java
index c415b1e4e..8a072ea65 100644
--- a/src/org/apache/fop/fo/pagination/LayoutMasterSet.java
+++ b/src/org/apache/fop/fo/pagination/LayoutMasterSet.java
@@ -92,7 +92,7 @@ public class LayoutMasterSet extends FObj {
/**
* Get a page sequence master by name.
- * This is used by the page sequence to get a page master for
+ * This is used by the page sequence to get a page master for
* creating pages.
*/
public PageSequenceMaster getPageSequenceMaster(String masterName) {
diff --git a/src/org/apache/fop/fonts/FontFileReader.java b/src/org/apache/fop/fonts/FontFileReader.java
index 0790c83b3..ff205a79c 100644
--- a/src/org/apache/fop/fonts/FontFileReader.java
+++ b/src/org/apache/fop/fonts/FontFileReader.java
@@ -24,7 +24,7 @@ public class FontFileReader {
/**
* Initializes class and reads stream. Init does not close stream.
- *
+ *
* @param in InputStream to read from new array with size + inc
* @throws IOException In case of an I/O problem
*/
@@ -52,7 +52,7 @@ public class FontFileReader {
/**
* Constructor
- *
+ *
* @param fileName filename to read
* @throws IOException In case of an I/O problem
*/
@@ -69,7 +69,7 @@ public class FontFileReader {
/**
* Constructor
- *
+ *
* @param in InputStream to read from
* @throws IOException In case of an I/O problem
*/
@@ -80,7 +80,7 @@ public class FontFileReader {
/**
* Set current file position to offset
- *
+ *
* @param offset The new offset to set
* @throws IOException In case of an I/O problem
*/
@@ -94,7 +94,7 @@ public class FontFileReader {
/**
* Set current file position to offset
- *
+ *
* @param add The number of bytes to advance
* @throws IOException In case of an I/O problem
*/
@@ -104,7 +104,7 @@ public class FontFileReader {
/**
* Skip a given number of bytes.
- *
+ *
* @param add The number of bytes to advance
* @throws IOException In case of an I/O problem
*/
@@ -114,7 +114,7 @@ public class FontFileReader {
/**
* Returns current file position.
- *
+ *
* @return int The current position.
*/
public int getCurrentPos() {
@@ -123,7 +123,7 @@ public class FontFileReader {
/**
* Returns the size of the file.
- *
+ *
* @return int The filesize
*/
public int getFileSize() {
@@ -132,7 +132,7 @@ public class FontFileReader {
/**
* Read 1 byte.
- *
+ *
* @return One byte
* @throws IOException If EOF is reached
*/
@@ -147,7 +147,7 @@ public class FontFileReader {
/**
* Read 1 signed byte.
- *
+ *
* @return One byte
* @throws IOException If EOF is reached
*/
@@ -157,7 +157,7 @@ public class FontFileReader {
/**
* Read 1 unsigned byte.
- *
+ *
* @return One unsigned byte
* @throws IOException If EOF is reached
*/
@@ -173,7 +173,7 @@ public class FontFileReader {
/**
* Read 2 bytes signed.
- *
+ *
* @return One signed short
* @throws IOException If EOF is reached
*/
@@ -185,7 +185,7 @@ public class FontFileReader {
/**
* Read 2 bytes unsigned.
- *
+ *
* @return One unsigned short
* @throws IOException If EOF is reached
*/
@@ -196,7 +196,7 @@ public class FontFileReader {
/**
* Write a USHort at a given position.
- *
+ *
* @param pos The absolute position to write to
* @param val The value to write
* @throws IOException If EOF is reached
@@ -213,7 +213,7 @@ public class FontFileReader {
/**
* Read 2 bytes signed at position pos without changing current position.
- *
+ *
* @param pos The absolute position to read from
* @return One signed short
* @throws IOException If EOF is reached
@@ -228,7 +228,7 @@ public class FontFileReader {
/**
* Read 2 bytes unsigned at position pos without changing current position.
- *
+ *
* @param pos The absolute position to read from
* @return One unsigned short
* @throws IOException If EOF is reached
@@ -243,7 +243,7 @@ public class FontFileReader {
/**
* Read 4 bytes.
- *
+ *
* @return One signed integer
* @throws IOException If EOF is reached
*/
@@ -258,7 +258,7 @@ public class FontFileReader {
/**
* Read 4 bytes.
- *
+ *
* @return One unsigned integer
* @throws IOException If EOF is reached
*/
@@ -273,7 +273,7 @@ public class FontFileReader {
/**
* Read a NUL terminated ISO-8859-1 string.
- *
+ *
* @return A String
* @throws IOException If EOF is reached
*/
@@ -294,7 +294,7 @@ public class FontFileReader {
/**
* Read an ISO-8859-1 string of len bytes.
- *
+ *
* @param len The length of the string to read
* @return A String
* @throws IOException If EOF is reached
@@ -312,7 +312,7 @@ public class FontFileReader {
/**
* Return a copy of the internal array
- *
+ *
* @param offset The absolute offset to start reading from
* @param length The number of bytes to read
* @return An array of bytes
diff --git a/src/org/apache/fop/fonts/Glyphs.java b/src/org/apache/fop/fonts/Glyphs.java
index e5944031e..9f5da3b75 100644
--- a/src/org/apache/fop/fonts/Glyphs.java
+++ b/src/org/apache/fop/fonts/Glyphs.java
@@ -154,28 +154,28 @@ public class Glyphs {
'\u2014', // emdash
'~', '\u2022', // bullet
'\u0161', '\u203a', '\u0153', '\u2022', '\u017e', '\u0178', // 0xA0
- ' ', '\u00a1', '\u00a2', '\u00a3', '\u00a4', '\u00a5',
- '\u00a6', '\u00a7', '\u00a8', '\u00a9', '\u00aa', '\u00ab',
+ ' ', '\u00a1', '\u00a2', '\u00a3', '\u00a4', '\u00a5',
+ '\u00a6', '\u00a7', '\u00a8', '\u00a9', '\u00aa', '\u00ab',
'\u00ac', '\u00ad', '\u00ae', '\u00af', // 0xb0
'\u00b0', '\u00b1', '\u00b2', '\u00b3', '\u00b4',
'\u00b5', // This is hand-coded, the rest is assumption
'\u00b6', // and *might* not be correct...
- '\u00b7', '\u00b8', '\u00b9', '\u00ba', '\u00bb', '\u00bc', '\u00bd',
+ '\u00b7', '\u00b8', '\u00b9', '\u00ba', '\u00bb', '\u00bc', '\u00bd',
'\u00be', '\u00bf', // 0xc0
'\u00c0', '\u00c1', '\u00c2', '\u00c3', '\u00c4', '\u00c5', // Aring
'\u00c6', // AE
- '\u00c7', '\u00c8', '\u00c9', '\u00ca', '\u00cb', '\u00cc',
+ '\u00c7', '\u00c8', '\u00c9', '\u00ca', '\u00cb', '\u00cc',
'\u00cd', '\u00ce', '\u00cf', // 0xd0
- '\u00d0', '\u00d1', '\u00d2', '\u00d3', '\u00d4', '\u00d5',
+ '\u00d0', '\u00d1', '\u00d2', '\u00d3', '\u00d4', '\u00d5',
'\u00d6', '\u00d7', '\u00d8', // Oslash
- '\u00d9', '\u00da', '\u00db', '\u00dc', '\u00dd', '\u00de',
+ '\u00d9', '\u00da', '\u00db', '\u00dc', '\u00dd', '\u00de',
'\u00df', // 0xe0
'\u00e0', '\u00e1', '\u00e2', '\u00e3', '\u00e4', '\u00e5', // aring
'\u00e6', // ae
- '\u00e7', '\u00e8', '\u00e9', '\u00ea', '\u00eb', '\u00ec',
+ '\u00e7', '\u00e8', '\u00e9', '\u00ea', '\u00eb', '\u00ec',
'\u00ed', '\u00ee', '\u00ef', // 0xf0
- '\u00f0', '\u00f1', '\u00f2', '\u00f3', '\u00f4', '\u00f5',
- '\u00f6', '\u00f7', '\u00f8', '\u00f9', '\u00fa', '\u00fb',
+ '\u00f0', '\u00f1', '\u00f2', '\u00f3', '\u00f4', '\u00f5',
+ '\u00f6', '\u00f7', '\u00f8', '\u00f9', '\u00fa', '\u00fb',
'\u00fc', '\u00fd', '\u00fe', '\u00ff'
};
@@ -1233,7 +1233,7 @@ public class Glyphs {
"\uF730", "zerooldstyle",
"\u2070", "zerosuperior",
"\u03B6", "zeta"
-
+
};
/**
diff --git a/src/org/apache/fop/fonts/TTFCmapEntry.java b/src/org/apache/fop/fonts/TTFCmapEntry.java
index 409cd11b0..d3e900d9f 100644
--- a/src/org/apache/fop/fonts/TTFCmapEntry.java
+++ b/src/org/apache/fop/fonts/TTFCmapEntry.java
@@ -12,7 +12,7 @@ package org.apache.fop.fonts;
* the glyph indexes related to the range
*/
public class TTFCmapEntry {
-
+
private int unicodeStart;
private int unicodeEnd;
private int glyphStartIndex;
diff --git a/src/org/apache/fop/fonts/TTFDirTabEntry.java b/src/org/apache/fop/fonts/TTFDirTabEntry.java
index 6648832a7..2c6213336 100644
--- a/src/org/apache/fop/fonts/TTFDirTabEntry.java
+++ b/src/org/apache/fop/fonts/TTFDirTabEntry.java
@@ -10,7 +10,7 @@ package org.apache.fop.fonts;
import java.io.IOException;
class TTFDirTabEntry {
-
+
private byte[] tag = new byte[4];
private int checksum;
private long offset;
@@ -33,13 +33,13 @@ class TTFDirTabEntry {
//System.out.println(this.toString());
return new String(tag, "ISO-8859-1");
}
-
-
+
+
public String toString() {
- return "Read dir tab ["
+ return "Read dir tab ["
+ tag[0] + " " + tag[1] + " " + tag[2] + " " + tag[3] + "]"
+ " offset: " + offset
- + " length: " + length
+ + " length: " + length
+ " name: " + tag;
}
diff --git a/src/org/apache/fop/fonts/TTFFile.java b/src/org/apache/fop/fonts/TTFFile.java
index b6a723480..d950718a6 100644
--- a/src/org/apache/fop/fonts/TTFFile.java
+++ b/src/org/apache/fop/fonts/TTFFile.java
@@ -22,25 +22,25 @@ import org.apache.avalon.framework.logger.Logger;
* Typography site: http://www.microsoft.com/truetype/
*/
public class TTFFile extends AbstractLogEnabled {
-
+
static final byte NTABS = 24;
static final int NMACGLYPHS = 258;
static final int MAX_CHAR_CODE = 255;
static final int ENC_BUF_SIZE = 1024;
private String encoding = "WinAnsiEncoding"; // Default encoding
-
+
private short firstChar = 0;
private boolean isEmbeddable = true;
private boolean hasSerifs = true;
/**
* Table directory
*/
- protected Map dirTabs;
+ protected Map dirTabs;
private Map kerningTab; // for CIDs
private Map ansiKerningTab; // For winAnsiEncoding
private List cmaps;
- private List unicodeMapping;
+ private List unicodeMapping;
private int upem; // unitsPerEm from "head" table
private int nhmtx; // Number of horizontal metrics
@@ -55,7 +55,7 @@ public class TTFFile extends AbstractLogEnabled {
/**
* Contains glyph data
- */
+ */
protected TTFMtxEntry mtxTab[]; // Contains glyph data
private int[] mtxEncoded = null;
@@ -144,7 +144,7 @@ public class TTFFile extends AbstractLogEnabled {
int cmapEID = in.readTTFUShort();
long cmapOffset = in.readTTFULong();
- getLogger().debug("Platform ID: " + cmapPID
+ getLogger().debug("Platform ID: " + cmapPID
+ " Encoding: " + cmapEID);
if (cmapPID == 3 && cmapEID == 1) {
@@ -175,7 +175,7 @@ public class TTFFile extends AbstractLogEnabled {
getLogger().debug("searchRange : " + cmapSearchRange);
getLogger().debug("entrySelector: " + cmapEntrySelector);
getLogger().debug("rangeShift : " + cmapRangeShift);
-
+
int cmapEndCounts[] = new int[cmapSegCountX2 / 2];
int cmapStartCounts[] = new int[cmapSegCountX2 / 2];
@@ -208,10 +208,10 @@ public class TTFFile extends AbstractLogEnabled {
// and fill in the cmaps ArrayList
for (int i = 0; i < cmapStartCounts.length; i++) {
-
- getLogger().debug(i + ": " + cmapStartCounts[i]
+
+ getLogger().debug(i + ": " + cmapStartCounts[i]
+ " - " + cmapEndCounts[i]);
-
+
for (int j = cmapStartCounts[i]; j <= cmapEndCounts[i]; j++) {
// Update lastChar
@@ -224,9 +224,9 @@ public class TTFFile extends AbstractLogEnabled {
// the last character 65535 = .notdef
// may have a range offset
if (cmapRangeOffsets[i] != 0 && j != 65535) {
- int glyphOffset = glyphIdArrayOffset
- + ((cmapRangeOffsets[i] / 2)
- + (j - cmapStartCounts[i])
+ int glyphOffset = glyphIdArrayOffset
+ + ((cmapRangeOffsets[i] / 2)
+ + (j - cmapStartCounts[i])
+ (i)
- cmapSegCountX2 / 2) * 2;
in.seekSet(glyphOffset);
@@ -245,18 +245,18 @@ public class TTFFile extends AbstractLogEnabled {
Integer aIdx = (Integer)e.next();
ansiWidth[aIdx.intValue()] =
mtxTab[glyphIdx].getWx();
-
+
getLogger().debug("Added width "
- + mtxTab[glyphIdx].getWx()
- + " uni: " + j
+ + mtxTab[glyphIdx].getWx()
+ + " uni: " + j
+ " ansi: " + aIdx.intValue());
}
}
-
- getLogger().debug("Idx: "
- + glyphIdx
- + " Delta: " + cmapDeltas[i]
- + " Unicode: " + j
+
+ getLogger().debug("Idx: "
+ + glyphIdx
+ + " Delta: " + cmapDeltas[i]
+ + " Unicode: " + j
+ " name: " + mtxTab[glyphIdx].getName());
} else {
glyphIdx = (j + cmapDeltas[i]) & 0xffff;
@@ -287,14 +287,14 @@ public class TTFFile extends AbstractLogEnabled {
ansiWidth[aIdx.intValue()] = mtxTab[glyphIdx].getWx();
}
}
-
+
//getLogger().debug("IIdx: " +
// mtxPtr +
// " Delta: " + cmap_deltas[i] +
// " Unicode: " + j +
// " name: " +
// mtxTab[(j+cmap_deltas[i]) & 0xffff].name);
-
+
}
if (glyphIdx < mtxTab.length) {
if (mtxTab[glyphIdx].getUnicodeIndex().size() < 2) {
@@ -326,10 +326,10 @@ public class TTFFile extends AbstractLogEnabled {
getLogger().info("Max: " + max);
}
-
+
/**
* Reads the font using a FontFileReader.
- *
+ *
* @param in The FontFileReader to use
* @throws IOException In case of an I/O problem
*/
@@ -566,7 +566,7 @@ public class TTFFile extends AbstractLogEnabled {
}
/**
- * Returns the index of the last character, but this is for WinAnsiEncoding
+ * Returns the index of the last character, but this is for WinAnsiEncoding
* only, so the last char is < 256.
* @return short Index of the last character (<256)
*/
@@ -724,8 +724,8 @@ public class TTFFile extends AbstractLogEnabled {
for (int i = 0; i < nhmtx; i++) {
mtxTab[i].setWx(in.readTTFUShort());
mtxTab[i].setLsb(in.readTTFUShort());
-
- getLogger().debug(" width[" + i + "] = "
+
+ getLogger().debug(" width[" + i + "] = "
+ convertTTFUnit2PDFUnit(mtxTab[i].getWx()) + ";");
}
@@ -783,7 +783,7 @@ public class TTFFile extends AbstractLogEnabled {
}
// firstChar=minIndex;
psGlyphsBuffer = new String[numGlyphStrings];
- getLogger().debug("Reading " + numGlyphStrings
+ getLogger().debug("Reading " + numGlyphStrings
+ " glyphnames" + ", was n num glyphs=" + l);
for (i = 0; i < psGlyphsBuffer.length; i++) {
psGlyphsBuffer[i] = in.readTTFString(in.readTTFUByte());
@@ -795,7 +795,7 @@ public class TTFFile extends AbstractLogEnabled {
} else {
k = mtxTab[i].getIndex() - NMACGLYPHS;
- getLogger().debug(k + " i=" + i + " mtx=" + mtxTab.length
+ getLogger().debug(k + " i=" + i + " mtx=" + mtxTab.length
+ " ps=" + psGlyphsBuffer.length);
mtxTab[i].setName(psGlyphsBuffer[k]);
@@ -877,9 +877,9 @@ public class TTFFile extends AbstractLogEnabled {
in.seekSet(n + mtxTab[i].getOffset());
in.skip(2);
final int[] bbox = {
- in.readTTFShort(),
- in.readTTFShort(),
- in.readTTFShort(),
+ in.readTTFShort(),
+ in.readTTFShort(),
+ in.readTTFShort(),
in.readTTFShort()};
mtxTab[i].setBoundingBox(bbox);
} else {
@@ -924,7 +924,7 @@ public class TTFFile extends AbstractLogEnabled {
// if (k==1 || k==2 || k==0 || k==4 || k==6) {
in.seekSet(j + in.readTTFUShort());
String txt = in.readTTFString(l);
- // getLogger().debug(platform_id + " " + encoding_id
+ // getLogger().debug(platform_id + " " + encoding_id
// + " " + k + " " + txt);
switch (k) {
case 0:
@@ -943,9 +943,9 @@ public class TTFFile extends AbstractLogEnabled {
fontName = txt;
break;
}
- if (!notice.equals("")
+ if (!notice.equals("")
&& !fullName.equals("")
- && !fontName.equals("")
+ && !fontName.equals("")
&& !familyName.equals("")
&& !subFamilyName.equals("")) {
break;
@@ -1220,10 +1220,10 @@ public class TTFFile extends AbstractLogEnabled {
* Key-value helper class
*/
class UnicodeMapping {
-
+
private int uIdx;
private int gIdx;
-
+
UnicodeMapping(int gIdx, int uIdx) {
this.uIdx = uIdx;
this.gIdx = gIdx;
diff --git a/src/org/apache/fop/fonts/TTFMtxEntry.java b/src/org/apache/fop/fonts/TTFMtxEntry.java
index 1aa11d2d2..747be55f8 100644
--- a/src/org/apache/fop/fonts/TTFMtxEntry.java
+++ b/src/org/apache/fop/fonts/TTFMtxEntry.java
@@ -10,7 +10,7 @@ package org.apache.fop.fonts;
import java.util.List;
class TTFMtxEntry {
-
+
private int wx;
private int lsb;
private String name = "";
@@ -22,10 +22,10 @@ class TTFMtxEntry {
public String toString(TTFFile t) {
return "Glyph " + name + " index: " + index + " bbox [ "
- + t.convertTTFUnit2PDFUnit(boundingBox[0]) + " "
- + t.convertTTFUnit2PDFUnit(boundingBox[1]) + " "
- + t.convertTTFUnit2PDFUnit(boundingBox[2]) + " "
- + t.convertTTFUnit2PDFUnit(boundingBox[3]) + "] wx: "
+ + t.convertTTFUnit2PDFUnit(boundingBox[0]) + " "
+ + t.convertTTFUnit2PDFUnit(boundingBox[1]) + " "
+ + t.convertTTFUnit2PDFUnit(boundingBox[2]) + " "
+ + t.convertTTFUnit2PDFUnit(boundingBox[3]) + "] wx: "
+ t.convertTTFUnit2PDFUnit(wx);
}
diff --git a/src/org/apache/fop/fonts/TTFSubSetFile.java b/src/org/apache/fop/fonts/TTFSubSetFile.java
index b790f4426..7a1a98e95 100644
--- a/src/org/apache/fop/fonts/TTFSubSetFile.java
+++ b/src/org/apache/fop/fonts/TTFSubSetFile.java
@@ -21,7 +21,7 @@ import java.util.List;
* Typography site: http://www.microsoft.com/truetype/
*/
public class TTFSubSetFile extends TTFFile {
-
+
private byte[] output = null;
private int realSize = 0;
private int currentPos = 0;
@@ -390,7 +390,7 @@ public class TTFSubSetFile extends TTFFile {
if (entry != null) {
pad4();
//int offset = (int)entry.offset;
- Iterator e = glyphs.keySet().iterator();
+ Iterator e = glyphs.keySet().iterator();
while (e.hasNext()) {
Integer origIndex = (Integer)e.next();
Integer subsetIndex = (Integer)glyphs.get(origIndex);
@@ -531,7 +531,7 @@ public class TTFSubSetFile extends TTFFile {
// Inefficient to iterate through all glyphs
newComposites = new java.util.HashMap();
- Iterator e = glyphs.keySet().iterator();
+ Iterator e = glyphs.keySet().iterator();
while (e.hasNext()) {
Integer origIndex = (Integer)e.next();
@@ -583,10 +583,10 @@ public class TTFSubSetFile extends TTFFile {
/**
* Returns a subset of the original font.
- *
+ *
* @param in FontFileReader to read from
* @param name Name to be checked for in the font file
- * @param glyphs Map of glyphs (glyphs has old index as (Integer) key and
+ * @param glyphs Map of glyphs (glyphs has old index as (Integer) key and
* new index as (Integer) value)
* @return A subset of the original font
* @throws IOException in case of an I/O problem
diff --git a/src/org/apache/fop/fonts/apps/FontPostProcess.xsl b/src/org/apache/fop/fonts/apps/FontPostProcess.xsl
index 120fd36a3..624df8092 100644
--- a/src/org/apache/fop/fonts/apps/FontPostProcess.xsl
+++ b/src/org/apache/fop/fonts/apps/FontPostProcess.xsl
@@ -4,24 +4,24 @@
<xsl:output method="xml"/>
<xsl:template match="@*|node()">
- <xsl:copy>
- <xsl:apply-templates select="@*|node()"/>
- </xsl:copy>
+ <xsl:copy>
+ <xsl:apply-templates select="@*|node()"/>
+ </xsl:copy>
</xsl:template>
<xsl:template match="widths">
- <xsl:element name="widths">
- <xsl:for-each select="char">
- <xsl:variable name="char-num" select="@ansichar"/>
- <xsl:variable name="char-name" select="document('file:charlist.xml')/font-mappings/map[@win-ansi=$char-num]/@adobe-name"/>
- <xsl:if test="$char-name!=''">
- <xsl:element name="char">
- <xsl:attribute name="name"><xsl:value-of select="$char-name"/></xsl:attribute>
- <xsl:attribute name="width"><xsl:value-of select="@width"/></xsl:attribute>
- </xsl:element>
- </xsl:if>
- </xsl:for-each>
- </xsl:element>
+ <xsl:element name="widths">
+ <xsl:for-each select="char">
+ <xsl:variable name="char-num" select="@ansichar"/>
+ <xsl:variable name="char-name" select="document('file:charlist.xml')/font-mappings/map[@win-ansi=$char-num]/@adobe-name"/>
+ <xsl:if test="$char-name!=''">
+ <xsl:element name="char">
+ <xsl:attribute name="name"><xsl:value-of select="$char-name"/></xsl:attribute>
+ <xsl:attribute name="width"><xsl:value-of select="@width"/></xsl:attribute>
+ </xsl:element>
+ </xsl:if>
+ </xsl:for-each>
+ </xsl:element>
</xsl:template>
</xsl:stylesheet>
diff --git a/src/org/apache/fop/fonts/apps/FontPostProcessSort.xsl b/src/org/apache/fop/fonts/apps/FontPostProcessSort.xsl
index 63ca43408..989f66566 100644
--- a/src/org/apache/fop/fonts/apps/FontPostProcessSort.xsl
+++ b/src/org/apache/fop/fonts/apps/FontPostProcessSort.xsl
@@ -3,17 +3,17 @@
<xsl:output method="xml"/>
<xsl:template match="@*|node()">
- <xsl:copy>
- <xsl:apply-templates select="@*|node()"/>
- </xsl:copy>
+ <xsl:copy>
+ <xsl:apply-templates select="@*|node()"/>
+ </xsl:copy>
</xsl:template>
<xsl:template match="widths">
- <xsl:copy>
- <xsl:apply-templates select="char">
- <xsl:sort select="@name" case-order="upper-first"/>
- </xsl:apply-templates>
- </xsl:copy>
+ <xsl:copy>
+ <xsl:apply-templates select="char">
+ <xsl:sort select="@name" case-order="upper-first"/>
+ </xsl:apply-templates>
+ </xsl:copy>
</xsl:template>
diff --git a/src/org/apache/fop/image/AbstractFopImage.java b/src/org/apache/fop/image/AbstractFopImage.java
index e4cc9bbdb..9646a18d5 100644
--- a/src/org/apache/fop/image/AbstractFopImage.java
+++ b/src/org/apache/fop/image/AbstractFopImage.java
@@ -158,7 +158,7 @@ public abstract class AbstractFopImage implements FopImage {
* Load a bitmap array of the image.
* If the renderer requires a bitmap image then the
* implementations should override this to load the bitmap.
- *
+ *
* @param ua the user agent
* @return true if the loading was successful
*/
@@ -169,7 +169,7 @@ public abstract class AbstractFopImage implements FopImage {
/**
* Load the original image data.
* In some cases the original data can be used by the renderer.
- * This should load the data and any other associated information.
+ * This should load the data and any other associated information.
*
* @param ua the user agent
* @return true if the loading was successful
diff --git a/src/org/apache/fop/image/ImageFactory.java b/src/org/apache/fop/image/ImageFactory.java
index e0e2ef866..3ea3a8bc5 100644
--- a/src/org/apache/fop/image/ImageFactory.java
+++ b/src/org/apache/fop/image/ImageFactory.java
@@ -100,7 +100,7 @@ public class ImageFactory {
* the image.
* The image should then be put into the weak cache.
*
- * @param url the url for the image
+ * @param url the url for the image
* @param context the user agent context
*/
public void releaseImage(String url, FOUserAgent context) {
@@ -112,7 +112,7 @@ public class ImageFactory {
* @param href image URL as a String
* @return a new FopImage object
*
- * @param href the url for the image
+ * @param href the url for the image
* @param baseURL the base url
* @param ua the user agent context
* @return the fop image instance
diff --git a/src/org/apache/fop/layoutmgr/AbstractLayoutManager.java b/src/org/apache/fop/layoutmgr/AbstractLayoutManager.java
index 9d649b266..4099deff6 100644
--- a/src/org/apache/fop/layoutmgr/AbstractLayoutManager.java
+++ b/src/org/apache/fop/layoutmgr/AbstractLayoutManager.java
@@ -141,7 +141,7 @@ public abstract class AbstractLayoutManager implements LayoutManager {
protected boolean hasMoreLM(LayoutManager prevLM) {
// prevLM should = curChildLM
if (prevLM != curChildLM) {
- //log.debug("AbstractLayoutManager.peekNextLM: " +
+ //log.debug("AbstractLayoutManager.peekNextLM: " +
// "passed LM is not current child LM!");
return false;
}
@@ -158,7 +158,7 @@ public abstract class AbstractLayoutManager implements LayoutManager {
* If pos is null, then back up to the first child LM.
*/
protected void reset(Position pos) {
- //if (lm == null) return;
+ //if (lm == null) return;
LayoutManager lm = (pos != null) ? pos.getLM() : null;
if (curChildLM != lm) {
// ASSERT curChildLM == (LayoutManager)childLMiter.previous()
@@ -191,7 +191,7 @@ public abstract class AbstractLayoutManager implements LayoutManager {
* This method provides a hook for a LayoutManager to intialize traits
* for the areas it will create, based on Properties set on its FO.
*/
- public void init() {
+ public void init() {
if (fobj != null && bInited == false) {
initProperties(fobj.getPropertyManager());
bInited = true;
@@ -205,7 +205,7 @@ public abstract class AbstractLayoutManager implements LayoutManager {
protected void initProperties(PropertyManager pm) {
//log.debug("AbstractLayoutManager.initProperties");
}
-
+
/**
* Tell whether this LayoutManager has handled all of its content.
@@ -369,7 +369,7 @@ public abstract class AbstractLayoutManager implements LayoutManager {
/**
* Add background to an area.
- * Layout managers that create areas with a background can use this to
+ * Layout managers that create areas with a background can use this to
* add the background to the area.
*/
public static void addBackground(Area curBlock, BackgroundProps backProps) {
@@ -386,7 +386,7 @@ public abstract class AbstractLayoutManager implements LayoutManager {
back.vertical = backProps.backPosVertical.mvalue();
}
}
-
+
if(back.color != null || back.url != null) {
curBlock.addTrait(Trait.BACKGROUND, back);
}
diff --git a/src/org/apache/fop/layoutmgr/BlockContainerLayoutManager.java b/src/org/apache/fop/layoutmgr/BlockContainerLayoutManager.java
index 4ccfea572..3446179da 100644
--- a/src/org/apache/fop/layoutmgr/BlockContainerLayoutManager.java
+++ b/src/org/apache/fop/layoutmgr/BlockContainerLayoutManager.java
@@ -168,7 +168,7 @@ public class BlockContainerLayoutManager extends BlockStackingLayoutManager {
while ((curLM = getChildLM()) != null) {
// Make break positions and return blocks!
- // Set up a LayoutContext
+ // Set up a LayoutContext
BreakPoss bp;
LayoutContext childLC = new LayoutContext(0);
diff --git a/src/org/apache/fop/layoutmgr/BlockLayoutManager.java b/src/org/apache/fop/layoutmgr/BlockLayoutManager.java
index 63e56c613..7692c8c3b 100644
--- a/src/org/apache/fop/layoutmgr/BlockLayoutManager.java
+++ b/src/org/apache/fop/layoutmgr/BlockLayoutManager.java
@@ -117,7 +117,7 @@ public class BlockLayoutManager extends BlockStackingLayoutManager {
borderProps = pm.getBorderAndPadding();
backgroundProps = pm.getBackgroundProps();
}
-
+
public BreakPoss getNextBreakPoss(LayoutContext context) {
LayoutManager curLM; // currently active LM
diff --git a/src/org/apache/fop/layoutmgr/FlowLayoutManager.java b/src/org/apache/fop/layoutmgr/FlowLayoutManager.java
index 58e57834d..0da033a5b 100644
--- a/src/org/apache/fop/layoutmgr/FlowLayoutManager.java
+++ b/src/org/apache/fop/layoutmgr/FlowLayoutManager.java
@@ -23,7 +23,7 @@ import java.util.List;
*/
public class FlowLayoutManager extends BlockStackingLayoutManager {
- protected List blockBreaks = new ArrayList();
+ protected List blockBreaks = new ArrayList();
/** Array of areas currently being filled stored by area class */
private BlockParent[] currentAreas = new BlockParent[Area.CLASS_MAX];
@@ -103,7 +103,7 @@ public class FlowLayoutManager extends BlockStackingLayoutManager {
PositionIterator breakPosIter =
new BreakPossPosIter(blockBreaks, iStartPos,
lfp.getLeafPos() + 1);
- iStartPos = lfp.getLeafPos() + 1;
+ iStartPos = lfp.getLeafPos() + 1;
while ((childLM = breakPosIter.getNextChildLM()) != null) {
childLM.addAreas(breakPosIter, lc);
}
diff --git a/src/org/apache/fop/layoutmgr/LineLayoutManager.java b/src/org/apache/fop/layoutmgr/LineLayoutManager.java
index 882644764..3b05cb0af 100644
--- a/src/org/apache/fop/layoutmgr/LineLayoutManager.java
+++ b/src/org/apache/fop/layoutmgr/LineLayoutManager.java
@@ -86,7 +86,7 @@ public class LineLayoutManager extends InlineStackingLayoutManager {
private int follow;
// inline start pos when adding areas
- int iStartPos = 0;
+ int iStartPos = 0;
/**
* Create a new Line Layout Manager.
@@ -447,7 +447,7 @@ public class LineLayoutManager extends InlineStackingLayoutManager {
BreakPoss bp = (BreakPoss)iter.next();
if (bp.getLead() > lineLead) {
lineLead = bp.getLead();
- }
+ }
if (bp.getTotal() > maxtb) {
maxtb = bp.getTotal();
}
diff --git a/src/org/apache/fop/layoutmgr/PageLayoutManager.java b/src/org/apache/fop/layoutmgr/PageLayoutManager.java
index 9c494fa61..0583ae401 100644
--- a/src/org/apache/fop/layoutmgr/PageLayoutManager.java
+++ b/src/org/apache/fop/layoutmgr/PageLayoutManager.java
@@ -70,7 +70,7 @@ public class PageLayoutManager extends AbstractLayoutManager implements Runnable
private Flow curFlow;
private int flowBPD = 0;
- private int flowIPD = 0;
+ private int flowIPD = 0;
/** Manager which handles a queue of all pages which are completely
* laid out and ready for rendering, except for resolution of ID
@@ -412,7 +412,7 @@ public class PageLayoutManager extends AbstractLayoutManager implements Runnable
}
}
}
-
+
private void finishPage() {
if (curPage != null) {
// Layout static content into the regions
diff --git a/src/org/apache/fop/layoutmgr/StaticContentLayoutManager.java b/src/org/apache/fop/layoutmgr/StaticContentLayoutManager.java
index f7474860b..56205a2d7 100644
--- a/src/org/apache/fop/layoutmgr/StaticContentLayoutManager.java
+++ b/src/org/apache/fop/layoutmgr/StaticContentLayoutManager.java
@@ -24,8 +24,8 @@ import java.util.List;
public class StaticContentLayoutManager extends BlockStackingLayoutManager {
private RegionReference region;
- private List blockBreaks = new ArrayList();
-
+ private List blockBreaks = new ArrayList();
+
public StaticContentLayoutManager(FObj fobj) {
super(fobj);
}
@@ -33,7 +33,7 @@ public class StaticContentLayoutManager extends BlockStackingLayoutManager {
public void setRegionReference(RegionReference region) {
this.region = region;
}
-
+
public BreakPoss getNextBreakPoss(LayoutContext context) {
// currently active LM
@@ -73,7 +73,7 @@ public class StaticContentLayoutManager extends BlockStackingLayoutManager {
PositionIterator breakPosIter =
new BreakPossPosIter(blockBreaks, iStartPos,
lfp.getLeafPos() + 1);
- iStartPos = lfp.getLeafPos() + 1;
+ iStartPos = lfp.getLeafPos() + 1;
while ((childLM = breakPosIter.getNextChildLM()) != null) {
childLM.addAreas(breakPosIter, lc);
}
diff --git a/src/org/apache/fop/layoutmgr/list/Item.java b/src/org/apache/fop/layoutmgr/list/Item.java
index d55bd7cf8..bf96d6ab0 100644
--- a/src/org/apache/fop/layoutmgr/list/Item.java
+++ b/src/org/apache/fop/layoutmgr/list/Item.java
@@ -120,7 +120,7 @@ public class Item extends BlockStackingLayoutManager {
}
BreakPoss breakPoss = new BreakPoss(
new LeafPosition(this, childBreaks.size() - 1));
- if (over) {
+ if (over) {
breakPoss.setFlag(BreakPoss.NEXT_OVERFLOWS, true);
}
breakPoss.setStackingSize(stackSize);
diff --git a/src/org/apache/fop/layoutmgr/list/ListBlockLayoutManager.java b/src/org/apache/fop/layoutmgr/list/ListBlockLayoutManager.java
index 95335b4b1..2c4cf0603 100644
--- a/src/org/apache/fop/layoutmgr/list/ListBlockLayoutManager.java
+++ b/src/org/apache/fop/layoutmgr/list/ListBlockLayoutManager.java
@@ -122,7 +122,7 @@ public class ListBlockLayoutManager extends BlockStackingLayoutManager {
}
BreakPoss breakPoss = new BreakPoss(
new LeafPosition(this, bodyBreaks.size() - 1));
- if (over) {
+ if (over) {
breakPoss.setFlag(BreakPoss.NEXT_OVERFLOWS, true);
}
breakPoss.setStackingSize(stackSize);
@@ -163,7 +163,7 @@ public class ListBlockLayoutManager extends BlockStackingLayoutManager {
}
}
- if(borderProps != null) {
+ if(borderProps != null) {
addBorders(curBlockArea, borderProps);
}
if(backgroundProps != null) {
@@ -225,7 +225,7 @@ public class ListBlockLayoutManager extends BlockStackingLayoutManager {
bodyBreaks.clear();
reset(null);
} else {
-
+
}
}
}
diff --git a/src/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java b/src/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java
index b7a3219be..6d3efbf3a 100644
--- a/src/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java
+++ b/src/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java
@@ -177,7 +177,7 @@ public class ListItemLayoutManager extends BlockStackingLayoutManager {
ItemPosition rp = new ItemPosition(this, breakList.size() - 1, breakList);
BreakPoss breakPoss = new BreakPoss(rp);
- if (over) {
+ if (over) {
breakPoss.setFlag(BreakPoss.NEXT_OVERFLOWS, true);
}
breakPoss.setStackingSize(itemSize);
diff --git a/src/org/apache/fop/layoutmgr/table/Row.java b/src/org/apache/fop/layoutmgr/table/Row.java
index a7beb6695..c12bbba11 100644
--- a/src/org/apache/fop/layoutmgr/table/Row.java
+++ b/src/org/apache/fop/layoutmgr/table/Row.java
@@ -188,7 +188,7 @@ public class Row extends BlockStackingLayoutManager {
// the optimum is the maximum of all optimums
if (stackSize.opt > opt) {
opt = stackSize.opt;
- }
+ }
// the maximum is the largest maximum
if (stackSize.max > max) {
max = stackSize.max;
@@ -203,7 +203,7 @@ public class Row extends BlockStackingLayoutManager {
setFinished(true);
RowPosition rp = new RowPosition(this, breakList.size() - 1, breakList);
BreakPoss breakPoss = new BreakPoss(rp);
- if (over) {
+ if (over) {
breakPoss.setFlag(BreakPoss.NEXT_OVERFLOWS, true);
}
breakPoss.setStackingSize(rowSize);
@@ -217,7 +217,7 @@ public class Row extends BlockStackingLayoutManager {
* @param pos a Position returned by a child layout manager
* representing a potential break decision.
* If pos is null, then back up to the first child LM.
- */
+ */
protected void reset(Position pos) {
LayoutManager curLM; // currently active LM
int cellcount = 0;
@@ -249,7 +249,7 @@ public class Row extends BlockStackingLayoutManager {
*/
public void setYOffset(int off) {
yoffset = off;
- }
+ }
/**
* Add the areas for the break points.
diff --git a/src/org/apache/fop/layoutmgr/table/TableLayoutManager.java b/src/org/apache/fop/layoutmgr/table/TableLayoutManager.java
index db0864afc..d968ce23d 100644
--- a/src/org/apache/fop/layoutmgr/table/TableLayoutManager.java
+++ b/src/org/apache/fop/layoutmgr/table/TableLayoutManager.java
@@ -287,7 +287,7 @@ public class TableLayoutManager extends BlockStackingLayoutManager {
curBlockArea.setHeight(tableHeight);
- if(borderProps != null) {
+ if(borderProps != null) {
addBorders(curBlockArea, borderProps);
}
if(backgroundProps != null) {
diff --git a/src/org/apache/fop/mif/MIFHandler.java b/src/org/apache/fop/mif/MIFHandler.java
index 99e4333a3..1e4c320f4 100644
--- a/src/org/apache/fop/mif/MIFHandler.java
+++ b/src/org/apache/fop/mif/MIFHandler.java
@@ -119,7 +119,7 @@ public class MIFHandler extends StructureHandler {
}
public void endPageSequence(PageSequence pageSeq) throws FOPException {
-
+
}
public void startFlow(Flow fl) {
diff --git a/src/org/apache/fop/pdf/DCTFilter.java b/src/org/apache/fop/pdf/DCTFilter.java
index 47260b785..010035fd5 100644
--- a/src/org/apache/fop/pdf/DCTFilter.java
+++ b/src/org/apache/fop/pdf/DCTFilter.java
@@ -34,6 +34,6 @@ public class DCTFilter extends PDFFilter {
StreamUtilities.streamCopy(in, out, length);
out.close();
}
-
+
}
diff --git a/src/org/apache/fop/pdf/PDFColorSpace.java b/src/org/apache/fop/pdf/PDFColorSpace.java
index b8659ef2d..87862115d 100644
--- a/src/org/apache/fop/pdf/PDFColorSpace.java
+++ b/src/org/apache/fop/pdf/PDFColorSpace.java
@@ -11,10 +11,10 @@ public class PDFColorSpace {
private boolean hasICCProfile;
private byte[] iccProfile;
private int numComponents;
-
+
// Ok... so I had some grand purpose for this, but I can't recall.
// I'm just writing it
-
+
public static int DEVICE_UNKNOWN = -1;
public static int DEVICE_GRAY = 1;
// what's the *official* spelling?
diff --git a/src/org/apache/fop/pdf/PDFDocument.java b/src/org/apache/fop/pdf/PDFDocument.java
index fdd8578bd..afbe71706 100644
--- a/src/org/apache/fop/pdf/PDFDocument.java
+++ b/src/org/apache/fop/pdf/PDFDocument.java
@@ -161,28 +161,28 @@ public class PDFDocument {
/**
* List of Links.
- */
+ */
protected List links = new ArrayList();
/**
* List of FileSpecs.
- */
+ */
protected List filespecs = new ArrayList();
/**
* List of GoToRemotes.
- */
+ */
protected List gotoremotes = new ArrayList();
/**
* List of GoTos.
- */
+ */
protected List gotos = new ArrayList();
/**
* creates an empty PDF document <p>
- *
+ *
* The constructor creates a /Root and /Pages object to
* track the document but does not write these objects until
* the trailer is written. Note that the object ID of the
@@ -1464,8 +1464,8 @@ public class PDFDocument {
/**
* Add an annotation list object to the pdf document
*
- * @param obj the annotation list to add
- */
+ * @param obj the annotation list to add
+ */
public void addAnnotList(PDFAnnotList obj) {
this.objects.add(obj);
}
@@ -1536,7 +1536,7 @@ public class PDFDocument {
* add the position of this object to the list of object
* locations
*/
- location.set(object.getNumber() - 1,
+ location.set(object.getNumber() - 1,
new Integer(this.position));
/*
@@ -1586,7 +1586,7 @@ public class PDFDocument {
output(stream);
for (int count = 0; count < trailerObjects.size(); count++) {
PDFObject o = (PDFObject) trailerObjects.get(count);
- this.location.set(o.getNumber() - 1,
+ this.location.set(o.getNumber() - 1,
new Integer(this.position));
this.position += o.output(stream);
}
diff --git a/src/org/apache/fop/pdf/PDFFunction.java b/src/org/apache/fop/pdf/PDFFunction.java
index 32382b955..732d902a8 100644
--- a/src/org/apache/fop/pdf/PDFFunction.java
+++ b/src/org/apache/fop/pdf/PDFFunction.java
@@ -699,35 +699,35 @@ public class PDFFunction extends PDFObject {
}
if (range != null) {
if (!range.equals(func.range)) {
- return false;
+ return false;
}
} else if (func.range != null) {
return false;
}
if (size != null) {
if (!size.equals(func.size)) {
- return false;
+ return false;
}
} else if (func.size != null) {
return false;
}
if (encode != null) {
if (!encode.equals(func.encode)) {
- return false;
+ return false;
}
} else if (func.encode != null) {
return false;
}
if (decode != null) {
if (!decode.equals(func.decode)) {
- return false;
+ return false;
}
} else if (func.decode != null) {
return false;
}
if (functionDataStream != null) {
if (!functionDataStream.equals(func.functionDataStream)) {
- return false;
+ return false;
}
} else if (func.functionDataStream != null) {
return false;
diff --git a/src/org/apache/fop/pdf/PDFICCStream.java b/src/org/apache/fop/pdf/PDFICCStream.java
index b3f9c140d..9e61487cf 100644
--- a/src/org/apache/fop/pdf/PDFICCStream.java
+++ b/src/org/apache/fop/pdf/PDFICCStream.java
@@ -12,7 +12,7 @@ import java.awt.color.ICC_Profile;
public class PDFICCStream extends PDFStream {
private int origLength;
private int len1, len3;
-
+
private ICC_Profile cp;
private PDFColorSpace pdfColorSpace;
@@ -20,12 +20,12 @@ public class PDFICCStream extends PDFStream {
this.cp = cp;
pdfColorSpace = alt;
}
-
+
public PDFICCStream(int num) {
super(num);
cp = null;
}
-
+
// overload the base object method so we don't have to copy
// byte arrays around so much
protected int output(java.io.OutputStream stream)
@@ -38,11 +38,11 @@ public class PDFICCStream extends PDFStream {
StringBuffer pb = new StringBuffer();
pb.append(this.number).append(" ").append(this.generation).append(" obj\n<< ");
pb.append("/N ").append(cp.getNumComponents()).append(" ");
-
+
if (pdfColorSpace != null) {
pb.append("/Alternate /").append(pdfColorSpace.getColorSpacePDFString()).append(" ");
}
-
+
pb.append("/Length ").append((_data.getSize() + 1)).append(" ").append(filterEntry);
pb.append(" >>\n");
byte[] p = pb.toString().getBytes();
diff --git a/src/org/apache/fop/pdf/PDFOutline.java b/src/org/apache/fop/pdf/PDFOutline.java
index 48e281b81..c7b3e3b80 100644
--- a/src/org/apache/fop/pdf/PDFOutline.java
+++ b/src/org/apache/fop/pdf/PDFOutline.java
@@ -156,7 +156,7 @@ public class PDFOutline extends PDFObject {
// byte order marker (0xfeff)
result.append("\\376\\377");
-
+
for (int i = 0; i < l; i++) {
char ch = s.charAt(i);
int high = (ch & 0xff00) >>> 8;
diff --git a/src/org/apache/fop/pdf/PDFPage.java b/src/org/apache/fop/pdf/PDFPage.java
index fa958cce4..fb55e8f15 100644
--- a/src/org/apache/fop/pdf/PDFPage.java
+++ b/src/org/apache/fop/pdf/PDFPage.java
@@ -14,7 +14,7 @@ package org.apache.fop.pdf;
* specifies the dimensions of the page and references a /Resources
* object, a contents stream and the page's parent in the page
* hierarchy.
- *
+ *
* Modified by Mark Lillywhite, mark-fop@inomial.com. The Parent
* object was being referred to by reference, but all that we
* ever used from the Parent was it's PDF object ID, and according
@@ -95,7 +95,7 @@ public class PDFPage extends PDFResourceContext {
/**
* set this page contents
- *
+ *
* @param contents the contents of the page
*/
public void setContents(PDFStream contents) {
diff --git a/src/org/apache/fop/pdf/PDFResourceContext.java b/src/org/apache/fop/pdf/PDFResourceContext.java
index 6819cf187..89bb83c3e 100644
--- a/src/org/apache/fop/pdf/PDFResourceContext.java
+++ b/src/org/apache/fop/pdf/PDFResourceContext.java
@@ -14,7 +14,7 @@ package org.apache.fop.pdf;
* specifies the dimensions of the page and references a /Resources
* object, a contents stream and the page's parent in the page
* hierarchy.
- *
+ *
* Modified by Mark Lillywhite, mark-fop@inomial.com. The Parent
* object was being referred to by reference, but all that we
* ever used from the Parent was it's PDF object ID, and according
diff --git a/src/org/apache/fop/render/pdf/FontSetup.java b/src/org/apache/fop/render/pdf/FontSetup.java
index 21ae5eced..8d2aa7a06 100644
--- a/src/org/apache/fop/render/pdf/FontSetup.java
+++ b/src/org/apache/fop/render/pdf/FontSetup.java
@@ -159,7 +159,7 @@ public class FontSetup {
metricsFile,
configFontInfo.getKerning());
fontInfo.addMetrics(internalName, font);
-
+
ArrayList triplets = configFontInfo.getFontTriplets();
for (int c = 0; c < triplets.size(); c++) {
FontTriplet triplet = (FontTriplet)triplets.get(c);
diff --git a/src/org/apache/fop/render/pdf/FopPDFImage.java b/src/org/apache/fop/render/pdf/FopPDFImage.java
index 256e6af77..3027122cf 100644
--- a/src/org/apache/fop/render/pdf/FopPDFImage.java
+++ b/src/org/apache/fop/render/pdf/FopPDFImage.java
@@ -127,9 +127,9 @@ public class FopPDFImage implements PDFImage {
protected PDFStream getPSDataStream() throws IOException {
int length = 0;
- int i = 0;
+ int i = 0;
EPSImage epsImage = (EPSImage) fopImage;
- int[] bbox = epsImage.getBBox();
+ int[] bbox = epsImage.getBBox();
int bboxw = bbox[2] - bbox[0];
int bboxh = bbox[3] - bbox[1];
diff --git a/src/org/apache/fop/render/pdf/PDFRenderer.java b/src/org/apache/fop/render/pdf/PDFRenderer.java
index add3dd45c..2a75d2768 100644
--- a/src/org/apache/fop/render/pdf/PDFRenderer.java
+++ b/src/org/apache/fop/render/pdf/PDFRenderer.java
@@ -19,12 +19,12 @@ import org.apache.fop.apps.Version;
import org.apache.fop.fo.properties.RuleStyle;
import org.apache.fop.fo.properties.BackgroundRepeat;
import org.apache.fop.pdf.PDFStream;
-import org.apache.fop.pdf.PDFDocument;
+import org.apache.fop.pdf.PDFDocument;
import org.apache.fop.pdf.PDFInfo;
import org.apache.fop.pdf.PDFResources;
import org.apache.fop.pdf.PDFResourceContext;
import org.apache.fop.pdf.PDFXObject;
-import org.apache.fop.pdf.PDFPage;
+import org.apache.fop.pdf.PDFPage;
import org.apache.fop.pdf.PDFState;
import org.apache.fop.pdf.PDFLink;
import org.apache.fop.pdf.PDFOutline;
@@ -34,7 +34,7 @@ import org.apache.fop.extensions.BookmarkData;
import org.apache.fop.area.Trait;
import org.apache.fop.area.TreeExt;
-import org.apache.fop.area.CTM;
+import org.apache.fop.area.CTM;
import org.apache.fop.area.Title;
import org.apache.fop.area.PageViewport;
import org.apache.fop.area.Page;
@@ -661,7 +661,7 @@ public class PDFRenderer extends PrintRenderer {
closeText();
currentStream.add("ET\n");
}
- currentStream.add("q\n");
+ currentStream.add("q\n");
float x = (float)bv.getXOffset() / 1000f;
float y = (float)bv.getYOffset() / 1000f;
float width = (float)bv.getWidth() / 1000f;
@@ -677,7 +677,7 @@ public class PDFRenderer extends PrintRenderer {
if (ctm != null) {
endVParea();
}
-
+
if (bv.getClip()) {
currentStream.add("Q\n");
if (ctm == null) {
diff --git a/src/org/apache/fop/render/pdf/fonts/LazyFont.java b/src/org/apache/fop/render/pdf/fonts/LazyFont.java
index ab99a8b24..53ee462cf 100644
--- a/src/org/apache/fop/render/pdf/fonts/LazyFont.java
+++ b/src/org/apache/fop/render/pdf/fonts/LazyFont.java
@@ -15,21 +15,21 @@ import java.util.HashMap;
import org.apache.fop.render.pdf.FontReader;
public class LazyFont extends Font implements FontDescriptor {
-
+
private String metricsFileName = null;
private String fontEmbedPath = null;
private boolean useKerning = false;
-
+
private boolean isMetricsLoaded = false;
private Font realFont = null;
private FontDescriptor realFontDescriptor = null;
-
+
public LazyFont(String fontEmbedPath, String metricsFileName, boolean useKerning){
this.metricsFileName = metricsFileName;
this.fontEmbedPath = fontEmbedPath;
this.useKerning = useKerning;
}
-
+
private void load(){
if(! isMetricsLoaded){
isMetricsLoaded = true;
@@ -52,11 +52,11 @@ public class LazyFont extends Font implements FontDescriptor {
}
}
}
-
+
public Font getRealFont(){
return realFont;
}
-
+
public boolean isMultiByte() {
return realFont.isMultiByte();
}
@@ -66,114 +66,114 @@ public class LazyFont extends Font implements FontDescriptor {
load();
return realFont.encoding();
}
-
+
public String fontName(){
load();
return realFont.fontName();
}
-
+
public byte getSubType(){
load();
return realFont.getSubType();
}
-
+
public char mapChar(char c){
load();
return realFont.mapChar(c);
}
-
+
// FontMetrics
public int getAscender(int size){
load();
return realFont.getAscender(size);
}
-
+
public int getCapHeight(int size){
load();
return realFont.getCapHeight(size);
}
-
+
public int getDescender(int size){
load();
return realFont.getDescender(size);
}
-
+
public int getXHeight(int size){
load();
return realFont.getXHeight(size);
}
-
+
public int getFirstChar(){
load();
return realFont.getFirstChar();
}
-
+
public int getLastChar(){
load();
return realFont.getLastChar();
}
-
+
public int width(int i, int size){
load();
return realFont.width(i, size);
}
-
+
public int[] getWidths(int size){
load();
return realFont.getWidths(size);
}
-
+
// FontDescriptor
public int getCapHeight(){
load();
return realFontDescriptor.getCapHeight();
}
-
+
public int getDescender(){
load();
return realFontDescriptor.getDescender();
}
-
+
public int getAscender(){
load();
return realFontDescriptor.getAscender();
}
-
+
public int getFlags(){
load();
return realFontDescriptor.getFlags();
}
-
+
public int[] getFontBBox(){
load();
return realFontDescriptor.getFontBBox();
}
-
+
public int getItalicAngle(){
load();
return realFontDescriptor.getItalicAngle();
}
-
+
public int getStemV(){
load();
return realFontDescriptor.getStemV();
}
-
+
public boolean hasKerningInfo(){
load();
return realFontDescriptor.hasKerningInfo();
}
-
+
public HashMap getKerningInfo(){
load();
return realFontDescriptor.getKerningInfo();
}
-
+
public boolean isEmbeddable(){
load();
return realFontDescriptor.isEmbeddable();
}
-
+
public PDFStream getFontFile(int objNum){
load();
return realFontDescriptor.getFontFile(objNum);
diff --git a/src/org/apache/fop/rtf/renderer/RTFHandler.java b/src/org/apache/fop/rtf/renderer/RTFHandler.java
index 921b18b4e..0a03d3e0b 100644
--- a/src/org/apache/fop/rtf/renderer/RTFHandler.java
+++ b/src/org/apache/fop/rtf/renderer/RTFHandler.java
@@ -43,7 +43,7 @@ import java.io.IOException;
private RtfDocumentArea _docArea;
private RtfParagraph _para;
private boolean _warned = false;
-
+
private static final String ALPHA_WARNING = "WARNING: RTF renderer is veryveryalpha at this time, see class org.apache.fop.rtf.renderer.RTFHandler";
public RTFHandler(OutputStream os) {
@@ -58,7 +58,7 @@ import java.io.IOException;
}
public void startDocument() throws SAXException {
- // FIXME sections should be created
+ // FIXME sections should be created
try {
_rtfFile = new RtfFile(new OutputStreamWriter(_os));
_docArea = _rtfFile.startDocumentArea();
diff --git a/src/org/apache/fop/svg/PDFANode.java b/src/org/apache/fop/svg/PDFANode.java
index 34426dcdf..fb93a103a 100644
--- a/src/org/apache/fop/svg/PDFANode.java
+++ b/src/org/apache/fop/svg/PDFANode.java
@@ -104,7 +104,7 @@ public class PDFANode extends CompositeGraphicsNode {
destination = "" + x + " " + y + " "
+ (x + width) + " " + (y + height);
}
- pdfg.addLink(getBounds(), transform, destination, type);
+ pdfg.addLink(getBounds(), transform, destination, type);
}
}
}
diff --git a/src/org/apache/fop/svg/PDFDocumentGraphics2D.java b/src/org/apache/fop/svg/PDFDocumentGraphics2D.java
index f31ca91d6..ac59a489e 100644
--- a/src/org/apache/fop/svg/PDFDocumentGraphics2D.java
+++ b/src/org/apache/fop/svg/PDFDocumentGraphics2D.java
@@ -56,7 +56,7 @@ public class PDFDocumentGraphics2D extends PDFGraphics2D {
*/
PDFDocumentGraphics2D(boolean textAsShapes) {
super(textAsShapes);
-
+
if (!textAsShapes) {
fontInfo = new FontInfo();
FontSetup.setup(fontInfo, null);
@@ -109,7 +109,7 @@ public class PDFDocumentGraphics2D extends PDFGraphics2D {
* @param stream the stream that the final document should be written to.
* @param width the width of the document
* @param height the height of the document
- * @throws IOException an io exception if there is a problem
+ * @throws IOException an io exception if there is a problem
* writing to the output stream
*/
public PDFDocumentGraphics2D(boolean textAsShapes, OutputStream stream,
diff --git a/src/org/apache/fop/svg/PDFGraphics2D.java b/src/org/apache/fop/svg/PDFGraphics2D.java
index 8ac1f78bc..354178565 100644
--- a/src/org/apache/fop/svg/PDFGraphics2D.java
+++ b/src/org/apache/fop/svg/PDFGraphics2D.java
@@ -361,7 +361,7 @@ public class PDFGraphics2D extends AbstractGraphics2D {
return false;
}
- // first we look to see if we've already added this image to
+ // first we look to see if we've already added this image to
// the pdf document. If so, we just reuse the reference;
// otherwise we have to build a FopImage and add it to the pdf
// document
@@ -610,7 +610,7 @@ public class PDFGraphics2D extends AbstractGraphics2D {
boolean newTransform = graphicsState.checkTransform(trans)
&& !trans.isIdentity();
- if (newClip || newTransform) {
+ if (newClip || newTransform) {
currentStream.write("q\n");
graphicsState.push();
if (newClip) {
@@ -993,7 +993,7 @@ public class PDFGraphics2D extends AbstractGraphics2D {
if (outputStream != null) {
try {
- this.pdfDoc.output(outputStream);
+ this.pdfDoc.output(outputStream);
} catch (IOException ioe) {
// ignore exception, will be thrown again later
}
@@ -1172,10 +1172,10 @@ public class PDFGraphics2D extends AbstractGraphics2D {
float size;
name = fontState.getFontName();
size = (float)fontState.getFontSize() / 1000f;
-
+
if ((!name.equals(this.currentFontName))
|| (size != this.currentFontSize)) {
- this.currentFontName = name;
+ this.currentFontName = name;
this.currentFontSize = size;
currentStream.write("/" + name + " " + size + " Tf\n");
@@ -1193,7 +1193,7 @@ public class PDFGraphics2D extends AbstractGraphics2D {
HashMap vals = new HashMap();
vals.put(PDFGState.ca, new Float(salpha / 255f));
PDFGState gstate = pdfDoc.makeGState(vals, graphicsState.getGState());
- resourceContext.addGState(gstate);
+ resourceContext.addGState(gstate);
currentStream.write("/" + gstate.getName() + " gs\n");
}
diff --git a/src/org/apache/fop/viewer/GoToPageDialog.java b/src/org/apache/fop/viewer/GoToPageDialog.java
index 39a8bcd02..ba6ebcd0d 100644
--- a/src/org/apache/fop/viewer/GoToPageDialog.java
+++ b/src/org/apache/fop/viewer/GoToPageDialog.java
@@ -22,7 +22,7 @@ import java.awt.event.ActionListener;
public class GoToPageDialog extends JDialog {
private JTextField pgNbField;
private int pageNumber = -1;
-
+
/**
* Creates modal dialog with a given title, attached to a given frame.
*/
diff --git a/src/org/apache/fop/viewer/PreviewDialog.java b/src/org/apache/fop/viewer/PreviewDialog.java
index db813dd5d..609e7ce74 100644
--- a/src/org/apache/fop/viewer/PreviewDialog.java
+++ b/src/org/apache/fop/viewer/PreviewDialog.java
@@ -4,9 +4,9 @@
* For details on use and redistribution please refer to the
* LICENSE file included with these sources.
*/
-
+
package org.apache.fop.viewer;
-
+
//Java
import java.awt.*;
import javax.swing.*;
@@ -499,11 +499,11 @@ public class PreviewDialog extends JFrame {
String msg = translator.getString("Exception.Occured");
setStatus(msg);
JOptionPane.showMessageDialog(
- getContentPane(),
+ getContentPane(),
"<html><b>" + msg + ":</b><br>"
- + e.getClass().getName() + "<br>" + e.getMessage() + "</html>", translator.getString("Exception.Error"),
+ + e.getClass().getName() + "<br>" + e.getMessage() + "</html>", translator.getString("Exception.Error"),
JOptionPane.ERROR_MESSAGE
- );
+ );
}
}
diff --git a/src/org/apache/fop/viewer/Translator.java b/src/org/apache/fop/viewer/Translator.java
index f36c61789..0f9a5cc8f 100644
--- a/src/org/apache/fop/viewer/Translator.java
+++ b/src/org/apache/fop/viewer/Translator.java
@@ -5,14 +5,14 @@
* LICENSE file included with these sources.
*/
-package org.apache.fop.viewer;
+package org.apache.fop.viewer;
//Java
-import java.util.ResourceBundle;
+import java.util.ResourceBundle;
import java.util.Locale;
import java.util.MissingResourceException;
-/**
+/**
* AWT Viewer's localization class, backed up by <code>java.util.ResourceBundle</code>.
* Originally contributed by:
* Stanislav.Gorkhover@jCatalog.com
@@ -25,10 +25,10 @@ public class Translator {
* Default constructor, default <code>Locale</code> is used.
*/
public Translator() {
- this(Locale.getDefault());
+ this(Locale.getDefault());
}
-
- /**
+
+ /**
* Constructor for a given <code>Locale</code>.
*/
public Translator(Locale locale) {