/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /* * This file is part of the LibreOffice project. * * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. * * This file incorporates work covered by the following license notice: * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed * with this work for additional information regarding copyright * ownership. The ASF licenses this file to you under the Apache * License, Version 2.0 (the "License"); you may not use this file * except in compliance with the License. You may obtain a copy of * the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/ #ifndef INCLUDED_SW_INC_NUMRULE_HXX #define INCLUDED_SW_INC_NUMRULE_HXX
class SwTextFormatColl; class IDocumentListsAccess; class SwNodeNum; namespace vcl { class Font; } class SfxGrabBagItem; class SwDoc; class SwTextNode; class SwWrtShell;
const sal_Unicode cBulletChar = 0x2022; ///< Character for lists.
class SW_DLLPUBLIC SwNumFormat final : public SvxNumberFormat, public SwClient
{
SwFormatVertOrient m_aVertOrient; //For i120928,record the cp info of graphic within bullet
sal_Unicode m_cGrfBulletCP;
SAL_DLLPRIVATE void UpdateNumNodes(SwDoc& rDoc);
using SvxNumberFormat::operator ==; using SvxNumberFormat::operator !=;
using SvxNumberFormat::SetCharFormatName; // this should return UIName but cannot because we are overriding code from include/editeng virtual OUString GetCharFormatName() const override;
//For i120928,access the cp info of graphic within bullet void SetGrfBulletCP(sal_Unicode cP){m_cGrfBulletCP = cP;}
sal_Unicode GetGrfBulletCP() const {return m_cGrfBulletCP;}
UIName msName;
SwNumRuleType meRuleType;
sal_uInt16 mnPoolFormatId; ///< Id-for NumRules created "automatically"
sal_uInt16 mnPoolHelpId; ///< HelpId for this Pool-style.
sal_uInt8 mnPoolHlpFileId; ///< FilePos at Doc on style helps. bool mbAutoRuleFlag : 1; bool mbInvalidRuleFlag : 1; bool mbContinusNum : 1; ///< Continuous numbering without levels. bool mbAbsSpaces : 1; ///< Levels represent absolute indents. bool mbHidden : 1; ///< Is the numbering rule to be hidden in the UI? bool mbCountPhantoms; bool mbUsedByRedline; /// it needs to export as part of tracked numbering change
/** A kind of copy-constructor to make sure the num formats are attached to the correctCharFormats of a document!!
(Copies the NumFormats and returns itself). */
SwNumRule& CopyNumRule( SwDoc&, const SwNumRule& );
/** Tests whether the CharFormats are from the given doc
and copies them if appropriate. */ void CheckCharFormats( SwDoc& rDoc );
/// change indent of all list levels by given difference void ChangeIndent( const sal_Int32 nDiff ); /// set indent of certain list level to given value void SetIndent( constshort nNewIndent, const sal_uInt16 nListLevel ); /** set indent of first list level to given value and change other list level's
indents accordingly */ void SetIndentOfFirstListLevelAndChangeOthers( constshort nNewIndent );
/// namespace for static functions and methods for numbering and bullets namespace numfunc
{ /** retrieve font family name used for the default bullet list characters */
OUString const & GetDefBulletFontname();
/** determine if default bullet font is user defined
The default bullet font is user defined, if it is given in the user configuration
*/ bool IsDefBulletFontUserDefined();
/** retrieve font used for the default bullet list characters */
SW_DLLPUBLIC const vcl::Font& GetDefBulletFont();
/** retrieve unicode of character used for the default bullet list for the given list level */
sal_Unicode GetBulletChar( sal_uInt8 nLevel );
/** configuration, if at first position of the first list item the <TAB>-key increased the indent of the complete list or only demotes this list item. The same for <SHIFT-TAB>-key at the same position for decreasing the indent of the complete list or only promotes this list item.
*/ bool ChangeIndentOnTabAtFirstPosOfFirstListItem();
/** * Decides if increasing ("downing") the numbering level will change the amount of indentation * or not. This is typically true, unless the numbering levels are invisible and have no * indents.
*/ bool NumDownChangesIndent(const SwWrtShell& rShell);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.