LibreOffice Module sw (master) 1
DocumentLayoutManager.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_SOURCE_CORE_INC_DOCUMENTLAYOUTMANAGER_HXX
21#define INCLUDED_SW_SOURCE_CORE_INC_DOCUMENTLAYOUTMANAGER_HXX
22
24#include <memory>
25
26class SwDoc;
27class SwViewShell;
28class SwLayouter;
29
30namespace sw {
31
33{
34
35public:
36
37 DocumentLayoutManager( SwDoc& i_rSwdoc );
38
39 virtual const SwViewShell *GetCurrentViewShell() const override;
40 virtual SwViewShell *GetCurrentViewShell() override; //< It must be able to communicate to a SwViewShell.This is going to be removed later.
41 virtual void SetCurrentViewShell( SwViewShell* pNew ) override;
42
43 virtual const SwRootFrame *GetCurrentLayout() const override;
44 virtual SwRootFrame *GetCurrentLayout() override;
45 virtual bool HasLayout() const override;
46
47 virtual const SwLayouter* GetLayouter() const override;
48 virtual SwLayouter* GetLayouter() override;
49 virtual void SetLayouter( SwLayouter* pNew ) override;
50
51 virtual SwFrameFormat* MakeLayoutFormat( RndStdIds eRequest, const SfxItemSet* pSet ) override;
52 virtual void DelLayoutFormat( SwFrameFormat *pFormat ) override;
53 virtual SwFrameFormat* CopyLayoutFormat( const SwFrameFormat& rSrc, const SwFormatAnchor& rNewAnchor, bool bSetTextFlyAtt, bool bMakeFrames ) override;
54
55 //Non Interface methods
57
58 virtual ~DocumentLayoutManager() override;
59
60private:
61
64
66
67 SwViewShell *mpCurrentView; //< SwDoc should get a new member mpCurrentView
68 std::unique_ptr<SwLayouter> mpLayouter;
70};
71
72}
73
74#endif
75
76/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Provides access to the layout of a document.
Definition: doc.hxx:192
FlyAnchors.
Definition: fmtanchr.hxx:37
Style of a layout element.
Definition: frmfmt.hxx:62
The root element of a Writer document layout.
Definition: rootfrm.hxx:82
std::unique_ptr< SwLayouter > mpLayouter
css::frame::Controller for complex layout formatting like footnote/endnote in sections
virtual const SwLayouter * GetLayouter() const override
virtual void SetCurrentViewShell(SwViewShell *pNew) override
!!!The old layout must be deleted!!!
virtual void DelLayoutFormat(SwFrameFormat *pFormat) override
Deletes the denoted format and its content.
DocumentLayoutManager(DocumentLayoutManager const &)=delete
DocumentLayoutManager & operator=(DocumentLayoutManager const &)=delete
virtual void SetLayouter(SwLayouter *pNew) override
virtual SwFrameFormat * CopyLayoutFormat(const SwFrameFormat &rSrc, const SwFormatAnchor &rNewAnchor, bool bSetTextFlyAtt, bool bMakeFrames) override
Copies the stated format (pSrc) to pDest and returns pDest.
virtual bool HasLayout() const override
virtual const SwRootFrame * GetCurrentLayout() const override
virtual ~DocumentLayoutManager() override
virtual SwFrameFormat * MakeLayoutFormat(RndStdIds eRequest, const SfxItemSet *pSet) override
Create a new format whose settings fit to the Request by default.
virtual const SwViewShell * GetCurrentViewShell() const override
Returns the layout set at the document.
Dialog to specify the properties of date form field.
RndStdIds