reportlab/platypus/tables.py
changeset 2574 d81949596070
parent 2523 0473810aff11
child 2575 0cba68b93555
--- a/reportlab/platypus/tables.py	Wed Mar 15 12:22:10 2006 +0000
+++ b/reportlab/platypus/tables.py	Wed Mar 15 16:47:27 2006 +0000
@@ -79,6 +79,9 @@
             # copy the parents list at construction time
             commands = commands + parent.getCommands()
             self._opts = parent._opts
+            for a in ('spaceBefore','spaceAfter'):
+                if hasattr(parent,a):
+                    setattr(self,a,getattr(parent,a))
         if cmds:
             commands = commands + list(cmds)
         self._cmds = commands
@@ -780,6 +783,9 @@
             self._addCommand(cmd)
         for k,v in tblstyle._opts.items():
             setattr(self,k,v)
+        for a in ('spaceBefore','spaceAfter'):
+            if not hasattr(self,a) and hasattr(tblstyle,a):
+                setattr(self,a,getattr(tblstyle,a))
 
     def _addCommand(self,cmd):
         if cmd[0] in ('BACKGROUND','ROWBACKGROUNDS','COLBACKGROUNDS'):