[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sw/source

Boris Dušek me at dusek.me
Tue Aug 20 06:38:10 PDT 2013


 sw/source/core/access/accpara.cxx |   10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

New commits:
commit e5c7249382c12349e4e032c225c0153f6f41cccc
Author: Boris Dušek <me at dusek.me>
Date:   Sat Aug 17 17:23:40 2013 +0200

    fdo#68219: Parent style text attributes missing in accessibility
    
    Thanks to Niklas Johansson for testing.
    
    Change-Id: I550076e7d62f8db389cdbf902fce0ff7f8f98165
    Reviewed-on: https://gerrit.libreoffice.org/5499
    Reviewed-by: Tor Lillqvist <tml at iki.fi>
    Tested-by: Tor Lillqvist <tml at iki.fi>

diff --git a/sw/source/core/access/accpara.cxx b/sw/source/core/access/accpara.cxx
index 3b6ef33..34d9dbd 100644
--- a/sw/source/core/access/accpara.cxx
+++ b/sw/source/core/access/accpara.cxx
@@ -1197,6 +1197,14 @@ uno::Sequence<PropertyValue> SwAccessibleParagraph::getCharacterAttributes(
     return aValues;
 }
 
+static void SetPutRecursive(SfxItemSet &targetSet, const SfxItemSet &sourceSet)
+{
+    const SfxItemSet *const pParentSet = sourceSet.GetParent();
+    if (pParentSet)
+        SetPutRecursive(targetSet, *pParentSet);
+    targetSet.Put(sourceSet);
+}
+
 // #i63870#
 void SwAccessibleParagraph::_getDefaultAttributesImpl(
         const uno::Sequence< OUString >& aRequestedAttributes,
@@ -1243,7 +1251,7 @@ void SwAccessibleParagraph::_getDefaultAttributesImpl(
         SfxItemSet aCharSet( const_cast<SwAttrPool&>(pTxtNode->GetDoc()->GetAttrPool()),
                              RES_CHRATR_BEGIN, RES_CHRATR_END - 1,
                              0 );
-        aCharSet.Put( pTxtNode->GetTxtColl()->GetAttrSet() );
+        SetPutRecursive( aCharSet, pTxtNode->GetTxtColl()->GetAttrSet() );
         pSet->Put( aCharSet );
     }
 


More information about the Libreoffice-commits mailing list