summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorVitaliy Anderson <vanderson@smartru.com>2017-01-13 05:26:07 -0800
committerAron Budea <aron.budea@collabora.com>2018-03-14 21:19:23 +0100
commit6c86ae2fec7d2a1375a3e9683ea2155448990ce7 (patch)
tree8bb602c39ec7ccfca19caefbdb8f5d2369ed59a4 /sfx2
parent38d2aa02e8b617301f1a7db3831b73572d8b40bf (diff)
tdf#104349, tdf#104668 MS Word compatibility trailing blanks option
The commits: 1c1747ac13a9d895df0fcba2fbb1bd266dccd74b and 4a410dd147f7160c1d62e3e0b67388a178d5136c make trailing spaces and their highlighting compatible with the Ms Word. The option is enabled by default for imported MS Word formats: .doc, .docx, .rtf For the ODF files the option is disabled by default Also it allows saving and loading the option state to the ODF UserData. It may be manually set in Tools->Options->LibreOffice Writer->Compatibility Reviewed-on: https://gerrit.libreoffice.org/33046 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit 7fa20da88a4778bdf20d6ca0491fe97ae03ab554) Change-Id: I5a86359c52d18e50bbb54b9f37c79b672591c369
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/doc/objmisc.cxx7
1 files changed, 6 insertions, 1 deletions
diff --git a/sfx2/source/doc/objmisc.cxx b/sfx2/source/doc/objmisc.cxx
index 569a92f87939..59be71d84d2e 100644
--- a/sfx2/source/doc/objmisc.cxx
+++ b/sfx2/source/doc/objmisc.cxx
@@ -1128,6 +1128,12 @@ void SfxObjectShell::InitOwnModel_Impl()
void SfxObjectShell::FinishedLoading( SfxLoadedFlags nFlags )
{
+ std::shared_ptr<const SfxFilter> pFlt = pMedium->GetFilter();
+ if( pFlt )
+ {
+ SetFormatSpecificCompatibilityOptions( pFlt->GetTypeName() );
+ }
+
bool bSetModifiedTRUE = false;
const SfxStringItem* pSalvageItem = SfxItemSet::GetItem<SfxStringItem>(pMedium->GetItemSet(), SID_DOC_SALVAGE, false);
if( ( nFlags & SfxLoadedFlags::MAINDOCUMENT ) && !(pImpl->nLoadedFlags & SfxLoadedFlags::MAINDOCUMENT )
@@ -1216,7 +1222,6 @@ void SfxObjectShell::FinishedLoading( SfxLoadedFlags nFlags )
}
}
-
void SfxObjectShell::TemplateDisconnectionAfterLoad()
{
// document is created from a template