This is an automated email from the ASF dual-hosted git repository.

jimjag pushed a commit to branch AOO50X
in repository https://gitbox.apache.org/repos/asf/openoffice.git

commit 93e78662e06a907cea7116366cabca547139b223
Author: Jim Jagielski <[email protected]>
AuthorDate: Wed Nov 4 05:13:23 2026 -0500

    xmloff: require the HeaderFill or FooterFill name when routing header and 
footer fills
---
 main/xmloff/source/style/xmlexppr.cxx | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/main/xmloff/source/style/xmlexppr.cxx 
b/main/xmloff/source/style/xmlexppr.cxx
index 0da2be6337..3a7c76dd29 100644
--- a/main/xmloff/source/style/xmlexppr.cxx
+++ b/main/xmloff/source/style/xmlexppr.cxx
@@ -95,7 +95,10 @@ static  XMLPropTokens_Impl aPropTokens[MAX_PROP_TYPES] =
 // The drawing-layer fill entries of header and footer; ODF 1.4 writes them in 
a style:background-fill child.
 static sal_Bool lcl_IsHeaderFooterFill( const UniReference< 
XMLPropertySetMapper >& rMapper, sal_Int32 nIdx )
 {
+       const OUString& rName = rMapper->GetEntryAPIName( nIdx );
        return ( rMapper->GetEntryFlags( nIdx ) & XML_TYPE_PROP_MASK ) == 
XML_TYPE_PROP_HEADER_FOOTER &&
+               ( rName.matchAsciiL( RTL_CONSTASCII_STRINGPARAM( "HeaderFill" ) 
) ||
+                 rName.matchAsciiL( RTL_CONSTASCII_STRINGPARAM( "FooterFill" ) 
) ) &&
                ( rMapper->GetEntryNameSpace( nIdx ) == XML_NAMESPACE_DRAW ||
                  ( rMapper->GetEntryNameSpace( nIdx ) == XML_NAMESPACE_STYLE &&
                        IsXMLToken( rMapper->GetEntryXMLName( nIdx ), 
XML_REPEAT ) ) );

Reply via email to