/* -*- 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_FORMAT_HXX #define INCLUDED_SW_INC_FORMAT_HXX
class IDocumentSettingAccess; class IDocumentDrawModelAccess; class IDocumentLayoutAccess; class IDocumentTimerAccess; class IDocumentFieldsAccess; class IDocumentChartDataProviderAccess; class SwDoc; class SfxGrabBagItem; class SwTextGridItem;
/// Base class for various Writer styles. class SW_DLLPUBLIC SwFormat : public sw::BorderCacheOwner, public sw::BroadcastingModify
{ friendclass SwFrameFormat;
UIName m_aFormatName;
SwAttrSet m_aSet;
sal_uInt16 m_nWhichId;
sal_uInt16 m_nPoolFormatId; /**< Id for "automatically" created formats.
(is not hard attribution!!!) */
sal_uInt32 m_nPoolHelpId; ///< HelpId for this Pool-style.
sal_uInt8 m_nPoolHlpFileId; ///< FilePos to Doc to these style helps. bool m_bAutoFormat : 1; /**< FALSE: it is a template.
default is true! */ bool m_bFormatInDTOR : 1; /**< TRUE: Format becomes deleted. In order to be able
to recognize this in FormatChg-message!! */ bool m_bAutoUpdateOnDirectFormat : 1;/**< TRUE: Set attributes of a whole paragraph
at format (UI-side!). */ bool m_bHidden : 1;
std::shared_ptr<SfxGrabBagItem> m_pGrabBagItem; ///< Style InteropGrabBag. virtualvoid InvalidateInSwFntCache(sal_uInt16) {}; virtualvoid InvalidateInSwFntCache() {};
/// For querying the attribute array. const SwAttrSet& GetAttrSet() const { return m_aSet; }
/** The document is set in SwAttrPool now, therefore you always can access it. */ const SwDoc &GetDoc() const { return m_aSet.GetDoc(); }
SwDoc &GetDoc() { return m_aSet.GetDoc(); }
/// Provides access to the document settings interface. const IDocumentSettingAccess& getIDocumentSettingAccess() const;
/// Provides access to the document draw model interface. const IDocumentDrawModelAccess& getIDocumentDrawModelAccess() const;
IDocumentDrawModelAccess& getIDocumentDrawModelAccess();
/// Provides access to the document layout interface. const IDocumentLayoutAccess& getIDocumentLayoutAccess() const;
IDocumentLayoutAccess& getIDocumentLayoutAccess();
/// Provides access to the document idle timer interface.
IDocumentTimerAccess& getIDocumentTimerAccess();
/// Provides access to the document idle timer interface.
IDocumentFieldsAccess& getIDocumentFieldsAccess();
/// Gives access to the chart data-provider.
IDocumentChartDataProviderAccess& getIDocumentChartDataProviderAccess();
/// Get and set Pool style IDs.
sal_uInt16 GetPoolFormatId() const { return m_nPoolFormatId; } void SetPoolFormatId( sal_uInt16 nId ) { m_nPoolFormatId = nId; }
/// Get and set Help-IDs for document templates.
sal_uInt32 GetPoolHelpId() const { return m_nPoolHelpId; } void SetPoolHelpId( sal_uInt32 nId ) { m_nPoolHelpId = nId; }
sal_uInt8 GetPoolHlpFileId() const { return m_nPoolHlpFileId; } void SetPoolHlpFileId( sal_uInt8 nId ) { m_nPoolHlpFileId = nId; }
Virtual method to determine, if background of format is transparent. Default implementation returns false. Thus, subclasses have to override method, if the specific subclass can have a transparent background.
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.