LibreOffice Module sd (master) 1
OutlineViewShell.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#pragma once
21
22#include "ViewShell.hxx"
23#include <glob.hxx>
24
25class SdPage;
28
29namespace sd { class OutlineView; }
30
31namespace sd {
32
36 : public ViewShell
37{
38public:
39
42
43private:
45 static void InitInterface_Impl();
46
47public:
56 SfxViewFrame* pFrame,
57 ViewShellBase& rViewShellBase,
58 vcl::Window* pParentWindow,
59 FrameView* pFrameView);
60
61 virtual ~OutlineViewShell() override;
62
63 virtual void Shutdown() override;
64
65 virtual void Paint(const ::tools::Rectangle& rRect, ::sd::Window* pWin) override;
66
72 virtual void ArrangeGUIElements() override;
73
74 virtual bool PrepareClose( bool bUI = true ) override;
75
76 virtual void VirtHScrollHdl(ScrollAdaptor* pHScroll) override;
77 virtual void VirtVScrollHdl(ScrollAdaptor* pVHScroll) override;
78
79 virtual void Activate( bool IsMDIActivate ) override;
80 virtual void Deactivate( bool IsMDIActivate ) override;
81
82 virtual SdPage* GetActualPage() override;
83
85 virtual SdPage* getCurrentPage() const override;
86
87 void ExecCtrl(SfxRequest &rReq);
88 void GetCtrlState(SfxItemSet &rSet);
89 // FIXME non-virtual override???
90 void GetMenuState(SfxItemSet &rSet);
91 void GetAttrState(SfxItemSet &rSet);
92 void GetState (SfxItemSet& rSet);
93
94 static void ExecStatusBar(SfxRequest& rReq);
95 void GetStatusBarState(SfxItemSet& rSet);
96
97 void FuTemporary(SfxRequest &rReq);
98 void FuTemporaryModify(SfxRequest &rReq);
99 void FuPermanent(SfxRequest &rReq);
100 void FuSupport(SfxRequest &rReq);
101
102 virtual void SetZoom(::tools::Long nZoom) override;
103 virtual void SetZoomRect(const ::tools::Rectangle& rZoomRect) override;
104
105 void Execute(SfxRequest& rReq);
106
107 virtual void ReadFrameViewData(FrameView* pView) override;
108 virtual void WriteFrameViewData() override;
109
110 virtual void Command( const CommandEvent& rCEvt, ::sd::Window* pWin ) override;
111 virtual bool KeyInput(const KeyEvent& rKEvt, ::sd::Window* pWin) override;
112 virtual void MouseButtonUp(const MouseEvent& rMEvt, ::sd::Window* pWin) override;
113
114 ErrCode ReadRtf(SvStream& rInput);
115
116 virtual void WriteUserDataSequence ( css::uno::Sequence < css::beans::PropertyValue >& ) override;
117 virtual void ReadUserDataSequence ( const css::uno::Sequence < css::beans::PropertyValue >& ) override;
118
120 virtual void VisAreaChanged(const ::tools::Rectangle& rRect) override;
121
129 virtual css::uno::Reference<css::accessibility::XAccessible>
130 CreateAccessibleDocumentView (::sd::Window* pWindow) override;
131
134 virtual void UpdatePreview (SdPage* pPage) override;
135
136 virtual css::uno::Reference<css::drawing::XDrawSubController> CreateSubController() override;
137
144 void SetCurrentPage (SdPage* pPage);
145
146 void UpdateTitleObject( SdPage* pPage, Paragraph const * pPara );
147 void UpdateOutlineObject( SdPage* pPage, Paragraph* pPara );
148
149private:
151 std::unique_ptr<OutlineView> pOlView;
152 SdPage* pLastPage; // For efficient processing of the preview
156
157 void Construct();
158 DECL_LINK( ClipboardChanged, TransferableDataHelper*, void );
159};
160
161} // end of namespace sd
162
163/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
View for MDIFrame.
Definition: FrameView.hxx:36
Show a textual overview of the text contents of all slides.
virtual bool KeyInput(const KeyEvent &rKEvt, ::sd::Window *pWin) override
Definition: outlnvsh.cxx:1378
ErrCode ReadRtf(SvStream &rInput)
Fill Outliner from Stream.
Definition: outlnvsh.cxx:1742
virtual void UpdatePreview(SdPage *pPage) override
Update the preview to show the specified page.
Definition: outlnvsh.cxx:1549
virtual ~OutlineViewShell() override
Definition: outlnvsh.cxx:206
void Execute(SfxRequest &rReq)
Before saving: Update Model of the Drawing Engine, then forward the invocation to the ObjectShell.
Definition: outlnvsh.cxx:1154
std::unique_ptr< OutlineView > pOlView
void UpdateTitleObject(SdPage *pPage, Paragraph const *pPara)
Definition: outlnvsh.cxx:1560
void GetStatusBarState(SfxItemSet &rSet)
Definition: outlnvsh.cxx:1246
virtual void ReadUserDataSequence(const css::uno::Sequence< css::beans::PropertyValue > &) override
Definition: outlnvsh.cxx:1805
void GetAttrState(SfxItemSet &rSet)
Status of Attribute-Items.
Definition: outlnvsh.cxx:1418
void FuSupport(SfxRequest &rReq)
SfxRequests for support functions.
Definition: outlnvsh.cxx:406
void FuPermanent(SfxRequest &rReq)
SfxRequests for permanent functions.
Definition: outlnvsh.cxx:658
virtual void WriteUserDataSequence(css::uno::Sequence< css::beans::PropertyValue > &) override
Definition: outlnvsh.cxx:1798
virtual css::uno::Reference< css::drawing::XDrawSubController > CreateSubController() override
Return a sub controller that implements the view shell specific part of the DrawController.
Definition: outlnvsh.cxx:163
virtual void VirtVScrollHdl(ScrollAdaptor *pVHScroll) override
handling for vertical Scrollbars
Definition: outlnvsh.cxx:1073
void GetState(SfxItemSet &rSet)
Definition: outlnvsh.cxx:1845
virtual void Deactivate(bool IsMDIActivate) override
Definition: outlnvsh.cxx:333
void FuTemporaryModify(SfxRequest &rReq)
Definition: outlnvs2.cxx:335
void Construct()
common initialization part of both constructors
Definition: outlnvsh.cxx:126
rtl::Reference< TransferableClipboardListener > mxClipEvtLstnr
virtual SdPage * GetActualPage() override
Returns the first selected page.
Definition: outlnvsh.cxx:1544
void ExecCtrl(SfxRequest &rReq)
Handle SfxRequest for the Controller.
Definition: outlnvsh.cxx:283
virtual void SetZoom(::tools::Long nZoom) override
Zoom with zoom factor.
Definition: outlnvsh.cxx:1111
virtual void Shutdown() override
This method is more or less an alias to Deactivate().
Definition: outlnvsh.cxx:221
void FuTemporary(SfxRequest &rReq)
SfxRequests for temporary functions.
Definition: outlnvs2.cxx:69
void UpdateOutlineObject(SdPage *pPage, Paragraph *pPara)
Definition: outlnvsh.cxx:1640
virtual void ArrangeGUIElements() override
Arrange and resize the GUI elements like rulers, sliders, and buttons as well as the actual document ...
Definition: outlnvsh.cxx:240
void GetMenuState(SfxItemSet &rSet)
Set Status (Enabled/Disabled) of Menu-SfxSlots.
Definition: outlnvsh.cxx:714
SFX_DECL_VIEWFACTORY(OutlineViewShell)
virtual css::uno::Reference< css::accessibility::XAccessible > CreateAccessibleDocumentView(::sd::Window *pWindow) override
Create an accessible object representing the specified window.
Definition: outlnvsh.cxx:1826
static void InitInterface_Impl()
SfxInterface initializer.
Definition: outlnvsh.cxx:105
virtual void VisAreaChanged(const ::tools::Rectangle &rRect) override
this method is called when the visible area of the view from this viewshell is changed
Definition: outlnvsh.cxx:1814
DECL_LINK(ClipboardChanged, TransferableDataHelper *, void)
virtual void VirtHScrollHdl(ScrollAdaptor *pHScroll) override
gets invoked when ScrollBar is used
Definition: outlnvsh.cxx:1052
virtual SdPage * getCurrentPage() const override
inherited from sd::ViewShell
Definition: outlnvsh.cxx:1533
virtual void Command(const CommandEvent &rCEvt, ::sd::Window *pWin) override
Definition: outlnvsh.cxx:1346
virtual bool PrepareClose(bool bUI=true) override
PrepareClose, gets called when the Shell shall be destroyed.
Definition: outlnvsh.cxx:1098
virtual void Activate(bool IsMDIActivate) override
Activate(): during the first invocation the fields get updated.
Definition: outlnvsh.cxx:310
void SetCurrentPage(SdPage *pPage)
Make the given page the new current page.
Definition: outlnvsh.cxx:1867
virtual void Paint(const ::tools::Rectangle &rRect, ::sd::Window *pWin) override
Paint method: the event gets forwarded from pWindow to the Viewshell and the current function.
Definition: outlnvsh.cxx:232
virtual void SetZoomRect(const ::tools::Rectangle &rZoomRect) override
Zoom with zoom rectangle.
Definition: outlnvsh.cxx:1132
OutlineViewShell(SfxViewFrame *pFrame, ViewShellBase &rViewShellBase, vcl::Window *pParentWindow, FrameView *pFrameView)
Create a new view shell for the outline mode.
Definition: outlnvsh.cxx:179
virtual void ReadFrameViewData(FrameView *pView) override
Read FrameViews data and set actual views data.
Definition: outlnvsh.cxx:1202
static void ExecStatusBar(SfxRequest &rReq)
Handle SfxRequests for the StatusBar.
Definition: outlnvsh.cxx:1242
virtual void MouseButtonUp(const MouseEvent &rMEvt, ::sd::Window *pWin) override
Definition: outlnvsh.cxx:1513
virtual void WriteFrameViewData() override
Write actual views data to FrameView.
Definition: outlnvsh.cxx:1223
void GetCtrlState(SfxItemSet &rSet)
Set status of Controller-SfxSlots.
Definition: outlnvsh.cxx:345
SfxViewShell descendant that the stacked Draw/Impress shells are based on.
Base class of the stacked shell hierarchy.
Definition: ViewShell.hxx:92
An SdWindow contains the actual working area of ViewShell.
Definition: Window.hxx:45
#define SD_IF_SDOUTLINEVIEWSHELL
Definition: glob.hxx:27
long Long
#define SFX_DECL_INTERFACE(nId)