]> source.dussan.org Git - poi.git/commitdiff
Fix bug #48485 - Add extra paper size constans to PrintSetup, such as A3, B4 and B5
authorNick Burch <nick@apache.org>
Tue, 30 Mar 2010 10:05:53 +0000 (10:05 +0000)
committerNick Burch <nick@apache.org>
Tue, 30 Mar 2010 10:05:53 +0000 (10:05 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@929064 13f79535-47bb-0310-9956-ffa450edef68

src/documentation/content/xdocs/status.xml
src/java/org/apache/poi/hssf/record/PrintSetupRecord.java
src/java/org/apache/poi/ss/usermodel/PrintSetup.java

index 4498876f5d4cc64887a519e5129a1a9923f0bfe7..50bc1cd624d14f40329572ea503b399ba50c38d6 100644 (file)
@@ -34,6 +34,7 @@
 
     <changes>
         <release version="3.7-SNAPSHOT" date="2010-??-??">
+           <action dev="POI-DEVELOPERS" type="fix">48485 - Add extra paper size constans to PrintSetup, such as A3, B4 and B5</action>
            <action dev="POI-DEVELOPERS" type="fix">Make poifs.filesystem.DirectoryNode preserve the original ordering of its files, which HSMF needs to be able to correctly match up chunks</action>
            <action dev="POI-DEVELOPERS" type="add">Support evaluation of indirect defined names in INDIRECT</action>
            <action dev="POI-DEVELOPERS" type="fix">43670 - Improve HDGF ChunkV11 separator detection, and short string detection, to solve the "Negative length of ChunkHeader" problem</action>
index 08dafd4e0de6a93461dbf2d9af9ac22bf8e39d34..96f52b7675417e863cb0ddf0b4ef6f20fdb255df 100644 (file)
@@ -17,6 +17,7 @@
 
 package org.apache.poi.hssf.record;
 
+import org.apache.poi.ss.usermodel.PrintSetup;
 import org.apache.poi.util.LittleEndianOutput;
 import org.apache.poi.util.BitField;
 import org.apache.poi.util.BitFieldFactory;
@@ -25,12 +26,14 @@ import org.apache.poi.util.BitFieldFactory;
  * Title:        PAGESETUP (0x00A1)<p/>
  * Description:  Stores print setup options -- bogus for HSSF (and marked as such)<p/>
  * REFERENCE:  PG 385 Microsoft Excel 97 Developer's Kit (ISBN: 1-57231-498-2)<p/>
+ * REFERENCE:  PG 412 Microsoft Excel Binary File Format Structure v20091214<p/>
  * @author Andrew C. Oliver (acoliver at apache dot org)
  * @author Jason Height (jheight at chariot dot net dot au)
  * @version 2.0-pre
  */
 public final class PrintSetupRecord extends StandardRecord {
     public final static short     sid = 0x00A1;
+    /** Constants for this are held in {@link PrintSetup} */
     private short                 field_1_paper_size;
     private short                 field_2_scale;
     private short                 field_3_page_start;
index 0d8aa74bb7bbfef4f6a15c30f7f9d28f49ebc2f7..4857df4d809c0b77432e25fd778779afbdd87c57 100644 (file)
 package org.apache.poi.ss.usermodel;
 
 public interface PrintSetup {
-
+    /** US Letter 8 1/2 x 11 in */
     public static final short LETTER_PAPERSIZE = 1;
-
+    /** US Letter Small 8 1/2 x 11 in */
+    public static final short LETTER_SMALL_PAGESIZE = 2;
+    /** US Tabloid 11 x 17 in */
+    public static final short TABLOID_PAPERSIZE = 3;
+    /** US Ledger 17 x 11 in */
+    public static final short LEDGER_PAPERSIZE = 4;
+    /** US Legal 8 1/2 x 14 in */
     public static final short LEGAL_PAPERSIZE = 5;
-
+    /** US Statement 5 1/2 x 8 1/2 in */
+    public static final short STATEMENT_PAPERSIZE = 6;
+    /** US Executive 7 1/4 x 10 1/2 in */
     public static final short EXECUTIVE_PAPERSIZE = 7;
-
+    /** A3 - 297x420 mm */
+    public static final short A3_PAPERSIZE = 8;
+    /** A4 - 210x297 mm */
     public static final short A4_PAPERSIZE = 9;
-
+    /** A4 Small - 210x297 mm */
+    public static final short A4_SMALL_PAPERSIZE = 10;
+    /** A5 - 148x210 mm */
     public static final short A5_PAPERSIZE = 11;
-
+    /** B4 (JIS) 250x354 mm */
+    public static final short B4_PAPERSIZE = 12;
+    /** B5 (JIS) 182x257 mm */
+    public static final short B5_PAPERSIZE = 13;
+    /** Folio 8 1/2 x 13 in */
+    public static final short FOLIO8_PAPERSIZE = 14;
+    /** Quarto 215x275 mm */
+    public static final short QUARTO_PAPERSIZE = 15;
+    /** 10 x 14 in */
+    public static final short TEN_BY_FOURTEEN_PAPERSIZE = 16;
+    /** 11 x 17 in */
+    public static final short ELEVEN_BY_SEVENTEEN_PAPERSIZE = 17;
+    /** US Note 8 1/2 x 11 in */
+    public static final short NOTE8_PAPERSIZE = 18;
+    /** US Envelope #9 3 7/8 x 8 7/8 */
+    public static final short ENVELOPE_9_PAPERSIZE = 19;
+    /** US Envelope #10 4 1/8 x 9 1/2 */
     public static final short ENVELOPE_10_PAPERSIZE = 20;
-
+    /** Envelope DL 110x220 mm */
     public static final short ENVELOPE_DL_PAPERSIZE = 27;
-
+    /** Envelope C5 162x229 mm */
     public static final short ENVELOPE_CS_PAPERSIZE = 28;
+    public static final short ENVELOPE_C5_PAPERSIZE = 28;
+    /** Envelope C3 324x458 mm */
+    public static final short ENVELOPE_C3_PAPERSIZE = 29;
+    /** Envelope C4 229x324 mm */
+    public static final short ENVELOPE_C4_PAPERSIZE = 30;
+    /** Envelope C6 114x162 mm */
+    public static final short ENVELOPE_C6_PAPERSIZE = 31;
 
     public static final short ENVELOPE_MONARCH_PAPERSIZE = 37;
+    /** A4 Extra - 9.27 x 12.69 in */
+    public static final short A4_EXTRA_PAPERSIZE = 53;
+    /** A4 Transverse - 210x297 mm */
+    public static final short A4_TRANSVERSE_PAPERSIZE = 55;
+    /** A4 Plus - 210x330 mm */
+    public static final short A4_PLUS_PAPERSIZE = 60;
+    /** US Letter Rotated 11 x 8 1/2 in */
+    public static final short LETTER_ROTATED_PAPERSIZE = 75;
+    /** A4 Rotated - 297x210 mm */
+    public static final short A4_ROTATED_PAPERSIZE = 77;
 
     /**    
      * Set the paper size.