[ooo-build-commit] scratch/mso-dumper
Kohei Yoshida
kohei at kemper.freedesktop.org
Fri Dec 18 11:40:29 PST 2009
scratch/mso-dumper/src/xlsrecord.py | 19 ++++++++++++++++---
1 file changed, 16 insertions(+), 3 deletions(-)
New commits:
commit 339c310e0450eda2f6230cd23fb04170e26fbb4c
Author: Kohei Yoshida <kyoshida at novell.com>
Date: Fri Dec 18 14:38:07 2009 -0500
[xls-dump] Finally found where the connector style info is stored.
There are plenty more drawing object properties to cover, but at
least I found what I came here for.
* scratch/mso-dumper/src/xlsrecord.py:
diff --git a/scratch/mso-dumper/src/xlsrecord.py b/scratch/mso-dumper/src/xlsrecord.py
index 4ebcce6..f55a5a0 100644
--- a/scratch/mso-dumper/src/xlsrecord.py
+++ b/scratch/mso-dumper/src/xlsrecord.py
@@ -5,7 +5,7 @@ import globals, formula
# -------------------------------------------------------------------
# record handler classes
-def getValueOrUnknown (list, idx):
+def getValueOrUnknown (list, idx, errmsg='(unknown)'):
listType = type(list)
if listType == type([]):
# list
@@ -16,7 +16,7 @@ def getValueOrUnknown (list, idx):
if list.has_key(idx):
return list[idx]
- return '(unknown)'
+ return errmsg
class BaseRecordHandler(globals.ByteStream):
@@ -2209,9 +2209,22 @@ together.
recHdl.appendLineBoolean(indent + "use auto text margin", I)
recHdl.appendLineBoolean(indent + "use select text", J)
+ class CXStyle:
+ style = [
+ 'straight connector', # 0x00000000
+ 'elbow-shaped connector', # 0x00000001
+ 'curved connector', # 0x00000002
+ 'no connector' # 0x00000003
+ ]
+
+ def appendLines (self, recHdl, prop, level):
+ indent = MSODrawing.singleIndent*level
+ styleName = getValueOrUnknown(MSODrawing.FOPT.CXStyle.style, prop.value)
+ recHdl.appendLine(indent + "connector style: %s (0x%8.8X)"%(styleName, prop.value))
propTable = {
- 0x00BF: ['Text Boolean Properties', TextBoolean]
+ 0x00BF: ['Text Boolean Properties', TextBoolean],
+ 0x0303: ['Connector Shape Style (cxstyle)', CXStyle]
}
class E:
More information about the ooo-build-commit
mailing list