LibreOffice Module sc (master) 1
vbawindow.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#pragma once
20
21#include <ooo/vba/excel/XWindow.hpp>
22#include <com/sun/star/uno/XComponentContext.hpp>
23#include <com/sun/star/frame/XModel.hpp>
24#include <ooo/vba/excel/XPane.hpp>
25#include <com/sun/star/awt/XDevice.hpp>
27
29
30typedef cppu::ImplInheritanceHelper< VbaWindowBase, ov::excel::XWindow > WindowImpl_BASE;
31
33{
34private:
35 css::uno::Reference< ov::excel::XPane > m_xPane;
36
37 void init();
39 css::uno::Reference< css::beans::XPropertySet > getControllerProps() const;
41 css::uno::Reference< css::beans::XPropertySet > getFrameProps() const;
43 css::uno::Reference< css::awt::XDevice > getDevice() const;
44
45protected:
46 void SplitAtDefinedPosition( sal_Int32 nColumns, sal_Int32 nRows );
47
48public:
50 void Scroll( const css::uno::Any& Down, const css::uno::Any& Up, const css::uno::Any& ToRight, const css::uno::Any& ToLeft, bool bLargeScroll );
51
52public:
55 const css::uno::Reference< ov::XHelperInterface >& xParent,
56 const css::uno::Reference< css::uno::XComponentContext >& xContext,
57 const css::uno::Reference< css::frame::XModel >& xModel,
58 const css::uno::Reference< css::frame::XController >& xController );
61 const css::uno::Sequence< css::uno::Any >& aArgs,
62 const css::uno::Reference< css::uno::XComponentContext >& xContext );
63
64 // XWindow
65 virtual css::uno::Reference< ov::excel::XRange > SAL_CALL ActiveCell( ) override;
66 virtual css::uno::Reference< ov::excel::XPane > SAL_CALL ActivePane() override;
67 virtual css::uno::Reference< ov::excel::XWorksheet > SAL_CALL ActiveSheet( ) override;
68 virtual void SAL_CALL setCaption( const css::uno::Any& _caption ) override;
69 virtual css::uno::Any SAL_CALL getCaption() override;
70 virtual sal_Bool SAL_CALL getDisplayGridlines() override;
71 virtual void SAL_CALL setDisplayGridlines( sal_Bool _displaygridlines ) override;
72 virtual sal_Bool SAL_CALL getDisplayHeadings() override;
73 virtual void SAL_CALL setDisplayHeadings( sal_Bool _bDisplayHeadings ) override;
74 virtual sal_Bool SAL_CALL getDisplayHorizontalScrollBar() override;
75 virtual void SAL_CALL setDisplayHorizontalScrollBar( sal_Bool _bDisplayHorizontalScrollBar ) override;
76 virtual sal_Bool SAL_CALL getDisplayOutline() override;
77 virtual void SAL_CALL setDisplayOutline( sal_Bool _bDisplayOutline ) override;
78 virtual sal_Bool SAL_CALL getDisplayVerticalScrollBar() override;
79 virtual void SAL_CALL setDisplayVerticalScrollBar( sal_Bool _bDisplayVerticalScrollBar ) override;
80 virtual sal_Bool SAL_CALL getDisplayWorkbookTabs() override;
81 virtual void SAL_CALL setDisplayWorkbookTabs( sal_Bool _bDisplayWorkbookTabs ) override;
82 virtual sal_Bool SAL_CALL getFreezePanes() override;
83 virtual void SAL_CALL setFreezePanes( sal_Bool _bFreezePanes ) override;
84 virtual sal_Bool SAL_CALL getSplit() override;
85 virtual void SAL_CALL setSplit( sal_Bool _bSplit ) override;
86 virtual sal_Int32 SAL_CALL getSplitColumn() override ;
87 virtual void SAL_CALL setSplitColumn( sal_Int32 _splitcolumn ) override ;
88 virtual double SAL_CALL getSplitHorizontal() override ;
89 virtual void SAL_CALL setSplitHorizontal( double _splithorizontal ) override ;
90 virtual sal_Int32 SAL_CALL getSplitRow() override ;
91 virtual void SAL_CALL setSplitRow( sal_Int32 _splitrow ) override ;
92 virtual double SAL_CALL getSplitVertical() override ;
93 virtual void SAL_CALL setSplitVertical( double _splitvertical ) override ;
94 virtual css::uno::Any SAL_CALL getScrollRow() override ;
95 virtual void SAL_CALL setScrollRow( const css::uno::Any& _scrollrow ) override ;
96 virtual css::uno::Any SAL_CALL getScrollColumn() override ;
97 virtual void SAL_CALL setScrollColumn( const css::uno::Any& _scrollcolumn ) override ;
98 virtual css::uno::Any SAL_CALL getView() override;
99 virtual void SAL_CALL setView( const css::uno::Any& _view ) override;
100 virtual css::uno::Reference< ov::excel::XRange > SAL_CALL getVisibleRange() override;
101 virtual css::uno::Any SAL_CALL getWindowState() override;
102 virtual void SAL_CALL setWindowState( const css::uno::Any& _windowstate ) override;
103 virtual css::uno::Any SAL_CALL getZoom() override;
104 virtual void SAL_CALL setZoom(const css::uno::Any& _zoom) override;
105 virtual double SAL_CALL getTabRatio() override ;
106 virtual void SAL_CALL setTabRatio( double _tabratio ) override ;
107
108 // Methods
109 virtual void SAL_CALL SmallScroll( const css::uno::Any& Down, const css::uno::Any& Up, const css::uno::Any& ToRight, const css::uno::Any& ToLeft ) override;
110 virtual void SAL_CALL LargeScroll( const css::uno::Any& Down, const css::uno::Any& Up, const css::uno::Any& ToRight, const css::uno::Any& ToLeft ) override;
111 virtual css::uno::Any SAL_CALL SelectedSheets( const css::uno::Any& aIndex ) override;
112 virtual void SAL_CALL ScrollWorkbookTabs( const css::uno::Any& Sheets, const css::uno::Any& Position ) override;
113 virtual void SAL_CALL Activate( ) override;
114 virtual void SAL_CALL Close( const css::uno::Any& SaveChanges, const css::uno::Any& FileName, const css::uno::Any& RouteWorkBook ) override;
115 virtual css::uno::Any SAL_CALL Selection( ) override;
116 virtual css::uno::Reference< ov::excel::XRange > SAL_CALL RangeSelection() override;
117 virtual sal_Int32 SAL_CALL PointsToScreenPixelsX(sal_Int32 _points) override;
118 virtual sal_Int32 SAL_CALL PointsToScreenPixelsY(sal_Int32 _points) override;
119 virtual void SAL_CALL PrintOut( const css::uno::Any& From, const css::uno::Any&To, const css::uno::Any& Copies, const css::uno::Any& Preview, const css::uno::Any& ActivePrinter, const css::uno::Any& PrintToFile, const css::uno::Any& Collate, const css::uno::Any& PrToFileName ) override;
120 virtual void SAL_CALL PrintPreview( const css::uno::Any& EnableChanges ) override;
121 // XHelperInterface
122 virtual OUString getServiceImplName() override;
123 virtual css::uno::Sequence<OUString> getServiceNames() override;
124};
125
126/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual css::uno::Reference< ov::excel::XWorksheet > SAL_CALL ActiveSheet() override
Definition: vbawindow.cxx:736
virtual void SAL_CALL setDisplayOutline(sal_Bool _bDisplayOutline) override
Definition: vbawindow.cxx:513
virtual sal_Bool SAL_CALL getDisplayHeadings() override
Definition: vbawindow.cxx:477
css::uno::Reference< ov::excel::XPane > m_xPane
Definition: vbawindow.hxx:35
virtual double SAL_CALL getTabRatio() override
Definition: vbawindow.cxx:824
void init()
Definition: vbawindow.cxx:209
virtual void SAL_CALL setFreezePanes(sal_Bool _bFreezePanes) override
Definition: vbawindow.cxx:554
virtual sal_Int32 SAL_CALL getSplitColumn() override
Definition: vbawindow.cxx:610
virtual void SAL_CALL Close(const css::uno::Any &SaveChanges, const css::uno::Any &FileName, const css::uno::Any &RouteWorkBook) override
Definition: vbawindow.cxx:427
virtual double SAL_CALL getSplitVertical() override
Definition: vbawindow.cxx:661
virtual void SAL_CALL setDisplayVerticalScrollBar(sal_Bool _bDisplayVerticalScrollBar) override
Definition: vbawindow.cxx:527
void Scroll(const css::uno::Any &Down, const css::uno::Any &Up, const css::uno::Any &ToRight, const css::uno::Any &ToLeft, bool bLargeScroll)
Definition: vbawindow.cxx:247
virtual void SAL_CALL PrintOut(const css::uno::Any &From, const css::uno::Any &To, const css::uno::Any &Copies, const css::uno::Any &Preview, const css::uno::Any &ActivePrinter, const css::uno::Any &PrintToFile, const css::uno::Any &Collate, const css::uno::Any &PrToFileName) override
Definition: vbawindow.cxx:809
virtual css::uno::Any SAL_CALL getZoom() override
Definition: vbawindow.cxx:702
virtual css::uno::Any SAL_CALL getWindowState() override
Definition: vbawindow.cxx:379
virtual css::uno::Sequence< OUString > getServiceNames() override
Definition: vbawindow.cxx:853
virtual css::uno::Any SAL_CALL getCaption() override
Definition: vbawindow.cxx:304
virtual sal_Bool SAL_CALL getDisplayWorkbookTabs() override
Definition: vbawindow.cxx:533
virtual void SAL_CALL setTabRatio(double _tabratio) override
Definition: vbawindow.cxx:836
virtual double SAL_CALL getSplitHorizontal() override
Definition: vbawindow.cxx:628
virtual void SAL_CALL setSplit(sal_Bool _bSplit) override
Definition: vbawindow.cxx:592
virtual void SAL_CALL setSplitHorizontal(double _splithorizontal) override
Definition: vbawindow.cxx:635
virtual void SAL_CALL LargeScroll(const css::uno::Any &Down, const css::uno::Any &Up, const css::uno::Any &ToRight, const css::uno::Any &ToLeft) override
Definition: vbawindow.cxx:264
virtual void SAL_CALL Activate() override
Definition: vbawindow.cxx:419
virtual void SAL_CALL setDisplayHeadings(sal_Bool _bDisplayHeadings) override
Definition: vbawindow.cxx:485
virtual css::uno::Any SAL_CALL Selection() override
Definition: vbawindow.cxx:448
ScVbaWindow(const css::uno::Sequence< css::uno::Any > &aArgs, const css::uno::Reference< css::uno::XComponentContext > &xContext)
virtual sal_Int32 SAL_CALL PointsToScreenPixelsX(sal_Int32 _points) override
Definition: vbawindow.cxx:793
virtual css::uno::Reference< ov::excel::XRange > SAL_CALL ActiveCell() override
Definition: vbawindow.cxx:441
virtual void SAL_CALL PrintPreview(const css::uno::Any &EnableChanges) override
Definition: vbawindow.cxx:817
virtual sal_Bool SAL_CALL getDisplayVerticalScrollBar() override
Definition: vbawindow.cxx:519
virtual void SAL_CALL setSplitVertical(double _splitvertical) override
Definition: vbawindow.cxx:668
virtual void SAL_CALL setZoom(const css::uno::Any &_zoom) override
Definition: vbawindow.cxx:722
virtual sal_Bool SAL_CALL getSplit() override
Definition: vbawindow.cxx:585
virtual sal_Int32 SAL_CALL getSplitRow() override
Definition: vbawindow.cxx:643
virtual sal_Bool SAL_CALL getDisplayOutline() override
Definition: vbawindow.cxx:505
void SplitAtDefinedPosition(sal_Int32 nColumns, sal_Int32 nRows)
Definition: vbawindow.cxx:675
virtual OUString getServiceImplName() override
Definition: vbawindow.cxx:847
css::uno::Reference< css::beans::XPropertySet > getControllerProps() const
Definition: vbawindow.cxx:229
virtual css::uno::Reference< ov::excel::XRange > SAL_CALL RangeSelection() override
Definition: vbawindow.cxx:455
virtual void SAL_CALL setScrollColumn(const css::uno::Any &_scrollcolumn) override
Definition: vbawindow.cxx:364
virtual void SAL_CALL SmallScroll(const css::uno::Any &Down, const css::uno::Any &Up, const css::uno::Any &ToRight, const css::uno::Any &ToLeft) override
Definition: vbawindow.cxx:258
virtual css::uno::Any SAL_CALL getScrollRow() override
Definition: vbawindow.cxx:319
virtual void SAL_CALL setSplitColumn(sal_Int32 _splitcolumn) override
Definition: vbawindow.cxx:617
virtual css::uno::Any SAL_CALL getView() override
Definition: vbawindow.cxx:743
virtual void SAL_CALL setView(const css::uno::Any &_view) override
Definition: vbawindow.cxx:761
virtual sal_Bool SAL_CALL getDisplayHorizontalScrollBar() override
Definition: vbawindow.cxx:491
virtual void SAL_CALL setSplitRow(sal_Int32 _splitrow) override
Definition: vbawindow.cxx:650
virtual void SAL_CALL setDisplayWorkbookTabs(sal_Bool _bDisplayWorkbookTabs) override
Definition: vbawindow.cxx:541
virtual void SAL_CALL ScrollWorkbookTabs(const css::uno::Any &Sheets, const css::uno::Any &Position) override
Definition: vbawindow.cxx:284
virtual void SAL_CALL setDisplayGridlines(sal_Bool _displaygridlines) override
Definition: vbawindow.cxx:471
virtual sal_Bool SAL_CALL getDisplayGridlines() override
Definition: vbawindow.cxx:463
virtual css::uno::Reference< ov::excel::XRange > SAL_CALL getVisibleRange() override
Definition: vbawindow.cxx:784
virtual css::uno::Any SAL_CALL SelectedSheets(const css::uno::Any &aIndex) override
Definition: vbawindow.cxx:270
virtual void SAL_CALL setScrollRow(const css::uno::Any &_scrollrow) override
Definition: vbawindow.cxx:334
virtual void SAL_CALL setCaption(const css::uno::Any &_caption) override
Definition: vbawindow.cxx:313
virtual void SAL_CALL setWindowState(const css::uno::Any &_windowstate) override
Definition: vbawindow.cxx:397
virtual void SAL_CALL setDisplayHorizontalScrollBar(sal_Bool _bDisplayHorizontalScrollBar) override
Definition: vbawindow.cxx:499
ScVbaWindow(const css::uno::Reference< ov::XHelperInterface > &xParent, const css::uno::Reference< css::uno::XComponentContext > &xContext, const css::uno::Reference< css::frame::XModel > &xModel, const css::uno::Reference< css::frame::XController > &xController)
css::uno::Reference< css::awt::XDevice > getDevice() const
Definition: vbawindow.cxx:241
virtual sal_Bool SAL_CALL getFreezePanes() override
Definition: vbawindow.cxx:547
css::uno::Reference< css::beans::XPropertySet > getFrameProps() const
Definition: vbawindow.cxx:235
virtual sal_Int32 SAL_CALL PointsToScreenPixelsY(sal_Int32 _points) override
Definition: vbawindow.cxx:801
virtual css::uno::Reference< ov::excel::XPane > SAL_CALL ActivePane() override
Definition: vbawindow.cxx:434
virtual css::uno::Any SAL_CALL getScrollColumn() override
Definition: vbawindow.cxx:349
unsigned char sal_Bool
std::vector< uno::Reference< sheet::XSpreadsheet > > Sheets
Definition: vbawindow.cxx:58
cppu::ImplInheritanceHelper< VbaWindowBase, ov::excel::XWindow > WindowImpl_BASE
Definition: vbawindow.hxx:30
cppu::ImplInheritanceHelper< VbaWindowBase, ov::word::XWindow > WindowImpl_BASE