Kaydet (Commit) 8d65149d authored tarafından Oliver Specht's avatar Oliver Specht

tdf#94386 set page style at page breaks behind evelopes

insert page descriptor attribute instead of simple break after envelope page
to enable .docx roundtrip

Change-Id: I05d45daa3043d42df22509faafcfc4dcb2ec8946
Reviewed-on: https://gerrit.libreoffice.org/19146Reviewed-by: 's avatarOliver Specht <oliver.specht@cib.de>
Tested-by: 's avatarOliver Specht <oliver.specht@cib.de>
üst c501c654
......@@ -59,6 +59,7 @@
#include <expfld.hxx>
#include <SwStyleNameMapper.hxx>
#include <crsskip.hxx>
#include <fmtpdsc.hxx>
#include <cmdid.h>
#include <globals.hrc>
......@@ -302,12 +303,15 @@ void SwModule::InsertEnv( SfxRequest& rReq )
{
pSh->SplitNode();
pSh->Right( CRSR_SKIP_CHARS, false, 1, false );
SfxItemSet aBreakSet( pSh->GetAttrPool(), RES_BREAK, RES_BREAK, 0 );
aBreakSet.Put( SvxFormatBreakItem(SVX_BREAK_PAGE_BEFORE, RES_BREAK) );
SfxItemSet aBreakSet( pSh->GetAttrPool(), RES_PAGEDESC, RES_PAGEDESC, 0 );
aBreakSet.Put( SwFormatPageDesc( pFollow ) );
pSh->SetTableAttr( aBreakSet );
}
else
pSh->InsertPageBreak(0, boost::none);
{
OUString sFollowName(pFollow->GetName());
pSh->InsertPageBreak(&sFollowName, boost::none);
}
pSh->SttEndDoc(true);
}
else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment