LCOV - code coverage report
Current view: top level - sw/inc - IDocumentSettingAccess.hxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 2 2 100.0 %
Date: 2012-08-25 Functions: 2 3 66.7 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 1 2 50.0 %

           Branch data     Line data    Source code
       1                 :            : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2                 :            : /*************************************************************************
       3                 :            :  *
       4                 :            :  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
       5                 :            :  *
       6                 :            :  * Copyright 2000, 2010 Oracle and/or its affiliates.
       7                 :            :  *
       8                 :            :  * OpenOffice.org - a multi-platform office productivity suite
       9                 :            :  *
      10                 :            :  * This file is part of OpenOffice.org.
      11                 :            :  *
      12                 :            :  * OpenOffice.org is free software: you can redistribute it and/or modify
      13                 :            :  * it under the terms of the GNU Lesser General Public License version 3
      14                 :            :  * only, as published by the Free Software Foundation.
      15                 :            :  *
      16                 :            :  * OpenOffice.org is distributed in the hope that it will be useful,
      17                 :            :  * but WITHOUT ANY WARRANTY; without even the implied warranty of
      18                 :            :  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      19                 :            :  * GNU Lesser General Public License version 3 for more details
      20                 :            :  * (a copy is included in the LICENSE file that accompanied this code).
      21                 :            :  *
      22                 :            :  * You should have received a copy of the GNU Lesser General Public License
      23                 :            :  * version 3 along with OpenOffice.org.  If not, see
      24                 :            :  * <http://www.openoffice.org/license.html>
      25                 :            :  * for a copy of the LGPLv3 License.
      26                 :            :  *
      27                 :            :  ************************************************************************/
      28                 :            : 
      29                 :            : #ifndef IDOCUMENTSETTINGACCESS_HXX_INCLUDED
      30                 :            : #define IDOCUMENTSETTINGACCESS_HXX_INCLUDED
      31                 :            : 
      32                 :            : #include <tools/solar.h>
      33                 :            : #include <rtl/ref.hxx>
      34                 :            : #include <chcmprse.hxx>
      35                 :            : #include <fldupde.hxx>
      36                 :            : 
      37                 :            : class SvxForbiddenCharactersTable;
      38                 :            : namespace com { namespace sun { namespace star { namespace i18n { struct ForbiddenCharacters; } } } }
      39                 :            : 
      40                 :            :  /** Provides access to settings of a document
      41                 :            :  */
      42                 :       1549 :  class IDocumentSettingAccess
      43                 :            :  {
      44                 :            :  public:
      45                 :            :      enum DocumentSettingId
      46                 :            :      {
      47                 :            :          // COMPATIBILITY FLAGS START
      48                 :            :          PARA_SPACE_MAX,
      49                 :            :          PARA_SPACE_MAX_AT_PAGES,
      50                 :            : 
      51                 :            :          TAB_COMPAT,
      52                 :            : 
      53                 :            :          ADD_FLY_OFFSETS,
      54                 :            : 
      55                 :            :          OLD_NUMBERING,
      56                 :            : 
      57                 :            :          ADD_EXT_LEADING,
      58                 :            :          USE_VIRTUAL_DEVICE,
      59                 :            :          USE_HIRES_VIRTUAL_DEVICE,
      60                 :            :          OLD_LINE_SPACING,
      61                 :            :          ADD_PARA_SPACING_TO_TABLE_CELLS,
      62                 :            :          USE_FORMER_OBJECT_POS,
      63                 :            :          USE_FORMER_TEXT_WRAPPING,
      64                 :            :          CONSIDER_WRAP_ON_OBJECT_POSITION,
      65                 :            : 
      66                 :            :          IGNORE_FIRST_LINE_INDENT_IN_NUMBERING,
      67                 :            :          DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK,
      68                 :            :          DO_NOT_RESET_PARA_ATTRS_FOR_NUM_FONT,
      69                 :            :          OUTLINE_LEVEL_YIELDS_OUTLINE_RULE,
      70                 :            : 
      71                 :            :          DO_NOT_CAPTURE_DRAW_OBJS_ON_PAGE,
      72                 :            :          TABLE_ROW_KEEP,
      73                 :            :          IGNORE_TABS_AND_BLANKS_FOR_LINE_CALCULATION,
      74                 :            :          CLIP_AS_CHARACTER_ANCHORED_WRITER_FLY_FRAME,
      75                 :            : 
      76                 :            :          UNIX_FORCE_ZERO_EXT_LEADING,
      77                 :            :          USE_OLD_PRINTER_METRICS,
      78                 :            :          TABS_RELATIVE_TO_INDENT,
      79                 :            :          PROTECT_FORM,
      80                 :            :          // #i89181#
      81                 :            :          TAB_AT_LEFT_INDENT_FOR_PARA_IN_LIST,
      82                 :            :          INVERT_BORDER_SPACING,
      83                 :            :          COLLAPSE_EMPTY_CELL_PARA,
      84                 :            :          SMALL_CAPS_PERCENTAGE_66,
      85                 :            :          TAB_OVERFLOW,
      86                 :            :          UNBREAKABLE_NUMBERINGS,
      87                 :            :          // COMPATIBILITY FLAGS END
      88                 :            : 
      89                 :            :          BROWSE_MODE,
      90                 :            :          HTML_MODE,
      91                 :            :          GLOBAL_DOCUMENT,
      92                 :            :          GLOBAL_DOCUMENT_SAVE_LINKS,
      93                 :            :          LABEL_DOCUMENT,
      94                 :            :          PURGE_OLE,
      95                 :            :          KERN_ASIAN_PUNCTUATION,
      96                 :            :          MATH_BASELINE_ALIGNMENT,
      97                 :            :          STYLES_NODEFAULT,
      98                 :            :          FLOATTABLE_NOMARGINS
      99                 :            :      };
     100                 :            : 
     101                 :            :  public:
     102                 :            :     /** Return the specified document setting.
     103                 :            : 
     104                 :            :        @param id
     105                 :            :        [in] the identifier of the document setting to be returned.
     106                 :            :        See above for a list of valid document setting identifiers.
     107                 :            : 
     108                 :            :        @returns
     109                 :            :        the value of the requested document setting.
     110                 :            :     */
     111                 :            :     virtual bool get(/*[in]*/ DocumentSettingId id) const = 0;
     112                 :            : 
     113                 :            :     /** Set the specified document setting.
     114                 :            : 
     115                 :            :         @param id
     116                 :            :         [in] the identifier of the document setting to be set.
     117                 :            :         See above for a list of valid document setting identifiers.
     118                 :            : 
     119                 :            :         @param value
     120                 :            :         [in] the new value of the specified document setting.
     121                 :            :     */
     122                 :            :     virtual void set(/*[in]*/ DocumentSettingId id, /*[in]*/ bool value) = 0;
     123                 :            : 
     124                 :            :     /** Return the forbidden characters.
     125                 :            : 
     126                 :            :        @param nLang
     127                 :            :        [in] the language for which the forbidden character list is returned.
     128                 :            : 
     129                 :            :        @param bLocaleData
     130                 :            :        [in] if set and there is no user defined forbidden character list for
     131                 :            :             language lang, the default list for language lang will be returned.
     132                 :            : 
     133                 :            :        @returns
     134                 :            :        a list of forbidden characters.
     135                 :            :     */
     136                 :            :     virtual const com::sun::star::i18n::ForbiddenCharacters*
     137                 :            :         getForbiddenCharacters(/*[in]*/ sal_uInt16 nLang, /*[in]*/ bool bLocaleData ) const = 0;
     138                 :            : 
     139                 :            :     /** Set the forbidden characters.
     140                 :            : 
     141                 :            :        @param nLang
     142                 :            :        [in] the language for which the forbidden character list should be set.
     143                 :            : 
     144                 :            :        @param rForbiddenCharacters
     145                 :            :        [in] the new list of forbidden characters for language lang.
     146                 :            :     */
     147                 :            :     virtual void setForbiddenCharacters(/*[in]*/ sal_uInt16 nLang,
     148                 :            :                                         /*[in]*/ const com::sun::star::i18n::ForbiddenCharacters& rForbiddenCharacters ) = 0;
     149                 :            : 
     150                 :            :     /** Get the forbidden character table and creates one if necessary.
     151                 :            : 
     152                 :            :        @returns
     153                 :            :        the forbidden characters table.
     154                 :            :     */
     155                 :            :     virtual rtl::Reference<SvxForbiddenCharactersTable>& getForbiddenCharacterTable() = 0;
     156                 :            : 
     157                 :            :     /** Get the forbidden character table.
     158                 :            : 
     159                 :            :        @returns
     160                 :            :        the forbidden characters table.
     161                 :            :     */
     162                 :            :     virtual const rtl::Reference<SvxForbiddenCharactersTable>& getForbiddenCharacterTable() const = 0;
     163                 :            : 
     164                 :            :     /** Get the current link update mode.
     165                 :            : 
     166                 :            :        @param bGlobalSettings
     167                 :            :        [in] if set, the link update mode is obtained from the module,
     168                 :            :             if it is set to GLOBALSETTING
     169                 :            : 
     170                 :            :        @returns
     171                 :            :        the current link update mode.
     172                 :            :     */
     173                 :            :     virtual sal_uInt16 getLinkUpdateMode( /*[in]*/bool bGlobalSettings ) const = 0;
     174                 :            : 
     175                 :            :     /** Set the current link update mode.
     176                 :            : 
     177                 :            :        @param nMode
     178                 :            :        [in] the new link update mode.
     179                 :            :     */
     180                 :            :     virtual void setLinkUpdateMode( /*[in]*/ sal_uInt16 nMode ) = 0;
     181                 :            : 
     182                 :            :     /** Get the current field update mode.
     183                 :            : 
     184                 :            :        @param bGlobalSettings
     185                 :            :        [in] if set, the field update mode is obtained from the module,
     186                 :            :             if it is set to GLOBALSETTING
     187                 :            : 
     188                 :            :        @returns
     189                 :            :        the current field update mode.
     190                 :            :     */
     191                 :            :     virtual SwFldUpdateFlags getFieldUpdateFlags( /*[in]*/bool bGlobalSettings ) const = 0;
     192                 :            : 
     193                 :            :     /** Set the current field update mode.
     194                 :            : 
     195                 :            :        @param nMode
     196                 :            :        [in] the new field update mode.
     197                 :            :     */
     198                 :            :     virtual void setFieldUpdateFlags( /*[in]*/ SwFldUpdateFlags nMode )  = 0;
     199                 :            : 
     200                 :            :     /** Get the character compression type for Asian characters.
     201                 :            : 
     202                 :            :        @returns
     203                 :            :        the current character compression mode.
     204                 :            :     */
     205                 :            :     virtual SwCharCompressType getCharacterCompressionType() const = 0;
     206                 :            : 
     207                 :            :     /** Set the character compression type for Asian characters.
     208                 :            : 
     209                 :            :        @param nMode
     210                 :            :        [in] the new character compression type.
     211                 :            :     */
     212                 :            :     virtual void setCharacterCompressionType( /*[in]*/SwCharCompressType nType ) = 0;
     213                 :            : 
     214                 :            : protected:
     215         [ -  + ]:       1458 :     virtual ~IDocumentSettingAccess() {};
     216                 :            :  };
     217                 :            : 
     218                 :            : #endif // IDOCUMENTSETTINGACCESS_HXX_INCLUDED
     219                 :            : 
     220                 :            : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10