diff options
author | William Victor Mote <vmote@apache.org> | 2003-06-29 22:56:32 +0000 |
---|---|---|
committer | William Victor Mote <vmote@apache.org> | 2003-06-29 22:56:32 +0000 |
commit | 811b58dfb133359e5c30744417605ba01c891b88 (patch) | |
tree | 3b8a998edf8a5fa02a8ef578acce1b8d9796f18b /src/java/org/apache/fop/rtf/rtflib/rtfdoc/RtfPage.java | |
parent | c36d9aa9f5e4f20778c5c920b11859547a6e87e2 (diff) | |
download | xmlgraphics-fop-811b58dfb133359e5c30744417605ba01c891b88.tar.gz xmlgraphics-fop-811b58dfb133359e5c30744417605ba01c891b88.zip |
Place jfor credits in a separate section, primarily to keep the standard header intact.
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@196540 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/fop/rtf/rtflib/rtfdoc/RtfPage.java')
-rw-r--r-- | src/java/org/apache/fop/rtf/rtflib/rtfdoc/RtfPage.java | 40 |
1 files changed, 23 insertions, 17 deletions
diff --git a/src/java/org/apache/fop/rtf/rtflib/rtfdoc/RtfPage.java b/src/java/org/apache/fop/rtf/rtflib/rtfdoc/RtfPage.java index e5abe6d12..c02af9849 100644 --- a/src/java/org/apache/fop/rtf/rtflib/rtfdoc/RtfPage.java +++ b/src/java/org/apache/fop/rtf/rtflib/rtfdoc/RtfPage.java @@ -43,13 +43,19 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * ============================================================================ * - * The RTF library of the FOP project consists of voluntary contributions made by - * many individuals on behalf of the Apache Software Foundation and was originally - * created by Bertrand Delacretaz <bdelacretaz@codeconsult.ch> and contributors of - * the jfor project (www.jfor.org), who agreed to donate jfor to the FOP project. - * For more information on the Apache Software Foundation, please - * see <http://www.apache.org/>. + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation and was originally created by + * James Tauber <jtauber@jtauber.com>. For more information on the Apache + * Software Foundation, please see <http://www.apache.org/>. */ + +/* + * This file is part of the RTF library of the FOP project, which was originally + * created by Bertrand Delacretaz <bdelacretaz@codeconsult.ch> and by other + * contributors to the jfor project (www.jfor.org), who agreed to donate jfor to + * the FOP project. + */ + package org.apache.fop.rtf.rtflib.rtfdoc; import java.io.Writer; @@ -68,19 +74,19 @@ extends RtfContainer{ /**RtfPage attributes*/ public final static String PAGE_WIDTH = "paperw"; public final static String PAGE_HEIGHT = "paperh"; - + public final static String MARGIN_TOP = "margt"; public final static String MARGIN_BOTTOM = "margb"; public final static String MARGIN_LEFT = "margl"; public final static String MARGIN_RIGHT = "margr"; - + public final static String[] PAGE_ATTR = new String[]{ PAGE_WIDTH, PAGE_HEIGHT, MARGIN_TOP, MARGIN_BOTTOM, MARGIN_LEFT, MARGIN_RIGHT }; - + /** RtfPage creates new page attributes with the parent container, the writer - and the attributes*/ + and the attributes*/ RtfPage(RtfPageArea parent, Writer w, RtfAttributes attrs) throws IOException { super((RtfContainer)parent,w); m_attrib = attrs; @@ -90,31 +96,31 @@ extends RtfContainer{ PAGE_ATTR, if not null */ protected void writeRtfContent() throws IOException { writeAttributes(m_attrib, PAGE_ATTR); - + if (m_attrib != null) { Object widthRaw = m_attrib.getValue( PAGE_WIDTH ); Object heightRaw = m_attrib.getValue( PAGE_HEIGHT ); - + if ((widthRaw instanceof Integer) && (heightRaw instanceof Integer) && ((Integer) widthRaw).intValue() > ((Integer) heightRaw).intValue()) { writeControlWord( "landscape" ); } - } + } } - + /** RtfPage - attributes accessor */ public RtfAttributes getAttributes(){ return m_attrib; } - + /** RtfPage - is overwritten here because page attributes have no content - only attributes. RtfContainer is defined not to write when empty. + only attributes. RtfContainer is defined not to write when empty. Therefore must make this true to print.*/ protected boolean okToWriteRtf() { return true; } - + } |