xref: /trunk/main/sc/source/ui/inc/tphf.hxx (revision 38d50f7b)
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 
24 #ifndef SC_TPHF_HXX
25 #define SC_TPHF_HXX
26 
27 
28 #include <svx/hdft.hxx>
29 
30 class ScStyleDlg;
31 
32 //========================================================================
33 
34 class ScHFPage : public SvxHFPage
35 {
36 public:
37 	virtual			~ScHFPage();
38 
39 	virtual void	Reset( const SfxItemSet& rSet );
40 	virtual sal_Bool 	FillItemSet( SfxItemSet& rOutSet );
41 
SetPageStyle(const String & rName)42 	void			SetPageStyle( const String& rName )    { aStrPageStyle = rName; }
SetStyleDlg(const ScStyleDlg * pDlg)43 	void			SetStyleDlg ( const ScStyleDlg* pDlg ) { pStyleDlg = pDlg; }
44 
45 protected:
46 					ScHFPage( Window* pParent,
47 							  sal_uInt16 nResId,
48 							  const SfxItemSet& rSet,
49 							  sal_uInt16 nSetId );
50 
51 //    using SvxHFPage::ActivatePage;
52 //    using SvxHFPage::DeactivatePage;
53     virtual void    ActivatePage();
54     virtual void    DeactivatePage();
55 	virtual void	ActivatePage( const SfxItemSet& rSet );
56 	virtual int		DeactivatePage( SfxItemSet* pSet = 0 );
57 
58 private:
59 	PushButton			aBtnEdit;
60 	SfxItemSet			aDataSet;
61 	String				aStrPageStyle;
62 	sal_uInt16				nPageUsage;
63 	const ScStyleDlg*	pStyleDlg;
64 
65 #ifdef _TPHF_CXX
66 private:
67 	DECL_LINK( BtnHdl, PushButton* );
68 	DECL_LINK( HFEditHdl, void* );
69 	DECL_LINK( TurnOnHdl, CheckBox* );
70 #endif
71 };
72 
73 //========================================================================
74 
75 class ScHeaderPage : public ScHFPage
76 {
77 public:
78 	static SfxTabPage* 	Create(	Window* pParent, const SfxItemSet& rSet );
79 	static sal_uInt16*		GetRanges();
80 
81 private:
82 	ScHeaderPage( Window* pParent, const SfxItemSet& rSet );
83 };
84 
85 //========================================================================
86 
87 class ScFooterPage : public ScHFPage
88 {
89 public:
90 	static SfxTabPage* 	Create(	Window* pParent, const SfxItemSet& rSet );
91 	static sal_uInt16*		GetRanges();
92 
93 private:
94 	ScFooterPage( Window* pParent, const SfxItemSet& rSet );
95 };
96 
97 
98 #endif // SC_TPHF_HXX
99 
100