]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
support for background-color at fo:table
authorPeter Herweg <pherweg@apache.org>
Sun, 15 Jan 2006 17:34:33 +0000 (17:34 +0000)
committerPeter Herweg <pherweg@apache.org>
Sun, 15 Jan 2006 17:34:33 +0000 (17:34 +0000)
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@369235 13f79535-47bb-0310-9956-ffa450edef68

src/java/org/apache/fop/render/rtf/TableAttributesConverter.java

index c82d31dc270d40c191fca8c02a904d38ca5810cb..90d1cac21bfb69efa4bf7c060b966479f0d884b5 100644 (file)
@@ -129,12 +129,24 @@ public class TableAttributesConverter {
             if (fobj.getParent() instanceof TableRow) {
                 TableRow parentRow=(TableRow)fobj.getParent();
                 brd = parentRow.getCommonBorderPaddingBackground();
+                color = brd.backgroundColor;
             } else if (fobj.getParent() instanceof TableHeader) {
                 TableHeader parentHeader=(TableHeader)fobj.getParent();
                 brd = parentHeader.getCommonBorderPaddingBackground();
+                color = brd.backgroundColor;
             }
             
-            color = brd.backgroundColor;
+            if (color == null
+                               && fobj.getParent()!=null 
+                               && fobj.getParent().getParent()!=null 
+                               && fobj.getParent().getParent().getParent() instanceof Table) {
+               
+               Table table = (Table)fobj.getParent().getParent().getParent();
+               brd = table.getCommonBorderPaddingBackground();
+               color = brd.backgroundColor;
+            }
+            
+            
         }
         if ((color != null) 
                 && (color.getAlpha() != 0