xref: /aoo41x/main/svx/inc/svx/hdft.hxx (revision 3334a7e6)
1*3334a7e6SAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
3*3334a7e6SAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4*3334a7e6SAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5*3334a7e6SAndrew Rist  * distributed with this work for additional information
6*3334a7e6SAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7*3334a7e6SAndrew Rist  * to you under the Apache License, Version 2.0 (the
8*3334a7e6SAndrew Rist  * "License"); you may not use this file except in compliance
9*3334a7e6SAndrew Rist  * with the License.  You may obtain a copy of the License at
10*3334a7e6SAndrew Rist  *
11*3334a7e6SAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12*3334a7e6SAndrew Rist  *
13*3334a7e6SAndrew Rist  * Unless required by applicable law or agreed to in writing,
14*3334a7e6SAndrew Rist  * software distributed under the License is distributed on an
15*3334a7e6SAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*3334a7e6SAndrew Rist  * KIND, either express or implied.  See the License for the
17*3334a7e6SAndrew Rist  * specific language governing permissions and limitations
18*3334a7e6SAndrew Rist  * under the License.
19*3334a7e6SAndrew Rist  *
20*3334a7e6SAndrew Rist  *************************************************************/
21*3334a7e6SAndrew Rist 
22*3334a7e6SAndrew Rist 
23cdf0e10cSrcweir #ifndef _SVX_HDFT_HXX
24cdf0e10cSrcweir #define _SVX_HDFT_HXX
25cdf0e10cSrcweir 
26cdf0e10cSrcweir // include ---------------------------------------------------------------
27cdf0e10cSrcweir 
28cdf0e10cSrcweir #include <sfx2/tabdlg.hxx>
29cdf0e10cSrcweir 
30cdf0e10cSrcweir #ifndef _FIXED_HXX //autogen
31cdf0e10cSrcweir #include <vcl/fixed.hxx>
32cdf0e10cSrcweir #endif
33cdf0e10cSrcweir 
34cdf0e10cSrcweir #ifndef _FIELD_HXX //autogen
35cdf0e10cSrcweir #include <vcl/field.hxx>
36cdf0e10cSrcweir #endif
37cdf0e10cSrcweir 
38cdf0e10cSrcweir #ifndef _GROUP_HXX //autogen
39cdf0e10cSrcweir #include <vcl/group.hxx>
40cdf0e10cSrcweir #endif
41cdf0e10cSrcweir #include <svx/pagectrl.hxx>
42cdf0e10cSrcweir #include "svx/svxdllapi.h"
43cdf0e10cSrcweir 
44cdf0e10cSrcweir // class  SvxHFPage ------------------------------------------------------
45cdf0e10cSrcweir 
46cdf0e10cSrcweir class SVX_DLLPUBLIC SvxHFPage: public SfxTabPage
47cdf0e10cSrcweir {
48cdf0e10cSrcweir 	using TabPage::ActivatePage;
49cdf0e10cSrcweir 	using TabPage::DeactivatePage;
50cdf0e10cSrcweir 
51cdf0e10cSrcweir public:
52cdf0e10cSrcweir 
53cdf0e10cSrcweir 	virtual sal_Bool 	FillItemSet( SfxItemSet& rOutSet );
54cdf0e10cSrcweir 	virtual void	Reset( const SfxItemSet& rSet );
55cdf0e10cSrcweir 
56cdf0e10cSrcweir 	virtual 		~SvxHFPage();
57cdf0e10cSrcweir 
DisableDeleteQueryBox()58cdf0e10cSrcweir 	void			DisableDeleteQueryBox() { bDisableQueryBox = sal_True; }
EnableBackgroundSelector(sal_Bool bNew)59cdf0e10cSrcweir 	void			EnableBackgroundSelector( sal_Bool bNew ) { bEnableBackgroundSelector = bNew; }
60cdf0e10cSrcweir     void            EnableDynamicSpacing();
61cdf0e10cSrcweir 
62cdf0e10cSrcweir protected:
63cdf0e10cSrcweir 	virtual void	ActivatePage( const SfxItemSet& rSet );
64cdf0e10cSrcweir 	virtual int		DeactivatePage( SfxItemSet* pSet = 0 );
65cdf0e10cSrcweir 
66cdf0e10cSrcweir 	SvxHFPage( Window* pParent, sal_uInt16 nResId, const SfxItemSet& rSet,
67cdf0e10cSrcweir 			   sal_uInt16 nSetId );
68cdf0e10cSrcweir 
69cdf0e10cSrcweir 	FixedLine       aFrm;
70cdf0e10cSrcweir 	CheckBox        aTurnOnBox;
71cdf0e10cSrcweir 	CheckBox        aCntSharedBox;
72cdf0e10cSrcweir 	FixedText       aLMLbl;
73cdf0e10cSrcweir 	MetricField     aLMEdit;
74cdf0e10cSrcweir 	FixedText       aRMLbl;
75cdf0e10cSrcweir 	MetricField     aRMEdit;
76cdf0e10cSrcweir 	FixedText		aDistFT;
77cdf0e10cSrcweir 	MetricField     aDistEdit;
78cdf0e10cSrcweir     CheckBox        aDynSpacingCB;
79cdf0e10cSrcweir 	FixedText		aHeightFT;
80cdf0e10cSrcweir 	MetricField     aHeightEdit;
81cdf0e10cSrcweir 	CheckBox     	aHeightDynBtn;
82cdf0e10cSrcweir 	SvxPageWindow	aBspWin;
83cdf0e10cSrcweir 	PushButton		aBackgroundBtn;
84cdf0e10cSrcweir 
85cdf0e10cSrcweir 	sal_uInt16			nId;
86cdf0e10cSrcweir 	SfxItemSet*		pBBSet;
87cdf0e10cSrcweir 	sal_Bool			bDisableQueryBox;
88cdf0e10cSrcweir 	sal_Bool			bEnableBackgroundSelector;
89cdf0e10cSrcweir 	FASTBOOL		bInReset;
90cdf0e10cSrcweir 
91cdf0e10cSrcweir 	void 			InitHandler();
92cdf0e10cSrcweir 	DECL_LINK( TurnOnHdl, CheckBox*);
93cdf0e10cSrcweir 	DECL_LINK( DistModify, MetricField*);
94cdf0e10cSrcweir 	DECL_LINK( HeightModify, MetricField*);
95cdf0e10cSrcweir 	DECL_LINK( BorderModify, MetricField*);
96cdf0e10cSrcweir 	DECL_LINK( BackgroundHdl, Button*);
97cdf0e10cSrcweir 
98cdf0e10cSrcweir 	void			UpdateExample();
99cdf0e10cSrcweir 	DECL_LINK( RangeHdl, Edit*);
100cdf0e10cSrcweir 
101cdf0e10cSrcweir private:
102cdf0e10cSrcweir #ifdef _SVX_HDFT_CXX
103cdf0e10cSrcweir 	SVX_DLLPRIVATE void			ResetBackground_Impl( const SfxItemSet& rSet );
104cdf0e10cSrcweir #endif
105cdf0e10cSrcweir };
106cdf0e10cSrcweir 
107cdf0e10cSrcweir // class SvxHeaderPage ---------------------------------------------------
108cdf0e10cSrcweir 
109cdf0e10cSrcweir class SVX_DLLPUBLIC SvxHeaderPage : public SvxHFPage
110cdf0e10cSrcweir {
111cdf0e10cSrcweir public:
112cdf0e10cSrcweir 	static SfxTabPage* 	Create(	Window* pParent, const SfxItemSet& rSet );
113cdf0e10cSrcweir 	static sal_uInt16*		GetRanges();
114cdf0e10cSrcweir 
115cdf0e10cSrcweir private:
116cdf0e10cSrcweir 	SvxHeaderPage( Window* pParent, const SfxItemSet& rSet );
117cdf0e10cSrcweir };
118cdf0e10cSrcweir 
119cdf0e10cSrcweir // class SvxFooterPage ---------------------------------------------------
120cdf0e10cSrcweir 
121cdf0e10cSrcweir class SVX_DLLPUBLIC SvxFooterPage : public SvxHFPage
122cdf0e10cSrcweir {
123cdf0e10cSrcweir public:
124cdf0e10cSrcweir 	static SfxTabPage* 	Create(	Window* pParent, const SfxItemSet& rSet );
125cdf0e10cSrcweir 	static sal_uInt16*		GetRanges();
126cdf0e10cSrcweir 
127cdf0e10cSrcweir private:
128cdf0e10cSrcweir 	SVX_DLLPRIVATE SvxFooterPage( 	Window* pParent, const SfxItemSet& rSet );
129cdf0e10cSrcweir };
130cdf0e10cSrcweir 
131cdf0e10cSrcweir #endif
132cdf0e10cSrcweir 
133