LibreOffice Module sw (master)  1
IDocumentSettingAccess.hxx
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 
20 #ifndef INCLUDED_SW_INC_IDOCUMENTSETTINGACCESS_HXX
21 #define INCLUDED_SW_INC_IDOCUMENTSETTINGACCESS_HXX
22 
23 #include <sal/types.h>
24 #include "fldupde.hxx"
25 #include <i18nlangtag/lang.h>
26 #include <memory>
27 
29 namespace com::sun::star::i18n { struct ForbiddenCharacters; }
30 enum class CharCompressType;
31 
33 {
34  // COMPATIBILITY FLAGS START
37 
38  TAB_COMPAT,
39 
42 
44 
52  ALLOW_WRAP_WHEN_ANCHORED_IN_TABLE, // change LO to match MS allowing wrapping around fly-frames anchored in tables in header & footnote
54 
59 
64 
65  // tdf#104349 tdf#104668
67  // tdf#128197 MS Word in some modes can have line height based on shape height, not on font
72  // #i89181#
82  // MS Word still wraps text around objects with less space than LO would.
86  // tdf#112443 disable off-page content positioning
89  // COMPATIBILITY FLAGS END
91  HTML_MODE,
95  PURGE_OLE,
100  EMBED_FONTS,
112 };
113 
117  {
118  public:
128  virtual bool get(/*[in]*/ DocumentSettingId id) const = 0;
129 
139  virtual void set(/*[in]*/ DocumentSettingId id, /*[in]*/ bool value) = 0;
140 
153  virtual const css::i18n::ForbiddenCharacters*
154  getForbiddenCharacters(/*[in]*/ LanguageType nLang, /*[in]*/ bool bLocaleData ) const = 0;
155 
164  virtual void setForbiddenCharacters(/*[in]*/ LanguageType nLang,
165  /*[in]*/ const css::i18n::ForbiddenCharacters& rForbiddenCharacters ) = 0;
166 
172  virtual std::shared_ptr<SvxForbiddenCharactersTable>& getForbiddenCharacterTable() = 0;
173 
179  virtual const std::shared_ptr<SvxForbiddenCharactersTable>& getForbiddenCharacterTable() const = 0;
180 
190  virtual sal_uInt16 getLinkUpdateMode( /*[in]*/bool bGlobalSettings ) const = 0;
191 
197  virtual void setLinkUpdateMode( /*[in]*/ sal_uInt16 nMode ) = 0;
198 
208  virtual SwFieldUpdateFlags getFieldUpdateFlags( /*[in]*/bool bGlobalSettings ) const = 0;
209 
215  virtual void setFieldUpdateFlags( /*[in]*/ SwFieldUpdateFlags nMode ) = 0;
216 
222  virtual CharCompressType getCharacterCompressionType() const = 0;
223 
229  virtual void setCharacterCompressionType( /*[in]*/CharCompressType nType ) = 0;
230 
233  virtual sal_uInt32 Getn32DummyCompatibilityOptions1() const = 0;
234 
237  virtual void Setn32DummyCompatibilityOptions1( const sal_uInt32 CompatibilityOptions1 ) = 0;
238 
241  virtual sal_uInt32 Getn32DummyCompatibilityOptions2() const = 0;
242 
245  virtual void Setn32DummyCompatibilityOptions2( const sal_uInt32 CompatibilityOptions2 ) = 0;
246 
247 protected:
249  };
250 
251 #endif // INCLUDED_SW_INC_IDOCUMENTSETTINGACCESS_HXX
252 
253 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual std::shared_ptr< SvxForbiddenCharactersTable > & getForbiddenCharacterTable()=0
Get the forbidden character table and creates one if necessary.
virtual sal_uInt32 Getn32DummyCompatibilityOptions2() const =0
Get the n32DummyCompatabilityOptions2.
SwFieldUpdateFlags
Definition: fldupde.hxx:22
virtual const css::i18n::ForbiddenCharacters * getForbiddenCharacters(LanguageType nLang, bool bLocaleData) const =0
Return the forbidden characters.
virtual void setFieldUpdateFlags(SwFieldUpdateFlags nMode)=0
Set the current field update mode.
static LanguageType nLang
Definition: srtdlg.cxx:51
virtual void set(DocumentSettingId id, bool value)=0
Set the specified document setting.
virtual void setCharacterCompressionType(CharCompressType nType)=0
Set the character compression type for Asian characters.
virtual SwFieldUpdateFlags getFieldUpdateFlags(bool bGlobalSettings) const =0
Get the current field update mode.
virtual void Setn32DummyCompatibilityOptions1(const sal_uInt32 CompatibilityOptions1)=0
Set the n32DummyCompatabilityOptions1.
virtual CharCompressType getCharacterCompressionType() const =0
Get the character compression type for Asian characters.
CharCompressType
virtual sal_uInt16 getLinkUpdateMode(bool bGlobalSettings) const =0
Get the current link update mode.
Provides access to settings of a document.
virtual sal_uInt32 Getn32DummyCompatibilityOptions1() const =0
Get the n32DummyCompatabilityOptions1.
virtual void setForbiddenCharacters(LanguageType nLang, const css::i18n::ForbiddenCharacters &rForbiddenCharacters)=0
Set the forbidden characters.
virtual void setLinkUpdateMode(sal_uInt16 nMode)=0
Set the current link update mode.
QPRO_FUNC_TYPE nType
Any value
virtual void Setn32DummyCompatibilityOptions2(const sal_uInt32 CompatibilityOptions2)=0
Set the n32DummyCompatabilityOptions2.