ooo-build r15546 - in trunk: . scratch/mso-dumper/src
- From: thorstenb svn gnome org
- To: svn-commits-list gnome org
- Subject: ooo-build r15546 - in trunk: . scratch/mso-dumper/src
- Date: Mon, 16 Mar 2009 08:41:47 +0000 (UTC)
Author: thorstenb
Date: Mon Mar 16 08:41:47 2009
New Revision: 15546
URL: http://svn.gnome.org/viewvc/ooo-build?rev=15546&view=rev
Log:
* scratch/mso-dumper/src/pptstream.py:
* scratch/mso-dumper/src/pptrecord.py: fixed minor bugs, added
proper handling for ppt table properties
Modified:
trunk/ChangeLog
trunk/scratch/mso-dumper/src/pptrecord.py
trunk/scratch/mso-dumper/src/pptstream.py
Modified: trunk/scratch/mso-dumper/src/pptrecord.py
==============================================================================
--- trunk/scratch/mso-dumper/src/pptrecord.py (original)
+++ trunk/scratch/mso-dumper/src/pptrecord.py Mon Mar 16 08:41:47 2009
@@ -164,7 +164,7 @@
handler = propData[propType][1](propType, propValue, isComplex, isBlip, complexBytes, self.appendLine)
handler.output()
else:
- self.appendLine("%4.4Xh: [unknown property type: %4.4Xh, value: %8.8Xh, complex: %d, blip: %d]"%(propType, propValue, isComplex, isBlip))
+ self.appendLine("%4.4Xh: [unknown property type: %4.4Xh, value: %8.8Xh, complex: %d, blip: %d]"%(propType, propType, propValue, isComplex, isBlip))
# -------------------------------------------------------------------
# special record handler: document atom
@@ -466,8 +466,12 @@
elementSize = self.readUnsignedInt(2)
self.printer("%4.4Xh: %s: [\"%s\"]"%(self.propType, self.propEntry[0], self.propEntry[2]))
for i in xrange(0, numElements):
- currElem = self.readUnsignedInt(elementSize)
- self.printer("%4.4Xh: %d = %Xh"%(i,currElem))
+ if elementSize > 4:
+ bytes = self.readBytes(elementSize)
+ self.printer("%4.4Xh: %d = [complex type]"%(self.propType,i))
+ else:
+ currElem = self.readUnsignedInt(elementSize)
+ self.printer("%4.4Xh: %d = %Xh"%(self.propType,i,currElem))
class UniCharPropertyHandler(BasePropertyHandler):
"""unicode string property."""
@@ -518,8 +522,11 @@
# -------------------------------------------------------------------
# special record handler: properties
-
- # opcode: [canonical name, prop handler, comment]
+#
+# IDs and comments from OOo's svx/inc/svx/msdffdef.hxx
+# (slightly adapted)
+#
+# opcode: [canonical name, prop handler, comment]
propData = {
@@ -810,8 +817,8 @@
902: ["DFF_Prop_dxWrapDistRight", LongPropertyHandler, "Right wrapping distance from text (Word)"],
903: ["DFF_Prop_dyWrapDistBottom", LongPropertyHandler, "Bottom wrapping distance from text (Word)"],
904: ["DFF_Prop_lidRegroup", LongPropertyHandler, "Regroup ID"],
- 927: ["DFF_Prop_tableProperties", LongPropertyHandler, ""],
- 928: ["DFF_Prop_tableRowProperties", LongPropertyHandler, ""],
+ 927: ["DFF_Prop_tableProperties", LongPropertyHandler, "Type of table: bit 1 plain, bit 2 placeholder, bit 3 rtl"],
+ 928: ["DFF_Prop_tableRowProperties", MsoArrayPropertyHandler, "Table row properties (row heights, actually)"],
937: ["DFF_Prop_xmlstuff", ZipStoragePropertyHandler, "Embedded ooxml"],
953: ["DFF_Prop_fEditedWrap", BoolPropertyHandler, "Has the wrap polygon been edited?"],
954: ["DFF_Prop_fBehindDocument", BoolPropertyHandler, "Word-only (shape is behind text)"],
Modified: trunk/scratch/mso-dumper/src/pptstream.py
==============================================================================
--- trunk/scratch/mso-dumper/src/pptstream.py (original)
+++ trunk/scratch/mso-dumper/src/pptstream.py Mon Mar 16 08:41:47 2009
@@ -18,7 +18,9 @@
class EndOfStream(Exception): pass
- # opcode: [canonical name, handler (optional)]
+# IDs from OOo's svx/inc/svx/msdffdef.hxx (slightly adapted)
+#
+# opcode: [canonical name, handler (optional)]
recData = {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]