29#include <svx/svxids.hrc>
50#include <com/sun/star/document/XViewDataSupplier.hpp>
51#include <com/sun/star/container/XIndexAccess.hpp>
52#include <com/sun/star/drawing/XDrawPagesSupplier.hpp>
53#include <com/sun/star/drawing/XMasterPagesSupplier.hpp>
54#include <com/sun/star/drawing/framework/XControllerManager.hpp>
55#include <com/sun/star/drawing/framework/XConfigurationController.hpp>
56#include <com/sun/star/drawing/framework/ResourceId.hpp>
73#include <LibreOfficeKit/LibreOfficeKitEnums.h>
79#include <drawview.hxx>
82#define ShellClass_ViewShellBase
85using ::sd::framework::FrameworkHelper;
96class CurrentPageSetter
100 void operator () (
bool);
157 const Point& rOrigin,
174 const OUString& rsPaneURL,
175 const OUString& rsViewURL);
201 virtual ~FocusForwardingWindow()
override;
202 virtual void dispose()
override;
227 mpDocShell (nullptr),
241 mpImpl->mpViewShellManager = std::make_shared<ViewShellManager>(*
this);
263 if (xSlideShow.is() && xSlideShow->dependsOn(
this))
269 mpImpl->mpController->ReleaseViewShellBase();
281 mpImpl->mpToolBarManager->Shutdown();
282 mpImpl->mpViewShellManager->Shutdown();
289 mpImpl->mpFormShellManager.reset();
299 mpImpl->mpEventMultiplexer = std::make_shared<tools::EventMultiplexer>(*
this);
301 mpImpl->mpFormShellManager = std::make_shared<FormShellManager>(*
this);
305 mpImpl->mpEventMultiplexer,
306 mpImpl->mpViewShellManager);
312 if (xControllerManager)
313 xConfigurationController = xControllerManager->getConfigurationController();
314 if (xConfigurationController.is())
316 OUString sView (rsDefaultView);
320 FrameworkHelper::Instance(*
this);
324 FrameworkHelper::CreateResourceId(FrameworkHelper::msCenterPaneURL));
326 FrameworkHelper::CreateResourceId(sView, xCenterPaneId));
329 xConfigurationController->requestResourceActivation(xCenterPaneId, ResourceActivationMode_ADD);
330 xConfigurationController->requestResourceActivation(xCenterViewId, ResourceActivationMode_REPLACE);
336 if (pConfigurationController !=
nullptr)
339 ! pConfigurationController->
getResource(xCenterViewId).is()
347 catch (
const RuntimeException&)
358 if (pViewShell !=
nullptr)
361 if (pFrameView !=
nullptr)
367 mpImpl->SetUserWantsTabBar( bIsTabBarVisible );
372 return mpImpl->mpViewShellManager;
377 std::shared_ptr<ViewShell> pMainViewShell (
380 if (pMainViewShell ==
nullptr)
383 return pMainViewShell;
390 if (pViewFrame !=
nullptr)
410 case SfxEventHintId::OpenDoc:
414 SID_PRESENTATION, SfxCallMode::ASYNCHRON );
427 case SfxHintId::LanguageChanged:
448 return pDrawViewShell
458 return pDrawViewShell
472 Size aObjSizePixel =
mpImpl->mpViewWindow->LogicToPixel(aObjSize,
MapMode(MapUnit::Map100thMM));
478 mpImpl->ResizePixel(rOrigin, rSize,
false);
483 mpImpl->ResizePixel (rOrigin, rSize,
true);
499 SAL_WARN(
"sd.view",
"Rearrange: window missing");
510 if (pShell !=
nullptr)
511 aResult = pShell->
DoVerb(nVerb);
525 OSL_ASSERT(
mpImpl !=
nullptr);
534 OSL_ASSERT(
mpImpl !=
nullptr);
538 if ( (nDiffFlags & SfxPrinterChangeFlags::CHG_ORIENTATION ||
539 nDiffFlags & SfxPrinterChangeFlags::CHG_SIZE) && pNewPrinter )
542 aMap.SetMapUnit(MapUnit::Map100thMM);
543 MapMode aOldMap = pNewPrinter->GetMapMode();
544 pNewPrinter->SetMapMode(
aMap);
545 Size aNewSize = pNewPrinter->GetOutputSize();
547 std::shared_ptr<DrawViewShell> pDrawViewShell (
553 pDrawViewShell->SetPageSizeAndBorder (
554 pDrawViewShell->GetPageKind(),
558 pNewPrinter->GetOrientation(),
563 pNewPrinter->SetMapMode(aOldMap);
571 mpImpl->ShowViewTabBar(
false);
584 mpImpl->ShowViewTabBar(
true);
594 if (
mpImpl->mpViewTabBar.is() &&
mpImpl->mpViewTabBar->GetTabControl()->IsVisible())
595 nTop =
mpImpl->mpViewTabBar->GetHeight();
601 sal_uInt16 nSlotId = rRequest.
GetSlot();
605 case SID_SWITCH_SHELL:
608 if (xControllerManager.is())
611 xControllerManager->getConfigurationController());
612 if (xConfigurationController.is())
613 xConfigurationController->update();
618 case SID_LEFT_PANE_DRAW:
619 mpImpl->SetPaneVisibility(
625 case SID_LEFT_PANE_IMPRESS:
626 mpImpl->SetPaneVisibility(
632 case SID_TOGGLE_TABBAR_VISIBILITY:
637 mpImpl->SetUserWantsTabBar( !bIsTabBarVisible );
643 case SID_DRAWINGMODE:
645 case SID_NORMAL_MULTI_PANE_GUI:
647 case SID_OUTLINE_MODE:
648 case SID_SLIDE_SORTER_MULTI_PANE_GUI:
649 case SID_SLIDE_SORTER_MODE:
651 case SID_SLIDE_MASTER_MODE:
652 case SID_NOTES_MASTER_MODE:
653 case SID_HANDOUT_MASTER_MODE:
657 case SID_WIN_FULLSCREEN:
661 case SID_RESTORE_EDITING_VIEW:
662 mpImpl->ProcessRestoreEditingViewSlot();
680 css::uno::Sequence< css::beans::PropertyValue >& rSequence)
684 if (pShell !=
nullptr)
689 const css::uno::Sequence< css::beans::PropertyValue >& rSequence)
693 if (pShell ==
nullptr)
721 if (!sViewURL.isEmpty())
738 if (xControllerManager.is())
741 xControllerManager->getConfigurationController());
742 if (xConfigurationController.is())
743 xConfigurationController->update();
755 if (pShell !=
nullptr)
765 mpImpl->mbIsClosing =
true;
769 if (pShell !=
nullptr)
782 if (pShell !=
nullptr)
792 if (pShell !=
nullptr)
800 if (pShell !=
nullptr)
821 if (pMainViewShell ==
nullptr ||
GetWindow()==
nullptr)
825 bool bOuterResize ( !
GetDocShell()->IsInPlaceActive());
829 if (bForce || (aBorder != aCurrentBorder))
841 if (pMainViewShell !=
nullptr)
851 OUString sRequestedView (FrameworkHelper::msImpressViewURL);
857 if ( ! xViewDataSupplier.is())
861 if ( ! xViewData.is())
863 if (xViewData->getCount() == 0)
866 css::uno::Any aAny = xViewData->getByIndex(0);
874 [](
const beans::PropertyValue& rProperty) {
return rProperty.Name ==
sUNO_View_PageKind; });
877 sal_Int16 nPageKind = 0;
878 pProperty->Value >>= nPageKind;
879 switch (
static_cast<PageKind>(nPageKind))
882 sRequestedView = FrameworkHelper::msImpressViewURL;
886 sRequestedView = FrameworkHelper::msHandoutViewURL;
890 sRequestedView = FrameworkHelper::msNotesViewURL;
897 SAL_WARN(
"sd.view",
"ViewShellBase::GetInitialViewShellType: invalid page kind");
898 sRequestedView = FrameworkHelper::msImpressViewURL;
905 return sRequestedView;
910 OSL_ASSERT(
mpImpl !=
nullptr);
911 OSL_ASSERT(
mpImpl->mpEventMultiplexer !=
nullptr);
913 return mpImpl->mpEventMultiplexer;
918 return mpImpl->maClientArea;
923 OSL_ASSERT(
mpImpl !=
nullptr);
924 OSL_ASSERT(
mpImpl->mpToolBarManager !=
nullptr);
926 return mpImpl->mpToolBarManager;
931 OSL_ASSERT(
mpImpl !=
nullptr);
932 OSL_ASSERT(
mpImpl->mpFormShellManager !=
nullptr);
934 return mpImpl->mpFormShellManager;
939 OSL_ASSERT(
mpImpl !=
nullptr);
941 return mpImpl->mpController.get();
946 OSL_ASSERT(
mpImpl !=
nullptr);
948 mpImpl->mpViewTabBar = rViewTabBar;
953 OSL_ASSERT(
mpImpl !=
nullptr);
955 return mpImpl->mpViewWindow.get();
971 return pDrawViewShell->GetCurPagePos();
983 switch ( pDrawViewShell->GetEditMode() )
1023 if (!pDrawViewShell)
1026 if (
this == pOtherShell)
1050 OString sRectangle = aRectangle.
toString();
1065 const SdViewOptions& rViewOptions = pCurrentDrawShell->GetViewOptions();
1068 case svtools::ColorConfigEntry::DOCCOLOR:
1081 SAL_WARN(
"sd",
"dynamic_cast to DrawViewShell failed");
1091 const SdViewOptions& rViewOptions = pCurrentDrawShell->GetViewOptions();
1095 SAL_WARN(
"sd",
"dynamic_cast to DrawViewShell failed");
1102 : mbIsClosing(false),
1104 mbUserWantsTabBar(false),
1105 mbTabBarShouldBeVisible(true),
1106 mpPageCacheManager(slidesorter::cache::PageCacheManager::Instance())
1113 mpViewTabBar =
nullptr;
1114 mpViewWindow.disposeAndClear();
1115 mpToolBarManager.reset();
1125 ViewShell* pViewShell = mrBase.GetMainViewShell().get();
1126 if (pViewShell ==
nullptr)
1130 if (pFrameView ==
nullptr)
1141 std::shared_ptr<FrameworkHelper> pHelper (FrameworkHelper::Instance(mrBase));
1142 pHelper->RequestView(
1144 FrameworkHelper::msCenterPaneURL);
1145 pHelper->RunOnConfigurationEvent(
"ConfigurationUpdateEnd", CurrentPageSetter(mrBase));
1150 mbUserWantsTabBar = inValue;
1152 ShowViewTabBar(mbTabBarShouldBeVisible);
1157 mbTabBarShouldBeVisible = bShow;
1158 bShow = bShow && mbUserWantsTabBar;
1160 if (mpViewTabBar.is()
1161 && mpViewTabBar->GetTabControl()->IsVisible() != bShow)
1163 mpViewTabBar->GetTabControl()->Show(bShow);
1169 const Point& rOrigin,
1178 ViewShell* pMainViewShell = mrBase.GetMainViewShell().get();
1182 mrBase.SetWindow (mpViewWindow.get());
1183 if (mpViewTabBar.is() && mpViewTabBar->GetTabControl()->IsVisible())
1184 mpViewTabBar->GetTabControl()->SetPosSizePixel (rOrigin, rSize);
1188 if (pMainViewShell !=
nullptr)
1190 aBorder += mrBase.GetBorder(bOuterResize);
1191 if (mrBase.GetBorderPixel() != aBorder)
1192 mrBase.SetBorderPixel(aBorder);
1196 if (mpViewTabBar.is() && mpViewTabBar->GetTabControl()->IsVisible())
1198 aBaseBorder.
Top() = mpViewTabBar->GetHeight();
1199 mpViewTabBar->GetTabControl()->SetPosSizePixel(
1204 Point aViewWindowPosition (
1205 rOrigin.
X()+aBaseBorder.
Left(),
1206 rOrigin.
Y()+aBaseBorder.
Top());
1208 Size aViewWindowSize (
1211 mpViewWindow->SetPosSizePixel(aViewWindowPosition, aViewWindowSize);
1218 const OUString& rsPaneURL,
1219 const OUString& rsViewURL)
1226 ::comphelper::getProcessComponentContext() );
1228 xContext, rsPaneURL));
1230 xContext, rsViewURL, rsPaneURL));
1234 bool bShowChildWindow;
1235 sal_uInt16 nSlotId = rRequest.
GetSlot();
1236 if (pArguments !=
nullptr)
1237 bShowChildWindow =
static_cast<const SfxBoolItem&
>(
1242 xControllerManager->getConfigurationController());
1243 if ( ! xConfigurationController.is())
1244 throw RuntimeException();
1246 xConfigurationController->getRequestedConfiguration());
1247 if ( ! xConfiguration.is())
1248 throw RuntimeException();
1250 bShowChildWindow = ! xConfiguration->hasResource(xPaneId);
1256 xControllerManager->getConfigurationController());
1257 if ( ! xConfigurationController.is())
1258 throw RuntimeException();
1259 if (bShowChildWindow)
1261 xConfigurationController->requestResourceActivation(
1263 ResourceActivationMode_ADD);
1264 xConfigurationController->requestResourceActivation(
1266 ResourceActivationMode_REPLACE);
1269 xConfigurationController->requestResourceDeactivation(
1285 xControllerManager->getConfigurationController());
1286 if ( ! xConfigurationController.is())
1287 throw RuntimeException();
1289 xConfigurationController->getRequestedConfiguration());
1290 if ( ! xConfiguration.is())
1291 throw RuntimeException();
1294 ::comphelper::getProcessComponentContext() );
1296 sal_uInt16 nItemId (aSetIterator.
FirstWhich());
1300 bool bState (
false);
1307 case SID_LEFT_PANE_IMPRESS:
1308 xResourceId = ResourceId::create(
1309 xContext, FrameworkHelper::msLeftImpressPaneURL);
1310 bState = xConfiguration->hasResource(xResourceId);
1313 case SID_LEFT_PANE_DRAW:
1314 xResourceId = ResourceId::create(
1315 xContext, FrameworkHelper::msLeftDrawPaneURL);
1316 bState = xConfiguration->hasResource(xResourceId);
1319 case SID_DRAWINGMODE:
1320 case SID_NORMAL_MULTI_PANE_GUI:
1321 case SID_SLIDE_MASTER_MODE:
1322 xResourceId = ResourceId::createWithAnchorURL(
1323 xContext, FrameworkHelper::msImpressViewURL,
1324 FrameworkHelper::msCenterPaneURL);
1325 bState = xConfiguration->hasResource(xResourceId);
1328 case SID_SLIDE_SORTER_MULTI_PANE_GUI:
1329 case SID_SLIDE_SORTER_MODE:
1330 xResourceId = ResourceId::createWithAnchorURL(
1332 FrameworkHelper::msSlideSorterURL,
1333 FrameworkHelper::msCenterPaneURL);
1334 bState = xConfiguration->hasResource(xResourceId);
1337 case SID_OUTLINE_MODE:
1338 xResourceId = ResourceId::createWithAnchorURL(
1340 FrameworkHelper::msOutlineViewURL,
1341 FrameworkHelper::msCenterPaneURL);
1342 bState = xConfiguration->hasResource(xResourceId);
1345 case SID_HANDOUT_MASTER_MODE:
1346 xResourceId = ResourceId::createWithAnchorURL(
1347 xContext, FrameworkHelper::msHandoutViewURL,
1348 FrameworkHelper::msCenterPaneURL);
1349 bState = xConfiguration->hasResource(xResourceId);
1352 case SID_NOTES_MODE:
1353 case SID_NOTES_MASTER_MODE:
1354 xResourceId = ResourceId::createWithAnchorURL(
1355 xContext, FrameworkHelper::msNotesViewURL,
1356 FrameworkHelper::msCenterPaneURL);
1357 bState = xConfiguration->hasResource(xResourceId);
1360 case SID_TOGGLE_TABBAR_VISIBILITY:
1361 bState = GetUserWantsTabBar();
1370 catch (
const DeploymentException&)
1378 FrameworkHelper::msCenterPaneURL).get();
1384 case SID_DRAWINGMODE:
1385 case SID_NORMAL_MULTI_PANE_GUI:
1386 case SID_NOTES_MODE:
1389 case SID_SLIDE_MASTER_MODE:
1390 case SID_NOTES_MASTER_MODE:
1403 catch (
const RuntimeException&)
1421void CurrentPageSetter::operator() (
bool)
1425 if (mrBase.GetMainViewShell() !=
nullptr)
1427 pFrameView = mrBase.GetMainViewShell()->GetFrameView();
1430 if (pFrameView==
nullptr)
1441 mrBase.GetController()->getModel(), UNO_QUERY_THROW);
1443 xPagesSupplier->getDrawPages(), UNO_QUERY_THROW);
1449 mrBase.GetController()->getModel(), UNO_QUERY_THROW);
1451 xPagesSupplier->getMasterPages(), UNO_QUERY_THROW);
1457 xSet->setPropertyValue (
"CurrentPage", aPage);
1459 catch (
const RuntimeException&)
1465 catch (
const beans::UnknownPropertyException&)
1467 SAL_WARN(
"sd.view",
"CurrentPage property unknown");
1478FocusForwardingWindow::FocusForwardingWindow (
1484 SAL_INFO(
"sd.view",
"created FocusForwardingWindow at " <<
this);
1487FocusForwardingWindow::~FocusForwardingWindow()
1492void FocusForwardingWindow::dispose()
1494 SAL_INFO(
"sd.view",
"destroyed FocusForwardingWindow at " <<
this);
1498void FocusForwardingWindow::KeyInput (
const KeyEvent& rKEvt)
1500 std::shared_ptr<ViewShell> pViewShell = mrBase.GetMainViewShell();
1501 if (pViewShell !=
nullptr)
1515void FocusForwardingWindow::Command (
const CommandEvent& rEvent)
1517 std::shared_ptr<ViewShell> pViewShell = mrBase.GetMainViewShell();
1518 if (pViewShell !=
nullptr)
PropertiesInfo aProperties
static const AllSettings & GetSettings()
void DrawSelectionXOR(OutlinerViewShell *pOtherShell)
void RegisterOtherShell(OutlinerViewShell *pOtherShell)
void ShowCursor(bool bGotoCursor=true, bool bForceVisCursor=true, bool bActivate=false)
MapUnit GetMapUnit() const
EditView & GetEditView() const
constexpr tools::Long Y() const
constexpr tools::Long X() const
SdPage * GetSdPage(sal_uInt16 nPgNum, PageKind ePgKind) const
void StopWorkStartupDelay()
SAL_DLLPRIVATE bool IsStartWithPresentation() const
bool IsTabBarVisible() const
void SetTabBarVisible(bool bOn)
sal_uInt16 GetPaperBin() const
void AdjustMarkHdl(SfxViewShell *pOtherShell=nullptr)
SdrTextObj * GetTextEditObject() const
const OutlinerView * GetTextEditOutlinerView() const
bool IsBackgroundFullSize() const
void Invalidate(sal_uInt16 nId)
const SfxPoolItem * Execute(sal_uInt16 nSlot, SfxCallMode nCall=SfxCallMode::SLOT, const SfxPoolItem **pArgs=nullptr, sal_uInt16 nModi=0, const SfxPoolItem **pInternalArgs=nullptr)
SfxEventHintId GetEventId() const
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
const SfxPoolItem & Get(sal_uInt16 nWhich, bool bSrchInParent=true) const
static void notifyOtherView(const SfxViewShell *pThisView, SfxViewShell const *pOtherView, int nType, std::string_view rKey, const OString &rPayload)
static void notifyOtherViews(const SfxViewShell *pThisView, int nType, std::string_view rKey, const OString &rPayload)
void SetWaitCursor(bool bSet) const
virtual tools::Rectangle GetVisArea(sal_uInt16 nAspect) const
sal_uInt16 GetSlot() const
const SfxItemSet * GetArgs() const
void Done(bool bRemove=false)
SfxViewFrame * GetFrame() const
SfxViewShell * GetViewShell() const
vcl::Window & GetWindow() const
SfxBindings & GetBindings()
void Resize(bool bForce=false)
SfxDispatcher * GetDispatcher()
virtual bool PrepareClose(bool bUI=true)
VclPtr< vcl::Window > pWindow
virtual void Activate(bool IsMDIActivate) override
virtual void WriteUserData(OUString &, bool bBrowse=false)
css::uno::Reference< css::frame::XController > GetController() const
virtual OUString GetSelectionText(bool bCompleteWords=false, bool bOnlyASample=false)
void SetBorderPixel(const SvBorder &rBorder)
virtual void UIActivating(SfxInPlaceClient *pClient)
virtual void SetZoomFactor(const Fraction &rZoomX, const Fraction &rZoomY)
SfxViewFrame & GetViewFrame() const
virtual void Notify(SfxBroadcaster &rBC, const SfxHint &rHint) override
virtual void ReadUserData(const OUString &, bool bBrowse=false)
virtual bool HasSelection(bool bText=true) const
const SvBorder & GetBorderPixel() const
virtual SfxObjectShell * GetObjectShell() override
virtual SdrView * GetDrawView() const
void SetWindow(vcl::Window *pViewPort)
vcl::Window * GetWindow() const
virtual void UIDeactivated(SfxInPlaceClient *pClient)
constexpr tools::Long Height() const
tools::Long AdjustHeight(tools::Long n)
tools::Long AdjustWidth(tools::Long n)
constexpr tools::Long Width() const
static VclPtr< reference_type > Create(Arg &&... arg)
The DrawController is the UNO controller for Impress and Draw.
void SetPrinter(SfxPrinter *pNewPrinter)
Set new SfxPrinter (transfer of ownership)
SfxPrinter * GetPrinter(bool bCreate)
Creates (if necessary) and returns a SfxPrinter.
SdDrawDocument * GetDoc()
Base class of the stacked shells that provide graphical views to Draw and Impress documents and editi...
OUString GetSelectionText(bool bCompleteWords)
EditMode GetEditMode() const
bool HasSelection(bool bText) const
DrawView * GetDrawView() const
PageKind GetPageKind() const
Derivative of sd::View; contains also a pointer to the document.
ViewShell::ShellType GetViewShellTypeOnLoad() const
PageKind GetPageKindOnLoad() const
can be used to get the page kind that was selected on last save of this document
EditMode GetViewShEditModeOnLoad() const
Return the value of the edit mode as it was when the document was loaded.
void SetViewShellTypeOnLoad(ViewShell::ShellType eType)
Remember the type of the view shell at the time when the document is loaded or, rather,...
void SetPageKind(PageKind eKind)
sal_uInt16 GetSelectedPageOnLoad() const
can be used to get the page that was selected on last save of this document
void SetViewShEditMode(EditMode eMode)
Set EditMode (Page or MasterPage) of working mode.
static void GetSlotState(SfxItemSet &rSet, ViewShell const *pViewShell, SfxViewFrame *pViewFrame)
static void Stop(ViewShellBase const &rBase)
static rtl::Reference< SlideShow > GetSlideShow(SdDrawDocument const *pDocument)
std::shared_ptr< ViewShellManager > mpViewShellManager
void ShowViewTabBar(bool bShow)
Show or hide the ViewTabBar.
::tools::Rectangle maClientArea
bool GetUserWantsTabBar() const
bool mbTabBarShouldBeVisible
void SetUserWantsTabBar(bool inValue)
::rtl::Reference< DrawController > mpController
Main controller of the view shell.
::rtl::Reference< ViewTabBar > mpViewTabBar
The view tab bar is the control for switching between different views in one pane.
void ResizePixel(const Point &rOrigin, const Size &rSize, bool bOuterResize)
Common code of ViewShellBase::OuterResizePixel() and ViewShellBase::InnerResizePixel().
void GetSlotState(SfxItemSet &rSet)
void SetPaneVisibility(const SfxRequest &rRequest, const OUString &rsPaneURL, const OUString &rsViewURL)
Show or hide the specified pane.
std::shared_ptr< slidesorter::cache::PageCacheManager > mpPageCacheManager
Hold a reference to the page cache manager of the slide sorter in order to ensure that it stays alive...
VclPtr< vcl::Window > mpViewWindow
The view window is the parent of all UI elements that belong to the view or ViewShell.
std::shared_ptr< ToolBarManager > mpToolBarManager
std::shared_ptr< FormShellManager > mpFormShellManager
std::shared_ptr< tools::EventMultiplexer > mpEventMultiplexer
Implementation(ViewShellBase &rBase)
void ProcessRestoreEditingViewSlot()
SfxViewShell descendant that the stacked Draw/Impress shells are based on.
DrawController * GetDrawController() const
void LateInit(const OUString &rsDefaultView)
This method is part of the object construction.
virtual void Execute(SfxRequest &rRequest)
Callback function for general slot calls.
::Color GetColorConfigColor(svtools::ColorConfigEntry nColorType) const override
See SfxViewShell::GetColorConfigColor().
static ViewShellBase * GetViewShellBase(SfxViewFrame const *pFrame)
When given a view frame this static method returns the corresponding sd::ViewShellBase object.
OUString RetrieveLabelFromCommand(const OUString &aCmdURL) const
returns the ui descriptive name for the given uno slot.
OUString GetInitialViewShellType() const
Determine from the properties of the document shell the initial type of the view shell in the center ...
virtual void SetZoomFactor(const Fraction &rZoomX, const Fraction &rZoomY) override
void ShowUIControls(bool bVisible)
With this method the UI controls can be turned on or off.
virtual sal_uInt16 SetPrinter(SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags=SFX_PRINTER_ALL) override
Forwarded to the print manager.
virtual void InnerResizePixel(const Point &rOrigin, const Size &rSize, bool inplaceEditModeChange) override
virtual bool HasSelection(bool=true) const override
virtual ~ViewShellBase() override
In this destructor the order in which some of the members are destroyed (and/or being prepared to bei...
void setEditMode(int nMode)
See SfxViewShell::setEditMode().
void GetState(SfxItemSet &rSet)
Callback function for retrieving item values related to certain slots.
void SetBusyState(bool bBusy)
When <TRUE> is given, then the mouse shape is set to hour glass (or whatever the busy shape looks lik...
std::shared_ptr< ToolBarManager > const & GetToolBarManager() const
OUString GetColorConfigName() const override
See SfxViewShell::GetColorConfigName().
DrawDocShell * mpDocShell
virtual void WriteUserDataSequence(css::uno::Sequence< css::beans::PropertyValue > &) override
Forward methods to main sub shell.
const ::tools::Rectangle & getClientRectangle() const
returns the complete area of the current view relative to the frame window
virtual void UIDeactivated(SfxInPlaceClient *) override
virtual void Activate(bool IsMDIActivate) override
virtual void OuterResizePixel(const Point &rOrigin, const Size &rSize) override
std::unique_ptr< Implementation > mpImpl
virtual void ReadUserDataSequence(const css::uno::Sequence< css::beans::PropertyValue > &) override
Pass the given properties to the main view shell.
virtual OUString GetSelectionText(bool=false, bool bOnlyASample=false) override
SdDrawDocument * mpDocument
std::shared_ptr< ViewShell > GetMainViewShell() const
Return the main view shell stacked on the called ViewShellBase object.
virtual void UIActivating(SfxInPlaceClient *) override
void NotifyCursor(SfxViewShell *pViewShell) const override
See SfxViewShell::NotifyCursor().
int getPart() const override
See SfxViewShell::getPart().
int getEditMode() const override
See SfxViewShell::getEditMode().
virtual void InitializeFramework()
std::shared_ptr< tools::EventMultiplexer > const & GetEventMultiplexer() const
Return an event multiplexer.
SvBorder GetBorder(bool bOuterResize)
virtual SfxPrinter * GetPrinter(bool bCreate=false) override
Forwarded to the print manager.
std::shared_ptr< FormShellManager > const & GetFormShellManager() const
virtual ErrCode DoVerb(sal_Int32 nVerb) override
This call is forwarded to the main sub-shell.
virtual css::uno::Reference< css::view::XRenderable > GetRenderable() override
Return a new renderer that can be used for example for printing the document.
vcl::Window * GetViewWindow()
Return the window that is used by the main view shell to display its view and other UI elements,...
ViewShellBase(SfxViewFrame &rFrame, SfxViewShell *pOldShell)
This constructor is used by the view factory of the SFX macros.
virtual void Notify(SfxBroadcaster &rBC, const SfxHint &rHint) override
std::shared_ptr< ViewShellManager > const & GetViewShellManager() const
void UpdateBorder(bool bForce=false)
Update the border that is set with SfxViewShell::SetBorderPixel().
virtual bool PrepareClose(bool bUI=true) override
void Rearrange()
Call this method when the controls of this view shell or the embedded sub shell need to be rearranged...
virtual void ReadUserData(const OUString &, bool bBrowse=false) override
void afterCallbackRegistered() override
See SfxViewShell::afterCallbackRegistered().
virtual void WriteUserData(OUString &, bool bBrowse=false) override
DrawDocShell * GetDocShell() const
virtual SdrView * GetDrawView() const override
SdDrawDocument * GetDocument() const
void SetViewTabBar(const ::rtl::Reference< ViewTabBar > &rViewTabBar)
Base class of the stacked shell hierarchy.
virtual void ShowUIControls(bool bVisible)
Show controls of the UI or hide them, depending on the given flag.
FrameView * GetFrameView()
virtual ErrCode DoVerb(sal_Int32 nVerb)
This function is called from the underlying ViewShellBase object to handle a verb execution request.
virtual void ReadUserDataSequence(const css::uno::Sequence< css::beans::PropertyValue > &)
::sd::Window * GetActiveWindow() const
The active window is usually the mpContentWindow.
SvBorder GetBorder()
Return the border that is drawn around the actual document view.
virtual bool PrepareClose(bool bUI=true)
Tell the FmFormShell that the view shell is closing.
virtual void WriteUserDataSequence(css::uno::Sequence< css::beans::PropertyValue > &)
virtual void SetZoomFactor(const Fraction &rZoomX, const Fraction &rZoomY)
Set zoom factor for InPlace.
virtual void UIActivating(SfxInPlaceClient *)
SD_DLLPUBLIC ViewShellBase & GetViewShellBase() const
virtual void UIDeactivated(SfxInPlaceClient *)
SD_DLLPUBLIC ShellType GetShellType() const
Return the type of the shell.
SdrView * GetDrawView() const
An SdWindow contains the actual working area of ViewShell.
The configuration controller is responsible for maintaining the current configuration.
virtual css::uno::Reference< css::drawing::framework::XResource > SAL_CALL getResource(const css::uno::Reference< css::drawing::framework::XResourceId > &rxResourceId) override
virtual sal_Bool SAL_CALL hasPendingRequests() override
static const OUString msHandoutViewURL
static const OUString msCenterPaneURL
static const OUString msLeftDrawPaneURL
static const OUString msNotesViewURL
static const OUString msSlideSorterURL
static ::std::shared_ptr< FrameworkHelper > Instance(ViewShellBase &rBase)
Return the FrameworkHelper object that is associated with the given ViewShellBase.
static const OUString msLeftImpressPaneURL
static const OUString msImpressViewURL
static const OUString msFullScreenPaneURL
static void CloseMethod(SfxBindings &rBindings)
virtual void dispose() override
vcl::Window * GetParent() const
const MapMode & GetMapMode() const
#define DBG_UNHANDLED_EXCEPTION(...)
virtual SfxBindings & GetBindings() override
SFX_IMPL_SUPERCLASS_INTERFACE(DrawDocShell, SfxObjectShell)
#define SAL_WARN(area, stream)
#define SAL_INFO(area, stream)
constexpr auto toTwips(N number, Length from)
css::uno::Reference< css::linguistic2::XProofreadingIterator > get(css::uno::Reference< css::uno::XComponentContext > const &context)
Sequence< beans::PropertyValue > GetCommandProperties(const OUString &rsCommandName, const OUString &rsModuleName)
OUString GetModuleIdentifier(const Reference< frame::XFrame > &rxFrame)
OUString GetLabelForCommand(const css::uno::Sequence< css::beans::PropertyValue > &rProperties)
HashMap_OWString_Interface aMap
View options for the current view.
Color mnDocBackgroundColor
OUString msColorSchemeName
SvxTableController * mpController
constexpr OUStringLiteral sUNO_View_PageKind
WinBits const WB_DIALOGCONTROL
WinBits const WB_CLIPCHILDREN