poi-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ser...@apache.org
Subject svn commit: r1147419 - /poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/sprm/CharacterSprmUncompressor.java
Date Sat, 16 Jul 2011 12:36:45 GMT
Author: sergey
Date: Sat Jul 16 12:36:45 2011
New Revision: 1147419

URL: http://svn.apache.org/viewvc?rev=1147419&view=rev
Log:
a bit more comments (quotes from specifications)

Modified:
    poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/sprm/CharacterSprmUncompressor.java

Modified: poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/sprm/CharacterSprmUncompressor.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/sprm/CharacterSprmUncompressor.java?rev=1147419&r1=1147418&r2=1147419&view=diff
==============================================================================
--- poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/sprm/CharacterSprmUncompressor.java (original)
+++ poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/sprm/CharacterSprmUncompressor.java Sat
Jul 16 12:36:45 2011
@@ -95,10 +95,23 @@ public final class CharacterSprmUncompre
       case 0x2:
         newCHP.setFFldVanish (getFlag (sprm.getOperand()));
         break;
-      case 0x3:
-        newCHP.setFcPic (sprm.getOperand());
-        newCHP.setFSpec (true);
-        break;
+        case 0x3:
+            // sprmCPicLocation -- 0x6A03
+            /*
+             * Microsoft Office Word 97-2007 Binary File Format (.doc)
+             * Specification
+             * 
+             * Page 75 of 210
+             * 
+             * sprmCPicLocation (opcode 0x6A03) is used ONLY IN CHPX FKPs. This
+             * sprm moves the 4-byte operand of the sprm into the chp.fcPic
+             * field. It simultaneously sets chp.fSpec to 1. This sprm is also
+             * used when the chp.lTagObj field that is unioned with chp.fcPic is
+             * to be set for OLE objects.
+             */
+            newCHP.setFcPic( sprm.getOperand() );
+            newCHP.setFSpec( true );
+            break;
       case 0x4:
         newCHP.setIbstRMark ((short) sprm.getOperand());
         break;
@@ -475,9 +488,10 @@ public final class CharacterSprmUncompre
       case 0x54:
         newCHP.setFImprint (getFlag (sprm.getOperand()));
         break;
-      case 0x55:
-        newCHP.setFSpec (getFlag (sprm.getOperand()));
-        break;
+        case 0x55:
+            // sprmCFSpec -- 0x0855
+            newCHP.setFSpec( getFlag( sprm.getOperand() ) );
+            break;
       case 0x56:
         newCHP.setFObj (getFlag (sprm.getOperand()));
         break;



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


Mime
View raw message