incubator-ooo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zhan...@apache.org
Subject svn commit: r1383383 - in /incubator/ooo/trunk/main: sw/source/core/unocore/unotext.cxx writerfilter/source/dmapper/DomainMapper.cxx
Date Tue, 11 Sep 2012 12:44:53 GMT
Author: zhangjf
Date: Tue Sep 11 12:44:52 2012
New Revision: 1383383

URL: http://svn.apache.org/viewvc?rev=1383383&view=rev
Log:
#i120832#, the style and color set on table text by user should have higher priority than
that from table style 

Found by: Jinlong Wu,wujinlong@gmail.com
Patch by: bjcheny,companycy@gmail.com
Review by: zhangjf

Modified:
    incubator/ooo/trunk/main/sw/source/core/unocore/unotext.cxx
    incubator/ooo/trunk/main/writerfilter/source/dmapper/DomainMapper.cxx

Modified: incubator/ooo/trunk/main/sw/source/core/unocore/unotext.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/sw/source/core/unocore/unotext.cxx?rev=1383383&r1=1383382&r2=1383383&view=diff
==============================================================================
--- incubator/ooo/trunk/main/sw/source/core/unocore/unotext.cxx (original)
+++ incubator/ooo/trunk/main/sw/source/core/unocore/unotext.cxx Tue Sep 11 12:44:52 2012
@@ -2176,9 +2176,15 @@ lcl_ApplyCellProperties(
                     xCellText->createTextCursor();
                 xCellCurs->gotoStart( sal_False );
                 xCellCurs->gotoEnd( sal_True );
-                const uno::Reference< beans::XPropertySet > xCellTextProps(
-                        xCellCurs, uno::UNO_QUERY);
-                xCellTextProps->setPropertyValue(rName, rValue);
+                const uno::Reference< beans::XPropertyState > 
+                    xCellTextPropState(xCellCurs, uno::UNO_QUERY);
+                const beans::PropertyState state = xCellTextPropState->getPropertyState(rName);
+                if (state == beans::PropertyState_DEFAULT_VALUE)
+                {
+                    const uno::Reference< beans::XPropertySet > 
+                        xCellTextProps(xCellCurs, uno::UNO_QUERY);
+                    xCellTextProps->setPropertyValue(rName, rValue);
+                }
             }
         }
     }

Modified: incubator/ooo/trunk/main/writerfilter/source/dmapper/DomainMapper.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/writerfilter/source/dmapper/DomainMapper.cxx?rev=1383383&r1=1383382&r2=1383383&view=diff
==============================================================================
--- incubator/ooo/trunk/main/writerfilter/source/dmapper/DomainMapper.cxx (original)
+++ incubator/ooo/trunk/main/writerfilter/source/dmapper/DomainMapper.cxx Tue Sep 11 12:44:52
2012
@@ -4357,11 +4357,6 @@ void DomainMapper::lcl_startCharacterGro
 {
     m_pImpl->PushProperties(CONTEXT_CHARACTER);
     DomainMapperTableManager& rTableManager = m_pImpl->getTableManager();
-    if( rTableManager.getTableStyleName().getLength() )
-    {
-        PropertyMapPtr pTopContext = m_pImpl->GetTopContext();
-        rTableManager.CopyTextProperties(pTopContext, m_pImpl->GetStyleSheetTable());
-    }
 }
 /*-- 09.06.2006 09:52:14---------------------------------------------------
 



Mime
View raw message