LibreOffice Module sw (master)  1
DocumentSettingManager.cxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8  *
9  * This file incorporates work covered by the following license notice:
10  *
11  * Licensed to the Apache Software Foundation (ASF) under one or more
12  * contributor license agreements. See the NOTICE file distributed
13  * with this work for additional information regarding copyright
14  * ownership. The ASF licenses this file to you under the Apache
15  * License, Version 2.0 (the "License"); you may not use this file
16  * except in compliance with the License. You may obtain a copy of
17  * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18  */
19 
21 #include <doc.hxx>
23 #include <IDocumentState.hxx>
27 #include <svx/svdmodel.hxx>
28 #include <svl/asiancfg.hxx>
30 #include <unotools/configmgr.hxx>
31 #include <drawdoc.hxx>
32 #include <swmodule.hxx>
33 #include <linkenum.hxx>
34 #include <rootfrm.hxx>
35 #include <breakit.hxx>
36 #include <docary.hxx>
37 #include <SwUndoFmt.hxx>
38 
39 /* IDocumentSettingAccess */
40 
42  :m_rDoc(rDoc),
43  mnLinkUpdMode( GLOBALSETTING ),
44  meFieldUpdMode( AUTOUPD_GLOBALSETTING ),
45  meChrCmprType( CharCompressType::NONE ),
46  mn32DummyCompatibilityOptions1(0),
47  mn32DummyCompatibilityOptions2(0),
48  mbHTMLMode(false),
49  mbIsGlobalDoc(false),
50  mbGlblDocSaveLinks(false),
51  mbIsLabelDoc(false),
52  mbPurgeOLE(true),
53  mbKernAsianPunctuation(false),
54 
55  // COMPATIBILITY FLAGS START
56 
57  mbAddFlyOffsets(false),
58  mbAddVerticalFlyOffsets(false),
59  mbUseHiResolutionVirtualDevice(true),
60  mbMathBaselineAlignment(false), // default for *old* documents is 'off'
61  mbStylesNoDefault(false),
62  mbFloattableNomargins(false),
63  mEmbedFonts(false),
64  mEmbedUsedFonts(false),
65  mEmbedLatinScriptFonts(true),
66  mEmbedAsianScriptFonts(true),
67  mEmbedComplexScriptFonts(true),
68  mEmbedSystemFonts(false),
69  mbOldNumbering(false),
70  mbIgnoreFirstLineIndentInNumbering(false),
71  mbDoNotResetParaAttrsForNumFont(false),
72  mbTableRowKeep(false),
73  mbIgnoreTabsAndBlanksForLineCalculation(false),
74  mbDoNotCaptureDrawObjsOnPage(false),
75  mbClipAsCharacterAnchoredWriterFlyFrames(false),
76  mbUnixForceZeroExtLeading(false),
77  mbTabRelativeToIndent(true),
78  mbProtectForm(false), // i#78591#
79  mbMsWordCompTrailingBlanks(false), // tdf#104349 tdf#104668
80  mbInvertBorderSpacing (false),
81  mbCollapseEmptyCellPara(true),
82  mbTabAtLeftIndentForParagraphsInList(false), //#i89181#
83  mbSmallCapsPercentage66(false),
84  mbTabOverflow(true),
85  mbUnbreakableNumberings(false),
86  mbClippedPictures(false),
87  mbBackgroundParaOverDrawings(false),
88  mbTabOverMargin(false),
89  mbTreatSingleColumnBreakAsPageBreak(false),
90  mbSurroundTextWrapSmall(false),
91  mbPropLineSpacingShrinksFirstLine(true),
92  mbSubtractFlys(false),
93  mApplyParagraphMarkFormatToNumbering(false),
94  mbLastBrowseMode( false ),
95  mbDisableOffPagePositioning ( false )
96 
97  // COMPATIBILITY FLAGS END
98 {
99  // COMPATIBILITY FLAGS START
100 
101  // Note: Any non-hidden compatibility flag should obtain its default
102  // by asking SvtCompatibilityOptions, see below.
103 
105  {
106  const SvtCompatibilityOptions aOptions;
123  }
124  else
125  {
126  mbParaSpaceMax = false;
127  mbParaSpaceMaxAtPages = false;
128  mbTabCompat = true;
129  mbUseVirtualDevice = true;
130  mbAddExternalLeading = true;
131  mbOldLineSpacing = false;
133  mbUseFormerObjectPos = false;
134  mbUseFormerTextWrapping = false;
135  mbConsiderWrapOnObjPos = false;
137  mbProtectForm = false;
139  mbSubtractFlys = false;
141  }
142 
143  // COMPATIBILITY FLAGS END
144 
145 }
146 
147 
149 {
150 }
151 
152 /* IDocumentSettingAccess */
154 {
155  switch (id)
156  {
157  // COMPATIBILITY FLAGS START
158  case DocumentSettingId::PARA_SPACE_MAX: return mbParaSpaceMax; //(n8Dummy1 & DUMMY_PARASPACEMAX);
159  case DocumentSettingId::PARA_SPACE_MAX_AT_PAGES: return mbParaSpaceMaxAtPages; //(n8Dummy1 & DUMMY_PARASPACEMAX_AT_PAGES);
160  case DocumentSettingId::TAB_COMPAT: return mbTabCompat; //(n8Dummy1 & DUMMY_TAB_COMPAT);
161  case DocumentSettingId::ADD_FLY_OFFSETS: return mbAddFlyOffsets; //(n8Dummy2 & DUMMY_ADD_FLY_OFFSETS);
162  case DocumentSettingId::ADD_VERTICAL_FLY_OFFSETS: return mbAddVerticalFlyOffsets;
163  case DocumentSettingId::ADD_EXT_LEADING: return mbAddExternalLeading; //(n8Dummy2 & DUMMY_ADD_EXTERNAL_LEADING);
164  case DocumentSettingId::USE_VIRTUAL_DEVICE: return mbUseVirtualDevice; //(n8Dummy1 & DUMMY_USE_VIRTUAL_DEVICE);
165  case DocumentSettingId::USE_HIRES_VIRTUAL_DEVICE: return mbUseHiResolutionVirtualDevice; //(n8Dummy2 & DUMMY_USE_HIRES_VIR_DEV);
166  case DocumentSettingId::OLD_NUMBERING: return mbOldNumbering;
167  case DocumentSettingId::OLD_LINE_SPACING: return mbOldLineSpacing;
168  case DocumentSettingId::ADD_PARA_SPACING_TO_TABLE_CELLS: return mbAddParaSpacingToTableCells;
169  case DocumentSettingId::USE_FORMER_OBJECT_POS: return mbUseFormerObjectPos;
170  case DocumentSettingId::USE_FORMER_TEXT_WRAPPING: return mbUseFormerTextWrapping;
171  case DocumentSettingId::CONSIDER_WRAP_ON_OBJECT_POSITION: return mbConsiderWrapOnObjPos;
172  case DocumentSettingId::DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK: return mbDoNotJustifyLinesWithManualBreak;
173  case DocumentSettingId::IGNORE_FIRST_LINE_INDENT_IN_NUMBERING: return mbIgnoreFirstLineIndentInNumbering;
174  case DocumentSettingId::TABLE_ROW_KEEP: return mbTableRowKeep;
175  case DocumentSettingId::IGNORE_TABS_AND_BLANKS_FOR_LINE_CALCULATION: return mbIgnoreTabsAndBlanksForLineCalculation;
176  case DocumentSettingId::DO_NOT_CAPTURE_DRAW_OBJS_ON_PAGE: return mbDoNotCaptureDrawObjsOnPage;
177  // #i68949#
178  case DocumentSettingId::CLIP_AS_CHARACTER_ANCHORED_WRITER_FLY_FRAME: return mbClipAsCharacterAnchoredWriterFlyFrames;
179  case DocumentSettingId::UNIX_FORCE_ZERO_EXT_LEADING: return mbUnixForceZeroExtLeading;
180  case DocumentSettingId::TABS_RELATIVE_TO_INDENT : return mbTabRelativeToIndent;
181  case DocumentSettingId::PROTECT_FORM: return mbProtectForm;
182  // tdf#104349 tdf#104668
183  case DocumentSettingId::MS_WORD_COMP_TRAILING_BLANKS: return mbMsWordCompTrailingBlanks;
184  // #i89181#
185  case DocumentSettingId::TAB_AT_LEFT_INDENT_FOR_PARA_IN_LIST: return mbTabAtLeftIndentForParagraphsInList;
186  case DocumentSettingId::INVERT_BORDER_SPACING: return mbInvertBorderSpacing;
187  case DocumentSettingId::COLLAPSE_EMPTY_CELL_PARA: return mbCollapseEmptyCellPara;
188  case DocumentSettingId::SMALL_CAPS_PERCENTAGE_66: return mbSmallCapsPercentage66;
189  case DocumentSettingId::TAB_OVERFLOW: return mbTabOverflow;
190  case DocumentSettingId::UNBREAKABLE_NUMBERINGS: return mbUnbreakableNumberings;
191  case DocumentSettingId::CLIPPED_PICTURES: return mbClippedPictures;
192  case DocumentSettingId::BACKGROUND_PARA_OVER_DRAWINGS: return mbBackgroundParaOverDrawings;
193  case DocumentSettingId::TAB_OVER_MARGIN: return mbTabOverMargin;
194  case DocumentSettingId::TREAT_SINGLE_COLUMN_BREAK_AS_PAGE_BREAK: return mbTreatSingleColumnBreakAsPageBreak;
195  case DocumentSettingId::SURROUND_TEXT_WRAP_SMALL: return mbSurroundTextWrapSmall;
196  case DocumentSettingId::PROP_LINE_SPACING_SHRINKS_FIRST_LINE: return mbPropLineSpacingShrinksFirstLine;
197  case DocumentSettingId::SUBTRACT_FLYS: return mbSubtractFlys;
198 
199  case DocumentSettingId::BROWSE_MODE: return mbLastBrowseMode; // Attention: normally the SwViewShell has to be asked!
200  case DocumentSettingId::HTML_MODE: return mbHTMLMode;
201  case DocumentSettingId::GLOBAL_DOCUMENT: return mbIsGlobalDoc;
202  case DocumentSettingId::GLOBAL_DOCUMENT_SAVE_LINKS: return mbGlblDocSaveLinks;
203  case DocumentSettingId::LABEL_DOCUMENT: return mbIsLabelDoc;
204  case DocumentSettingId::PURGE_OLE: return mbPurgeOLE;
205  case DocumentSettingId::KERN_ASIAN_PUNCTUATION: return mbKernAsianPunctuation;
206  case DocumentSettingId::DO_NOT_RESET_PARA_ATTRS_FOR_NUM_FONT: return mbDoNotResetParaAttrsForNumFont;
207  case DocumentSettingId::MATH_BASELINE_ALIGNMENT: return mbMathBaselineAlignment;
208  case DocumentSettingId::STYLES_NODEFAULT: return mbStylesNoDefault;
209  case DocumentSettingId::FLOATTABLE_NOMARGINS: return mbFloattableNomargins;
210  case DocumentSettingId::EMBED_FONTS: return mEmbedFonts;
211  case DocumentSettingId::EMBED_USED_FONTS: return mEmbedUsedFonts;
212  case DocumentSettingId::EMBED_LATIN_SCRIPT_FONTS: return mEmbedLatinScriptFonts;
213  case DocumentSettingId::EMBED_ASIAN_SCRIPT_FONTS: return mEmbedAsianScriptFonts;
214  case DocumentSettingId::EMBED_COMPLEX_SCRIPT_FONTS: return mEmbedComplexScriptFonts;
215  case DocumentSettingId::EMBED_SYSTEM_FONTS: return mEmbedSystemFonts;
216  case DocumentSettingId::APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING: return mApplyParagraphMarkFormatToNumbering;
217  case DocumentSettingId::DISABLE_OFF_PAGE_POSITIONING: return mbDisableOffPagePositioning;
218  case DocumentSettingId::EMPTY_DB_FIELD_HIDES_PARA: return mbEmptyDbFieldHidesPara;
219  default:
220  OSL_FAIL("Invalid setting id");
221  }
222  return false;
223 }
224 
225 void sw::DocumentSettingManager::set(/*[in]*/ DocumentSettingId id, /*[in]*/ bool value)
226 {
227  switch (id)
228  {
229  // COMPATIBILITY FLAGS START
231  mbParaSpaceMax = value;
232  break;
234  mbParaSpaceMaxAtPages = value;
235  break;
237  mbTabCompat = value;
238  break;
240  mbAddFlyOffsets = value;
241  break;
243  mbAddVerticalFlyOffsets = value;
244  break;
246  mbAddExternalLeading = value;
247  break;
249  mbUseVirtualDevice = value;
250  break;
252  mbUseHiResolutionVirtualDevice = value;
253  break;
255  if (mbOldNumbering != value)
256  {
257  mbOldNumbering = value;
258 
259  const SwNumRuleTable& rNmTable = m_rDoc.GetNumRuleTable();
260  for( SwNumRuleTable::size_type n = 0; n < rNmTable.size(); ++n )
261  rNmTable[n]->SetInvalidRule(true);
262 
263  m_rDoc.UpdateNumRule();
264 
265  SwNumRule *pOutlineRule = m_rDoc.GetOutlineNumRule();
266  if (pOutlineRule)
267  {
268  pOutlineRule->Validate();
269  // counting of phantoms depends on <IsOldNumbering()>
270  pOutlineRule->SetCountPhantoms( !mbOldNumbering );
271  }
272  }
273  break;
275  mbOldLineSpacing = value;
276  break;
278  mbAddParaSpacingToTableCells = value;
279  break;
281  mbUseFormerObjectPos = value;
282  break;
284  mbUseFormerTextWrapping = value;
285  break;
287  mbConsiderWrapOnObjPos = value;
288  break;
290  mbDoNotJustifyLinesWithManualBreak = value;
291  break;
293  mbIgnoreFirstLineIndentInNumbering = value;
294  break;
295 
297  mbTableRowKeep = value;
298  break;
299 
301  mbIgnoreTabsAndBlanksForLineCalculation = value;
302  break;
303 
305  mbDoNotCaptureDrawObjsOnPage = value;
306  break;
307 
308  // #i68949#
310  mbClipAsCharacterAnchoredWriterFlyFrames = value;
311  break;
312 
314  mbUnixForceZeroExtLeading = value;
315  break;
316 
318  mbProtectForm = value;
319  break;
320 
321  // tdf#140349
323  mbMsWordCompTrailingBlanks = value;
324  break;
325 
327  mbTabRelativeToIndent = value;
328  break;
329  // #i89181#
331  mbTabAtLeftIndentForParagraphsInList = value;
332  break;
333 
335  mbInvertBorderSpacing = value;
336  break;
337 
339  mbCollapseEmptyCellPara = value;
340  break;
341 
343  mbSmallCapsPercentage66 = value;
344  break;
345 
347  mbTabOverflow = value;
348  break;
349 
351  mbUnbreakableNumberings = value;
352  break;
353 
355  mbClippedPictures = value;
356  break;
357 
359  mbBackgroundParaOverDrawings = value;
360  break;
361 
363  mbTabOverMargin = value;
364  break;
365 
367  mbTreatSingleColumnBreakAsPageBreak = value;
368  break;
369 
371  mbSurroundTextWrapSmall = value;
372  break;
373 
375  mbPropLineSpacingShrinksFirstLine = value;
376  break;
377 
379  mbSubtractFlys = value;
380  break;
381 
382  // COMPATIBILITY FLAGS END
383 
384  case DocumentSettingId::BROWSE_MODE: //can be used temporary (load/save) when no SwViewShell is available
385  mbLastBrowseMode = value;
386  break;
387 
389  mbHTMLMode = value;
390  break;
391 
393  mbIsGlobalDoc = value;
394  break;
395 
397  mbGlblDocSaveLinks = value;
398  break;
399 
401  mbIsLabelDoc = value;
402  break;
403 
405  mbPurgeOLE = value;
406  break;
407 
409  mbKernAsianPunctuation = value;
410  break;
411 
413  mbDoNotResetParaAttrsForNumFont = value;
414  break;
416  mbMathBaselineAlignment = value;
417  break;
419  mbStylesNoDefault = value;
420  break;
422  mbFloattableNomargins = value;
423  break;
425  mEmbedFonts = value;
426  break;
428  mEmbedUsedFonts = value;
429  break;
431  mEmbedLatinScriptFonts = value;
432  break;
434  mEmbedAsianScriptFonts = value;
435  break;
437  mEmbedComplexScriptFonts = value;
438  break;
440  mEmbedSystemFonts = value;
441  break;
443  mApplyParagraphMarkFormatToNumbering = value;
444  break;
446  mbDisableOffPagePositioning = value;
447  break;
449  mbEmptyDbFieldHidesPara = value;
450  break;
451  default:
452  OSL_FAIL("Invalid setting id");
453  }
454 }
455 
456 const css::i18n::ForbiddenCharacters*
457  sw::DocumentSettingManager::getForbiddenCharacters(/*[in]*/ LanguageType nLang, /*[in]*/ bool bLocaleData ) const
458 {
459  const css::i18n::ForbiddenCharacters* pRet = nullptr;
460  if (mxForbiddenCharsTable)
461  pRet = mxForbiddenCharsTable->GetForbiddenCharacters( nLang, false );
462  if( bLocaleData && !pRet && g_pBreakIt )
463  pRet = &g_pBreakIt->GetForbidden( nLang );
464  return pRet;
465 }
466 
468  /*[in]*/ const css::i18n::ForbiddenCharacters& rFChars )
469 {
470  if (!mxForbiddenCharsTable)
472  mxForbiddenCharsTable->SetForbiddenCharacters( nLang, rFChars );
473 
474  SdrModel *pDrawModel = m_rDoc.getIDocumentDrawModelAccess().GetDrawModel();
475  if( pDrawModel )
476  {
477  pDrawModel->SetForbiddenCharsTable(mxForbiddenCharsTable);
478  if( !m_rDoc.IsInReading() )
479  pDrawModel->ReformatAllTextObjects();
480  }
481 
482  SwRootFrame* pTmpRoot = m_rDoc.getIDocumentLayoutAccess().GetCurrentLayout();
483  if( pTmpRoot && !m_rDoc.IsInReading() )
484  {
485  pTmpRoot->StartAllAction();
486  for(SwRootFrame* aLayout : m_rDoc.GetAllLayouts())
487  aLayout->InvalidateAllContent(SwInvalidateFlags::Size);
488  pTmpRoot->EndAllAction();
489  }
490  m_rDoc.getIDocumentState().SetModified();
491 }
492 
493 std::shared_ptr<SvxForbiddenCharactersTable>& sw::DocumentSettingManager::getForbiddenCharacterTable()
494 {
495  if (!mxForbiddenCharsTable)
497  return mxForbiddenCharsTable;
498 }
499 
500 const std::shared_ptr<SvxForbiddenCharactersTable>& sw::DocumentSettingManager::getForbiddenCharacterTable() const
501 {
502  return mxForbiddenCharsTable;
503 }
504 
505 sal_uInt16 sw::DocumentSettingManager::getLinkUpdateMode( /*[in]*/bool bGlobalSettings ) const
506 {
507  sal_uInt16 nRet = mnLinkUpdMode;
508  if( bGlobalSettings && GLOBALSETTING == nRet )
509  nRet = SW_MOD()->GetLinkUpdMode();
510  return nRet;
511 }
512 
513 void sw::DocumentSettingManager::setLinkUpdateMode( /*[in]*/sal_uInt16 eMode )
514 {
515  mnLinkUpdMode = eMode;
516 }
517 
519 {
520  SwFieldUpdateFlags eRet = meFieldUpdMode;
521  if( bGlobalSettings && AUTOUPD_GLOBALSETTING == eRet )
522  eRet = SW_MOD()->GetFieldUpdateFlags();
523  return eRet;
524 }
525 
527 {
528  meFieldUpdMode = eMode;
529 }
530 
532 {
533  return meChrCmprType;
534 }
535 
537 {
538  if( meChrCmprType != n )
539  {
540  meChrCmprType = n;
541 
542  SdrModel *pDrawModel = m_rDoc.getIDocumentDrawModelAccess().GetDrawModel();
543  if( pDrawModel )
544  {
545  pDrawModel->SetCharCompressType( n );
546  if( !m_rDoc.IsInReading() )
547  pDrawModel->ReformatAllTextObjects();
548  }
549 
550  SwRootFrame* pTmpRoot = m_rDoc.getIDocumentLayoutAccess().GetCurrentLayout();
551  if( pTmpRoot && !m_rDoc.IsInReading() )
552  {
553  pTmpRoot->StartAllAction();
554  for( auto aLayout : m_rDoc.GetAllLayouts() )
555  aLayout->InvalidateAllContent(SwInvalidateFlags::Size);
556  pTmpRoot->EndAllAction();
557  }
558  m_rDoc.getIDocumentState().SetModified();
559  }
560 }
561 
562 
564 {
565  Setn32DummyCompatibilityOptions1( rSource.Getn32DummyCompatibilityOptions1() );
566  Setn32DummyCompatibilityOptions2( rSource.Getn32DummyCompatibilityOptions2() );
567 
568  mbParaSpaceMax = rSource.mbParaSpaceMax;
569  mbParaSpaceMaxAtPages = rSource.mbParaSpaceMaxAtPages;
570  mbTabCompat = rSource.mbTabCompat;
571  mbUseVirtualDevice = rSource.mbUseVirtualDevice;
572  mbAddExternalLeading = rSource.mbAddExternalLeading;
573  mbOldLineSpacing = rSource.mbOldLineSpacing;
574  mbAddParaSpacingToTableCells = rSource.mbAddParaSpacingToTableCells;
575  mbUseFormerObjectPos = rSource.mbUseFormerObjectPos;
576  mbUseFormerTextWrapping = rSource.mbUseFormerTextWrapping;
577  mbConsiderWrapOnObjPos = rSource.mbConsiderWrapOnObjPos;
578  mbAddFlyOffsets = rSource.mbAddFlyOffsets;
579  mbOldNumbering = rSource.mbOldNumbering;
580  mbUseHiResolutionVirtualDevice = rSource.mbUseHiResolutionVirtualDevice;
581  mbIgnoreFirstLineIndentInNumbering = rSource.mbIgnoreFirstLineIndentInNumbering;
582  mbDoNotJustifyLinesWithManualBreak = rSource.mbDoNotJustifyLinesWithManualBreak;
583  mbDoNotResetParaAttrsForNumFont = rSource.mbDoNotResetParaAttrsForNumFont;
584  mbTableRowKeep = rSource.mbTableRowKeep;
585  mbIgnoreTabsAndBlanksForLineCalculation = rSource.mbIgnoreTabsAndBlanksForLineCalculation;
586  mbDoNotCaptureDrawObjsOnPage = rSource.mbDoNotCaptureDrawObjsOnPage;
587  mbClipAsCharacterAnchoredWriterFlyFrames = rSource.mbClipAsCharacterAnchoredWriterFlyFrames;
588  mbUnixForceZeroExtLeading = rSource.mbUnixForceZeroExtLeading;
589  mbTabRelativeToIndent = rSource.mbTabRelativeToIndent;
590  mbTabAtLeftIndentForParagraphsInList = rSource.mbTabAtLeftIndentForParagraphsInList;
591  mbMsWordCompTrailingBlanks = rSource.mbMsWordCompTrailingBlanks;
592  mbEmptyDbFieldHidesPara = rSource.mbEmptyDbFieldHidesPara;
593 }
594 
596 {
597  return mn32DummyCompatibilityOptions1;
598 }
599 
600 void sw::DocumentSettingManager::Setn32DummyCompatibilityOptions1( const sal_uInt32 CompatibilityOptions1 )
601 {
602  mn32DummyCompatibilityOptions1 = CompatibilityOptions1;
603 }
604 
606 {
607  return mn32DummyCompatibilityOptions2;
608 }
609 
610 void sw::DocumentSettingManager::Setn32DummyCompatibilityOptions2( const sal_uInt32 CompatibilityOptions2 )
611 {
612  mn32DummyCompatibilityOptions2 = CompatibilityOptions2;
613 }
614 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual const css::i18n::ForbiddenCharacters * getForbiddenCharacters(LanguageType nLang, bool bLocaleData) const override
Return the forbidden characters.
bool GetDefault(SvtCompatibilityEntry::Index rIdx) const
SwFieldUpdateFlags
Definition: fldupde.hxx:22
virtual bool get(DocumentSettingId id) const override
Return the specified document setting.
void SetForbiddenCharsTable(const std::shared_ptr< SvxForbiddenCharactersTable > &xForbiddenChars)
Definition: doc.hxx:185
virtual CharCompressType getCharacterCompressionType() const override
Get the character compression type for Asian characters.
virtual void set(DocumentSettingId id, bool value) override
Set the specified document setting.
void SetCharCompressType(CharCompressType nType)
void Setn32DummyCompatibilityOptions1(const sal_uInt32 CompatibilityOptions1) override
Set the n32DummyCompatabilityOptions1.
The root element of a Writer document layout.
Definition: rootfrm.hxx:79
static LanguageType nLang
Definition: srtdlg.cxx:58
void ReformatAllTextObjects()
SwBreakIt * g_pBreakIt
Definition: breakit.cxx:34
static bool IsFuzzing()
static std::shared_ptr< SvxForbiddenCharactersTable > makeForbiddenCharactersTable(const css::uno::Reference< css::uno::XComponentContext > &rxContext)
virtual void setLinkUpdateMode(sal_uInt16 nMode) override
Set the current link update mode.
void ReplaceCompatibilityOptions(const DocumentSettingManager &rSource)
virtual void setFieldUpdateFlags(SwFieldUpdateFlags eMode) override
Set the current field update mode.
#define SW_MOD()
Definition: swmodule.hxx:255
CharCompressType
std::vector< SwNumRule * >::size_type size_type
Definition: docary.hxx:70
virtual std::shared_ptr< SvxForbiddenCharactersTable > & getForbiddenCharacterTable() override
Get the forbidden character table and creates one if necessary.
void Setn32DummyCompatibilityOptions2(const sal_uInt32 CompatibilityOptions2) override
Set the n32DummyCompatabilityOptions2.
size_t size() const
Definition: docary.hxx:91
void SetCountPhantoms(bool bCountPhantoms)
Definition: number.cxx:989
virtual void setCharacterCompressionType(CharCompressType nType) override
Set the character compression type for Asian characters.
sal_uInt32 Getn32DummyCompatibilityOptions2() const override
Get the n32DummyCompatabilityOptions2.
void Validate()
Definition: number.cxx:976
virtual SwFieldUpdateFlags getFieldUpdateFlags(bool bGlobalSettings) const override
Get the current field update mode.
virtual void setForbiddenCharacters(LanguageType nLang, const css::i18n::ForbiddenCharacters &rForbiddenCharacters) override
Set the forbidden characters.
virtual sal_uInt16 getLinkUpdateMode(bool bGlobalSettings) const override
Get the current link update mode.
sal_uInt32 Getn32DummyCompatibilityOptions1() const override
Get the n32DummyCompatabilityOptions1.
Reference< XComponentContext > getProcessComponentContext()
virtual ~DocumentSettingManager() override
void StartAllAction()
Set up Start-/EndAction for all Shells on a as high as possible (Shell section) level.
Definition: pagechg.cxx:1866
void EndAllAction(bool bVirDev=false)
Definition: pagechg.cxx:1878
const css::i18n::ForbiddenCharacters & GetForbidden(const LanguageType aLang)
Definition: breakit.hxx:103