// The content has not to be removed, because the header // or footer is empty already.
bRemoveContent = false;
}
// If a header or footer is not shared, share it now.
aAny = xPropSet->getPropertyValue( sShareContent ); bool bShared = *o3tl::doAccess<bool>(aAny); if( !bShared )
{
xPropSet->setPropertyValue( sShareContent, Any(true) );
}
aAny = xPropSet->getPropertyValue( sText );
}
Reference < XText > xText;
aAny >>= xText;
if( bRemoveContent )
{
xText->setString(OUString()); // fdo#82165 shapes anchored at the beginning or end survive // setString("") - kill them the hard way: SwDoc::DelFullPara()
uno::Reference<text::XParagraphAppend> const xAppend(
xText, uno::UNO_QUERY_THROW);
uno::Reference<lang::XComponent> const xPara(
xAppend->finishParagraph(
uno::Sequence<beans::PropertyValue>()),
uno::UNO_QUERY_THROW);
xPara->dispose();
}
void XMLTextHeaderFooterContext::endFastElement(sal_Int32 )
{ if( xOldTextCursor.is() )
{
GetImport().GetTextImport()->DeleteParagraph();
GetImport().GetTextImport()->SetCursor( xOldTextCursor );
} elseif( !bLeft )
{ // If no content has been inserted into the header or footer, // switch it off.
xPropSet->setPropertyValue( sOn, Any(false) );
}
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.