[Libreoffice-commits] core.git: Branch 'feature/gsoc-calc-enhanced-db-range' - sc/source

Akash Shetye shetyeakash at gmail.com
Tue Jun 25 05:38:07 PDT 2013


 sc/source/filter/oox/stylesbuffer.cxx |   22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)

New commits:
commit 809154544ea1f49a1d7ef0f4b49b3378112f54d0
Author: Akash Shetye <shetyeakash at gmail.com>
Date:   Tue Jun 25 18:06:08 2013 +0530

    Add methods to get table name and Formatting and TableStyle.
    
    Change-Id: Ifb9011a4734810ac1f6ea64b676cb52a3e251a8d

diff --git a/sc/source/filter/oox/stylesbuffer.cxx b/sc/source/filter/oox/stylesbuffer.cxx
index 5428a34..502ceb7 100644
--- a/sc/source/filter/oox/stylesbuffer.cxx
+++ b/sc/source/filter/oox/stylesbuffer.cxx
@@ -2677,6 +2677,16 @@ void TableStyle::importTableStyleElement( const AttributeList& rAttribs )
     //is not showing up.
 }
 
+const OUString& TableStyle::getTableStyleName() const
+{
+    return mxTableFormatting->GetTableStyleName();
+}
+
+ScDBDataFormatting& TableStyle::getTableFormatting()
+{
+    return (*mxTableFormatting);
+}
+
 void TableStyle::finalizeImport()
 {
 }
@@ -3444,6 +3454,18 @@ void StylesBuffer::writeStyleXfToPropertySet( PropertySet& rPropSet, sal_Int32 n
         pXf->writeToPropertySet( rPropSet );
 }
 
+TableStyleRef StylesBuffer::getTableStyle( OUString& rTableStyleName )
+{
+    for( ::std::vector< TableStyleRef >::iterator i = maTableStyles.begin(); i < maTableStyles.end(); ++i)
+    {
+        if( ((*i)->getTableStyleName() ).equals(rTableStyleName) )
+        {
+            return(*i);
+        }
+    }
+    return 0;
+}
+
 // ============================================================================
 
 } // namespace xls


More information about the Libreoffice-commits mailing list