1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 #ifndef VBA_PAGESETUPBASE_HXX
24 #define VBA_PAGESETUPBASE_HXX
25 
26 #include <cppuhelper/implbase1.hxx>
27 #include <ooo/vba/XPageSetupBase.hpp>
28 #include <com/sun/star/uno/XComponentContext.hpp>
29 #include <com/sun/star/beans/XPropertySet.hpp>
30 #include <vbahelper/vbahelperinterface.hxx>
31 
32 typedef InheritedHelperInterfaceImpl1< ooo::vba::XPageSetupBase > VbaPageSetupBase_BASE;
33 
34 class VBAHELPER_DLLPUBLIC VbaPageSetupBase :  public VbaPageSetupBase_BASE
35 {
36 protected:
37     css::uno::Reference< css::frame::XModel > mxModel;
38     css::uno::Reference< css::beans::XPropertySet > mxPageProps;
39     sal_Int32 mnOrientLandscape;
40     sal_Int32 mnOrientPortrait;
41 
42 	VbaPageSetupBase( const css::uno::Reference< ov::XHelperInterface >& xParent,
43                     const css::uno::Reference< css::uno::XComponentContext >& xContext ) throw (css::uno::RuntimeException);
44 public:
~VbaPageSetupBase()45 	virtual ~VbaPageSetupBase(){}
46 
47     // Attribute
48 	virtual double SAL_CALL getTopMargin() throw (css::uno::RuntimeException);
49 	virtual void SAL_CALL setTopMargin( double margin ) throw (css::uno::RuntimeException);
50 	virtual double SAL_CALL getBottomMargin() throw (css::uno::RuntimeException);
51 	virtual void SAL_CALL setBottomMargin( double margin ) throw (css::uno::RuntimeException);
52 	virtual double SAL_CALL getRightMargin() throw (css::uno::RuntimeException);
53 	virtual void SAL_CALL setRightMargin( double margin ) throw (css::uno::RuntimeException);
54 	virtual double SAL_CALL getLeftMargin() throw (css::uno::RuntimeException);
55 	virtual void SAL_CALL setLeftMargin( double margin ) throw (css::uno::RuntimeException);
56 	virtual double SAL_CALL getHeaderMargin() throw (css::uno::RuntimeException);
57 	virtual void SAL_CALL setHeaderMargin( double margin ) throw (css::uno::RuntimeException);
58 	virtual double SAL_CALL getFooterMargin() throw (css::uno::RuntimeException);
59 	virtual void SAL_CALL setFooterMargin( double margin ) throw (css::uno::RuntimeException);
60 	virtual sal_Int32 SAL_CALL getOrientation() throw (css::uno::RuntimeException);
61 	virtual void SAL_CALL setOrientation( sal_Int32 orientation ) throw (css::uno::RuntimeException);
62 };
63 #endif
64