xref: /aoo42x/main/cui/source/inc/cuitabarea.hxx (revision b164f441)
1c4eee24dSAndrew Rist /**************************************************************
2c4eee24dSAndrew Rist  *
3c4eee24dSAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4c4eee24dSAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5c4eee24dSAndrew Rist  * distributed with this work for additional information
6c4eee24dSAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7c4eee24dSAndrew Rist  * to you under the Apache License, Version 2.0 (the
8c4eee24dSAndrew Rist  * "License"); you may not use this file except in compliance
9c4eee24dSAndrew Rist  * with the License.  You may obtain a copy of the License at
10c4eee24dSAndrew Rist  *
11c4eee24dSAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12cdf0e10cSrcweir  *
13c4eee24dSAndrew Rist  * Unless required by applicable law or agreed to in writing,
14c4eee24dSAndrew Rist  * software distributed under the License is distributed on an
15c4eee24dSAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16c4eee24dSAndrew Rist  * KIND, either express or implied.  See the License for the
17c4eee24dSAndrew Rist  * specific language governing permissions and limitations
18c4eee24dSAndrew Rist  * under the License.
19c4eee24dSAndrew Rist  *
20c4eee24dSAndrew Rist  *************************************************************/
21c4eee24dSAndrew Rist 
22c4eee24dSAndrew Rist 
23cdf0e10cSrcweir #ifndef _CUI_TAB_AREA_HXX
24cdf0e10cSrcweir #define _CUI_TAB_AREA_HXX
25cdf0e10cSrcweir 
26cdf0e10cSrcweir // include ---------------------------------------------------------------
27cdf0e10cSrcweir 
28cdf0e10cSrcweir #include <svx/tabarea.hxx>
2928bcfa49SArmin Le Grand #include <svx/SvxColorValueSet.hxx>
30cdf0e10cSrcweir 
31cdf0e10cSrcweir /*************************************************************************
32cdf0e10cSrcweir |*
33cdf0e10cSrcweir |* Fl"achen-Tab-Dialog
34cdf0e10cSrcweir |*
35cdf0e10cSrcweir \************************************************************************/
36cdf0e10cSrcweir 
37cdf0e10cSrcweir class SvxAreaTabDialog : public SfxTabDialog
38cdf0e10cSrcweir {
39cdf0e10cSrcweir private:
40cdf0e10cSrcweir 	SdrModel*           mpDrawModel;
41cdf0e10cSrcweir //	const SdrView*		mpView;
42cdf0e10cSrcweir 
43c7be74b1SArmin Le Grand 	XColorListSharedPtr     maColorTab;
44c7be74b1SArmin Le Grand 	XColorListSharedPtr     maNewColorTab;
45c7be74b1SArmin Le Grand 	XGradientListSharedPtr  maGradientList;
46c7be74b1SArmin Le Grand 	XGradientListSharedPtr  maNewGradientList;
47c7be74b1SArmin Le Grand 	XHatchListSharedPtr     maHatchingList;
48c7be74b1SArmin Le Grand 	XHatchListSharedPtr     maNewHatchingList;
49c7be74b1SArmin Le Grand 	XBitmapListSharedPtr    maBitmapList;
50c7be74b1SArmin Le Grand 	XBitmapListSharedPtr    maNewBitmapList;
51cdf0e10cSrcweir 
52cdf0e10cSrcweir 	const SfxItemSet&   mrOutAttrs;
53cdf0e10cSrcweir 
54cdf0e10cSrcweir 	ChangeType          mnColorTableState;
55cdf0e10cSrcweir 	ChangeType          mnBitmapListState;
56cdf0e10cSrcweir 	ChangeType          mnGradientListState;
57cdf0e10cSrcweir 	ChangeType          mnHatchingListState;
58cdf0e10cSrcweir 
59cdf0e10cSrcweir 	sal_uInt16              mnPageType;
60cdf0e10cSrcweir 	sal_uInt16              mnDlgType;
61cdf0e10cSrcweir 	sal_uInt16              mnPos;
62cdf0e10cSrcweir 	sal_Bool                mbAreaTP;
63cdf0e10cSrcweir 
64cdf0e10cSrcweir 	virtual void        PageCreated( sal_uInt16 nId, SfxTabPage &rPage );
65cdf0e10cSrcweir 
66cdf0e10cSrcweir protected:
67cdf0e10cSrcweir 	virtual short       Ok();
68cdf0e10cSrcweir #ifdef _SVX_TABAREA_CXX
69cdf0e10cSrcweir 	DECL_LINK( CancelHdlImpl, void * );
70cdf0e10cSrcweir 	void                SavePalettes();
71cdf0e10cSrcweir #endif
72cdf0e10cSrcweir 
73cdf0e10cSrcweir public:
7464b14621SArmin Le Grand 	SvxAreaTabDialog( Window* pParent, const SfxItemSet* pAttr, SdrModel* pModel, bool bShadow );
75cdf0e10cSrcweir 	~SvxAreaTabDialog();
76cdf0e10cSrcweir 
SetNewColorTable(XColorListSharedPtr aColTab)77c7be74b1SArmin Le Grand 	void SetNewColorTable( XColorListSharedPtr aColTab ) { maNewColorTab = aColTab; }
GetNewColorTable() const78c7be74b1SArmin Le Grand 	XColorListSharedPtr GetNewColorTable() const { return maNewColorTab; }
GetColorTable() const79c7be74b1SArmin Le Grand 	const XColorListSharedPtr GetColorTable() const { return maColorTab; }
80c7be74b1SArmin Le Grand 
SetNewGradientList(XGradientListSharedPtr aGrdLst)81c7be74b1SArmin Le Grand 	void SetNewGradientList( XGradientListSharedPtr aGrdLst) { maNewGradientList = aGrdLst; }
GetNewGradientList() const82c7be74b1SArmin Le Grand 	XGradientListSharedPtr GetNewGradientList() const { return maNewGradientList; }
GetGradientList() const83c7be74b1SArmin Le Grand 	const XGradientListSharedPtr GetGradientList() const { return maGradientList; }
84c7be74b1SArmin Le Grand 
SetNewHatchingList(XHatchListSharedPtr aHtchLst)85c7be74b1SArmin Le Grand 	void SetNewHatchingList( XHatchListSharedPtr aHtchLst) { maNewHatchingList = aHtchLst; }
GetNewHatchingList() const86c7be74b1SArmin Le Grand 	XHatchListSharedPtr GetNewHatchingList() const { return maNewHatchingList; }
GetHatchingList() const87c7be74b1SArmin Le Grand 	const XHatchListSharedPtr GetHatchingList() const { return maHatchingList; }
88c7be74b1SArmin Le Grand 
SetNewBitmapList(XBitmapListSharedPtr aBmpLst)89c7be74b1SArmin Le Grand 	void SetNewBitmapList( XBitmapListSharedPtr aBmpLst) { maNewBitmapList = aBmpLst; }
GetNewBitmapList() const90c7be74b1SArmin Le Grand 	XBitmapListSharedPtr GetNewBitmapList() const { return maNewBitmapList; }
GetBitmapList() const91c7be74b1SArmin Le Grand 	const XBitmapListSharedPtr GetBitmapList() const { return maBitmapList; }
92cdf0e10cSrcweir };
93cdf0e10cSrcweir 
94cdf0e10cSrcweir /*************************************************************************
95cdf0e10cSrcweir |*
96cdf0e10cSrcweir |* Transparence-Tab-Page
97cdf0e10cSrcweir |*
98cdf0e10cSrcweir \************************************************************************/
99cdf0e10cSrcweir 
100cdf0e10cSrcweir class SvxTransparenceTabPage : public SvxTabPage
101cdf0e10cSrcweir {
102cdf0e10cSrcweir 	using TabPage::ActivatePage;
103cdf0e10cSrcweir 	using TabPage::DeactivatePage;
104cdf0e10cSrcweir 
105cdf0e10cSrcweir 	const SfxItemSet&   rOutAttrs;
106cdf0e10cSrcweir 	RECT_POINT          eRP;
107cdf0e10cSrcweir 
108*b164f441SArmin Le Grand 	sal_uInt16             nPageType;
109*b164f441SArmin Le Grand 	sal_uInt16             nDlgType;
110cdf0e10cSrcweir 
111cdf0e10cSrcweir 	// main selection
112cdf0e10cSrcweir     FixedLine           aFlProp;
113cdf0e10cSrcweir     RadioButton         aRbtTransOff;
114cdf0e10cSrcweir     RadioButton         aRbtTransLinear;
115cdf0e10cSrcweir 	RadioButton         aRbtTransGradient;
116cdf0e10cSrcweir 
117cdf0e10cSrcweir 	// linear transparency
118cdf0e10cSrcweir 	MetricField         aMtrTransparent;
119cdf0e10cSrcweir 
120cdf0e10cSrcweir 	// gradient transparency
121cdf0e10cSrcweir 	FixedText           aFtTrgrType;
122cdf0e10cSrcweir 	ListBox             aLbTrgrGradientType;
123cdf0e10cSrcweir 	FixedText           aFtTrgrCenterX;
124cdf0e10cSrcweir 	MetricField         aMtrTrgrCenterX;
125cdf0e10cSrcweir 	FixedText           aFtTrgrCenterY;
126cdf0e10cSrcweir 	MetricField         aMtrTrgrCenterY;
127cdf0e10cSrcweir 	FixedText           aFtTrgrAngle;
128cdf0e10cSrcweir 	MetricField         aMtrTrgrAngle;
129cdf0e10cSrcweir 	FixedText           aFtTrgrBorder;
130cdf0e10cSrcweir 	MetricField         aMtrTrgrBorder;
131cdf0e10cSrcweir 	FixedText           aFtTrgrStartValue;
132cdf0e10cSrcweir 	MetricField         aMtrTrgrStartValue;
133cdf0e10cSrcweir 	FixedText           aFtTrgrEndValue;
134cdf0e10cSrcweir 	MetricField         aMtrTrgrEndValue;
135cdf0e10cSrcweir 
136cdf0e10cSrcweir 	// preview
137cdf0e10cSrcweir 	SvxXRectPreview     aCtlBitmapPreview;
138cdf0e10cSrcweir 	SvxXRectPreview     aCtlXRectPreview;
139cdf0e10cSrcweir 	sal_Bool				bBitmap;
140cdf0e10cSrcweir 
141cdf0e10cSrcweir 	XOutdevItemPool*    pXPool;
142cdf0e10cSrcweir 	XFillAttrSetItem    aXFillAttr;
143cdf0e10cSrcweir 	SfxItemSet&         rXFSet;
144cdf0e10cSrcweir 
145cdf0e10cSrcweir #ifdef _SVX_TPAREA_CXX
146cdf0e10cSrcweir 	DECL_LINK(ClickTransOffHdl_Impl, void * );
147cdf0e10cSrcweir 	DECL_LINK(ClickTransLinearHdl_Impl, void * );
148cdf0e10cSrcweir 	DECL_LINK(ClickTransGradientHdl_Impl, void * );
149cdf0e10cSrcweir 	DECL_LINK(ModifyTransparentHdl_Impl, void*);
150cdf0e10cSrcweir 	DECL_LINK(ChangeTrgrTypeHdl_Impl, void*);
151cdf0e10cSrcweir 	DECL_LINK(ModifiedTrgrHdl_Impl, void*);
152cdf0e10cSrcweir #endif
153cdf0e10cSrcweir 
154cdf0e10cSrcweir 	void ActivateLinear(sal_Bool bActivate);
155cdf0e10cSrcweir 	void ActivateGradient(sal_Bool bActivate);
156cdf0e10cSrcweir 	void SetControlState_Impl(XGradientStyle eXGS);
157cdf0e10cSrcweir 
158cdf0e10cSrcweir 	sal_Bool InitPreview ( const SfxItemSet& rSet );
159cdf0e10cSrcweir 	void InvalidatePreview (sal_Bool bEnable = sal_True );
160cdf0e10cSrcweir 
161cdf0e10cSrcweir public:
162cdf0e10cSrcweir 	SvxTransparenceTabPage(Window* pParent, const SfxItemSet& rInAttrs);
163cdf0e10cSrcweir 	void Construct();
164cdf0e10cSrcweir 
165cdf0e10cSrcweir 	static SfxTabPage* Create(Window*, const SfxItemSet&);
166cdf0e10cSrcweir 	static sal_uInt16* GetRanges();
167cdf0e10cSrcweir 
168cdf0e10cSrcweir 	virtual sal_Bool FillItemSet(SfxItemSet&);
169cdf0e10cSrcweir 	virtual void Reset(const SfxItemSet&);
170cdf0e10cSrcweir 	virtual void ActivatePage(const SfxItemSet& rSet);
171cdf0e10cSrcweir 	virtual int  DeactivatePage(SfxItemSet* pSet);
172cdf0e10cSrcweir 	virtual void PointChanged(Window* pWindow, RECT_POINT eRP);
173cdf0e10cSrcweir 
174cdf0e10cSrcweir 	//CHINA001 void SetPageType(sal_uInt16 *pInType) { pPageType = pInType; }
175cdf0e10cSrcweir 	//CHINA001 void SetDlgType(sal_uInt16* pInType) { pDlgType = pInType; }
SetPageType(sal_uInt16 nInType)176cdf0e10cSrcweir 	void SetPageType(sal_uInt16 nInType) { nPageType = nInType; } //add CHINA001
SetDlgType(sal_uInt16 nInType)177cdf0e10cSrcweir 	void SetDlgType(sal_uInt16 nInType) { nDlgType = nInType; }//add CHINA001
178cdf0e10cSrcweir 	virtual void PageCreated (SfxAllItemSet aSet); //add CHINA001
179cdf0e10cSrcweir };
180cdf0e10cSrcweir 
181cdf0e10cSrcweir /*************************************************************************
182cdf0e10cSrcweir |*
183cdf0e10cSrcweir |* Fl"achen-Tab-Page
184cdf0e10cSrcweir |*
185cdf0e10cSrcweir \************************************************************************/
186cdf0e10cSrcweir 
187cdf0e10cSrcweir class SvxAreaTabPage : public SvxTabPage
188cdf0e10cSrcweir {
189cdf0e10cSrcweir 	using TabPage::ActivatePage;
190cdf0e10cSrcweir 	using TabPage::DeactivatePage;
191cdf0e10cSrcweir 
192cdf0e10cSrcweir private:
193cdf0e10cSrcweir     FixedLine           aFlProp;
194cdf0e10cSrcweir     ListBox             aTypeLB;
195cdf0e10cSrcweir 
196cdf0e10cSrcweir 	ColorLB             aLbColor;
197cdf0e10cSrcweir 	GradientLB          aLbGradient;
198cdf0e10cSrcweir 	HatchingLB          aLbHatching;
199cdf0e10cSrcweir 	BitmapLB            aLbBitmap;
200cdf0e10cSrcweir 	SvxXRectPreview     aCtlBitmapPreview;
201cdf0e10cSrcweir 
202cdf0e10cSrcweir 	TriStateBox         aTsbStepCount;
203cdf0e10cSrcweir     FixedLine           aFlStepCount;
204cdf0e10cSrcweir 	NumericField        aNumFldStepCount;
205cdf0e10cSrcweir 
206cdf0e10cSrcweir 	CheckBox			aCbxHatchBckgrd;
207cdf0e10cSrcweir 	ColorLB             aLbHatchBckgrdColor;
208cdf0e10cSrcweir 
209cdf0e10cSrcweir     FixedLine           aFlSize;
210cdf0e10cSrcweir 	TriStateBox			aTsbOriginal;
211cdf0e10cSrcweir 	TriStateBox			aTsbScale;
212cdf0e10cSrcweir 	FixedText			aFtXSize;
213cdf0e10cSrcweir 	MetricField			aMtrFldXSize;
214cdf0e10cSrcweir 	FixedText			aFtYSize;
215cdf0e10cSrcweir 	MetricField			aMtrFldYSize;
216cdf0e10cSrcweir     FixedLine           aFlPosition;
217cdf0e10cSrcweir 	SvxRectCtl			aCtlPosition;
218cdf0e10cSrcweir 	FixedText			aFtXOffset;
219cdf0e10cSrcweir 	MetricField			aMtrFldXOffset;
220cdf0e10cSrcweir 	FixedText			aFtYOffset;
221cdf0e10cSrcweir 	MetricField			aMtrFldYOffset;
222cdf0e10cSrcweir 	TriStateBox         aTsbTile;
223cdf0e10cSrcweir 	TriStateBox         aTsbStretch;
224cdf0e10cSrcweir     FixedLine           aFlOffset;
225cdf0e10cSrcweir 	RadioButton			aRbtRow;
226cdf0e10cSrcweir 	RadioButton			aRbtColumn;
227cdf0e10cSrcweir 	MetricField			aMtrFldOffset;
228cdf0e10cSrcweir 
229cdf0e10cSrcweir 	SvxXRectPreview     aCtlXRectPreview;
230cdf0e10cSrcweir 
231cdf0e10cSrcweir 	const SfxItemSet&   rOutAttrs;
232cdf0e10cSrcweir 	RECT_POINT          eRP;
233cdf0e10cSrcweir 
234c7be74b1SArmin Le Grand 	XColorListSharedPtr     maColorTab;
235c7be74b1SArmin Le Grand 	XGradientListSharedPtr  maGradientList;
236c7be74b1SArmin Le Grand 	XHatchListSharedPtr     maHatchingList;
237c7be74b1SArmin Le Grand 	XBitmapListSharedPtr    maBitmapList;
238cdf0e10cSrcweir 
239*b164f441SArmin Le Grand     // Placeholders for pointer-based entries; these will be inited
240*b164f441SArmin Le Grand     // to point to these so that the page is usable without that
241*b164f441SArmin Le Grand     // SvxAreaTabDialog has to call the setter methods (e.g. SetColorChgd).
242*b164f441SArmin Le Grand     // Without that the pages used in SvxAreaTabDialog are not usable
243*b164f441SArmin Le Grand     ChangeType          maFixed_ChangeType;
244*b164f441SArmin Le Grand     sal_Bool            maFixed_sal_Bool;
245*b164f441SArmin Le Grand 
246cdf0e10cSrcweir 	ChangeType*         pnColorTableState;
247cdf0e10cSrcweir 	ChangeType*         pnBitmapListState;
248cdf0e10cSrcweir 	ChangeType*         pnGradientListState;
249cdf0e10cSrcweir 	ChangeType*         pnHatchingListState;
250cdf0e10cSrcweir 
251*b164f441SArmin Le Grand 	sal_uInt16          nPageType;
252*b164f441SArmin Le Grand 	sal_uInt16          nDlgType;
253*b164f441SArmin Le Grand 	sal_uInt16          nPos;
254cdf0e10cSrcweir 
255*b164f441SArmin Le Grand 	sal_Bool*           pbAreaTP;
256cdf0e10cSrcweir 
257cdf0e10cSrcweir 	XOutdevItemPool*    pXPool;
258cdf0e10cSrcweir 	XFillAttrSetItem    aXFillAttr;
259cdf0e10cSrcweir 	SfxItemSet&         rXFSet;
260cdf0e10cSrcweir 
261cdf0e10cSrcweir 	SfxMapUnit			ePoolUnit;
262cdf0e10cSrcweir 	FieldUnit			eFUnit;
263cdf0e10cSrcweir 
264*b164f441SArmin Le Grand     //UUUU
265*b164f441SArmin Le Grand     bool                mbOfferImportButton;
266*b164f441SArmin Le Grand     bool                mbPositionsAdapted;
267*b164f441SArmin Le Grand     bool                mbDirectGraphicSet;
268*b164f441SArmin Le Grand     Graphic             maDirectGraphic;
269*b164f441SArmin Le Grand     String              maDirectName;
270*b164f441SArmin Le Grand     PushButton          maBtnImport;
271*b164f441SArmin Le Grand 
272cdf0e10cSrcweir #ifdef _SVX_TPAREA_CXX
273cdf0e10cSrcweir 	DECL_LINK( SelectDialogTypeHdl_Impl, ListBox * );
274cdf0e10cSrcweir 	DECL_LINK( ClickInvisibleHdl_Impl, void * );
275cdf0e10cSrcweir 	DECL_LINK( ClickColorHdl_Impl, void * );
276cdf0e10cSrcweir 	DECL_LINK( ModifyColorHdl_Impl, void * );
277cdf0e10cSrcweir 	DECL_LINK( ModifyHatchBckgrdColorHdl_Impl, void * );
278cdf0e10cSrcweir 	DECL_LINK( ClickGradientHdl_Impl, void * );
279cdf0e10cSrcweir 	DECL_LINK( ModifyGradientHdl_Impl, void * );
280cdf0e10cSrcweir 	DECL_LINK( ClickHatchingHdl_Impl, void * );
281cdf0e10cSrcweir 	DECL_LINK( ModifyHatchingHdl_Impl, void * );
282cdf0e10cSrcweir 	DECL_LINK( ToggleHatchBckgrdColorHdl_Impl, void * );
283cdf0e10cSrcweir 	DECL_LINK( ClickBitmapHdl_Impl, void * );
284cdf0e10cSrcweir 	DECL_LINK( ModifyBitmapHdl_Impl, void * );
285cdf0e10cSrcweir //	DECL_LINK( ModifyTransparentHdl_Impl, void * );
286cdf0e10cSrcweir 	DECL_LINK( ModifyStepCountHdl_Impl, void * );
287*b164f441SArmin Le Grand 
288*b164f441SArmin Le Grand     //UUUU
289*b164f441SArmin Le Grand     DECL_LINK( ClickImportHdl_Impl, void * );
290*b164f441SArmin Le Grand 
291cdf0e10cSrcweir 	DECL_LINK( ModifyTileHdl_Impl, void * );
292cdf0e10cSrcweir 	DECL_LINK( ClickScaleHdl_Impl, void * );
293cdf0e10cSrcweir #endif
294cdf0e10cSrcweir 
295cdf0e10cSrcweir public:
296*b164f441SArmin Le Grand 	SvxAreaTabPage( Window* pParent, const SfxItemSet& rInAttrs );
297cdf0e10cSrcweir 
298cdf0e10cSrcweir 	void    Construct();
299cdf0e10cSrcweir 
300cdf0e10cSrcweir 	static  SfxTabPage* Create( Window*, const SfxItemSet& );
301cdf0e10cSrcweir 	static  sal_uInt16*	    GetRanges();
302cdf0e10cSrcweir 
303cdf0e10cSrcweir 	virtual sal_Bool FillItemSet( SfxItemSet& );
304cdf0e10cSrcweir 	virtual void Reset( const SfxItemSet & );
305cdf0e10cSrcweir 	virtual void ActivatePage( const SfxItemSet& rSet );
306cdf0e10cSrcweir 	virtual int  DeactivatePage( SfxItemSet* pSet );
307cdf0e10cSrcweir 	virtual void PointChanged( Window* pWindow, RECT_POINT eRP );
308cdf0e10cSrcweir 
SetColorTable(XColorListSharedPtr aColTab)309c7be74b1SArmin Le Grand 	void    SetColorTable( XColorListSharedPtr aColTab ) { maColorTab = aColTab; }
SetGradientList(XGradientListSharedPtr aGrdLst)310c7be74b1SArmin Le Grand 	void    SetGradientList( XGradientListSharedPtr aGrdLst) { maGradientList = aGrdLst; }
SetHatchingList(XHatchListSharedPtr aHtchLst)311c7be74b1SArmin Le Grand 	void    SetHatchingList( XHatchListSharedPtr aHtchLst) { maHatchingList = aHtchLst; }
SetBitmapList(XBitmapListSharedPtr aBmpLst)312c7be74b1SArmin Le Grand 	void    SetBitmapList( XBitmapListSharedPtr aBmpLst) { maBitmapList = aBmpLst; }
313cdf0e10cSrcweir 
314cdf0e10cSrcweir 	//CHINA001 void    SetPageType( sal_uInt16* pInType ) { pPageType = pInType; }
SetPageType(sal_uInt16 nInType)315cdf0e10cSrcweir 	void    SetPageType( sal_uInt16 nInType ) { nPageType = nInType; } //add CHINA001
316cdf0e10cSrcweir 	//CHINA001 void    SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; }
SetDlgType(sal_uInt16 nInType)317cdf0e10cSrcweir 	void    SetDlgType( sal_uInt16 nInType ) { nDlgType = nInType; }//add CHINA001
318cdf0e10cSrcweir 	//CHINA001 void    SetPos( sal_uInt16* pInPos ) { pPos = pInPos; }
SetPos(sal_uInt16 nInPos)319cdf0e10cSrcweir 	void    SetPos( sal_uInt16 nInPos ) { nPos = nInPos; }//add CHINA001
SetAreaTP(sal_Bool * pIn)320cdf0e10cSrcweir 	void    SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; }
321cdf0e10cSrcweir 	virtual void PageCreated (SfxAllItemSet aSet); //add CHINA001
SetColorChgd(ChangeType * pIn)322cdf0e10cSrcweir 	void    SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; }
SetGrdChgd(ChangeType * pIn)323cdf0e10cSrcweir 	void    SetGrdChgd( ChangeType* pIn ) { pnGradientListState = pIn; }
SetHtchChgd(ChangeType * pIn)324cdf0e10cSrcweir 	void    SetHtchChgd( ChangeType* pIn ) { pnHatchingListState = pIn; }
SetBmpChgd(ChangeType * pIn)325cdf0e10cSrcweir 	void    SetBmpChgd( ChangeType* pIn ) { pnBitmapListState = pIn; }
326cdf0e10cSrcweir };
327cdf0e10cSrcweir 
328cdf0e10cSrcweir /*************************************************************************
329cdf0e10cSrcweir |*
330cdf0e10cSrcweir |* Schatten-Tab-Page
331cdf0e10cSrcweir |*
332cdf0e10cSrcweir \************************************************************************/
333cdf0e10cSrcweir 
334cdf0e10cSrcweir class SvxShadowTabPage : public SvxTabPage
335cdf0e10cSrcweir {
336cdf0e10cSrcweir 	using TabPage::ActivatePage;
337cdf0e10cSrcweir 	using TabPage::DeactivatePage;
338cdf0e10cSrcweir 
339cdf0e10cSrcweir private:
340cdf0e10cSrcweir     FixedLine           aFlProp;
341cdf0e10cSrcweir     TriStateBox         aTsbShowShadow;
342cdf0e10cSrcweir 	FixedText           aFtPosition;
343cdf0e10cSrcweir 	SvxRectCtl          aCtlPosition;
344cdf0e10cSrcweir 	FixedText           aFtDistance;
345cdf0e10cSrcweir 	MetricField         aMtrDistance;
346cdf0e10cSrcweir 	FixedText           aFtShadowColor;
347cdf0e10cSrcweir 	ColorLB             aLbShadowColor;
348cdf0e10cSrcweir 	FixedText           aFtTransparent;
349cdf0e10cSrcweir 	MetricField         aMtrTransparent;
350cdf0e10cSrcweir 	SvxXShadowPreview	aCtlXRectPreview;
351cdf0e10cSrcweir 
352cdf0e10cSrcweir 	const SfxItemSet&   rOutAttrs;
353cdf0e10cSrcweir 	RECT_POINT          eRP;
354cdf0e10cSrcweir 
355c7be74b1SArmin Le Grand 	XColorListSharedPtr maColorTab;
356cdf0e10cSrcweir 	ChangeType*         pnColorTableState;
357cdf0e10cSrcweir 	sal_uInt16				nPageType;	//add CHINA001
358cdf0e10cSrcweir 	sal_uInt16				nDlgType;	//add CHINA001
359cdf0e10cSrcweir 	sal_uInt16*             pPos;
360cdf0e10cSrcweir 	sal_Bool*               pbAreaTP;
361cdf0e10cSrcweir 
362cdf0e10cSrcweir 	sal_Bool				bDisable;
363cdf0e10cSrcweir 
364cdf0e10cSrcweir 	XOutdevItemPool*    pXPool;
365cdf0e10cSrcweir 	XFillAttrSetItem    aXFillAttr;
366cdf0e10cSrcweir 	SfxItemSet&         rXFSet;
367cdf0e10cSrcweir 	SfxMapUnit			ePoolUnit;
368cdf0e10cSrcweir 
369cdf0e10cSrcweir #ifdef _SVX_TPSHADOW_CXX
370cdf0e10cSrcweir 	DECL_LINK( ClickShadowHdl_Impl, void * );
371cdf0e10cSrcweir 	DECL_LINK( ModifyShadowHdl_Impl, void * );
372cdf0e10cSrcweir #endif
373cdf0e10cSrcweir 
374cdf0e10cSrcweir public:
375cdf0e10cSrcweir 	SvxShadowTabPage( Window* pParent, const SfxItemSet& rInAttrs  );
376cdf0e10cSrcweir 
377cdf0e10cSrcweir 	void    Construct();
378cdf0e10cSrcweir 	static  SfxTabPage* Create( Window*, const SfxItemSet& );
379cdf0e10cSrcweir 	static  sal_uInt16*	    GetRanges();
380cdf0e10cSrcweir 
381cdf0e10cSrcweir 	virtual sal_Bool FillItemSet( SfxItemSet& );
382cdf0e10cSrcweir 	virtual void Reset( const SfxItemSet & );
383cdf0e10cSrcweir 	virtual void ActivatePage( const SfxItemSet& rSet );
384cdf0e10cSrcweir 	virtual int  DeactivatePage( SfxItemSet* pSet );
385cdf0e10cSrcweir 	virtual void PointChanged( Window* pWindow, RECT_POINT eRP );
386cdf0e10cSrcweir 
SetColorTable(XColorListSharedPtr aColTab)387c7be74b1SArmin Le Grand 	void    SetColorTable( XColorListSharedPtr aColTab ) { maColorTab = aColTab; }
388cdf0e10cSrcweir //CHINA001	void    SetPageType( sal_uInt16* pInType ) { pPageType = pInType; }
389cdf0e10cSrcweir //CHINA001	void    SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; }
SetPageType(sal_uInt16 nInType)390cdf0e10cSrcweir 	void    SetPageType( sal_uInt16 nInType ) { nPageType = nInType; } //add CHINA001
SetDlgType(sal_uInt16 nInType)391cdf0e10cSrcweir 	void    SetDlgType( sal_uInt16 nInType ) { nDlgType = nInType; }	//add CHINA001
SetAreaTP(sal_Bool * pIn)392cdf0e10cSrcweir 	void    SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; }
SetColorChgd(ChangeType * pIn)393cdf0e10cSrcweir 	void    SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; }
394cdf0e10cSrcweir 	virtual void PageCreated (SfxAllItemSet aSet); //add CHINA001
DisablePage(sal_Bool bIn)395cdf0e10cSrcweir 	void	DisablePage( sal_Bool bIn ) { bDisable = bIn; }
396cdf0e10cSrcweir };
397cdf0e10cSrcweir 
398cdf0e10cSrcweir /*************************************************************************
399cdf0e10cSrcweir |*
400cdf0e10cSrcweir |* Farbverlauf-Tab-Page
401cdf0e10cSrcweir |*
402cdf0e10cSrcweir \************************************************************************/
403cdf0e10cSrcweir 
404cdf0e10cSrcweir class SvxGradientTabPage : public SfxTabPage
405cdf0e10cSrcweir {
406cdf0e10cSrcweir 	using TabPage::ActivatePage;
407cdf0e10cSrcweir 	using TabPage::DeactivatePage;
408cdf0e10cSrcweir 
409cdf0e10cSrcweir private:
410cdf0e10cSrcweir     FixedLine           aFlProp;
411cdf0e10cSrcweir 	FixedText           aFtType;
412cdf0e10cSrcweir 	ListBox             aLbGradientType;
413cdf0e10cSrcweir 	FixedText           aFtCenterX;
414cdf0e10cSrcweir 	MetricField         aMtrCenterX;
415cdf0e10cSrcweir 	FixedText           aFtCenterY;
416cdf0e10cSrcweir 	MetricField         aMtrCenterY;
417cdf0e10cSrcweir 	FixedText           aFtAngle;
418cdf0e10cSrcweir 	MetricField         aMtrAngle;
419cdf0e10cSrcweir 	FixedText           aFtBorder;
420cdf0e10cSrcweir 	MetricField         aMtrBorder;
421cdf0e10cSrcweir 	FixedText           aFtColorFrom;
422cdf0e10cSrcweir 	ColorLB             aLbColorFrom;
423cdf0e10cSrcweir 	MetricField         aMtrColorFrom;
424cdf0e10cSrcweir 	FixedText           aFtColorTo;
425cdf0e10cSrcweir 	ColorLB             aLbColorTo;
426cdf0e10cSrcweir 	MetricField         aMtrColorTo;
427cdf0e10cSrcweir 	GradientLB          aLbGradients;
428cdf0e10cSrcweir 	SvxXRectPreview     aCtlPreview;
429cdf0e10cSrcweir 	PushButton          aBtnAdd;
430cdf0e10cSrcweir 	PushButton          aBtnModify;
431cdf0e10cSrcweir 	PushButton          aBtnDelete;
432cdf0e10cSrcweir 	ImageButton         aBtnLoad;
433cdf0e10cSrcweir 	ImageButton         aBtnSave;
434cdf0e10cSrcweir 
435cdf0e10cSrcweir 	const SfxItemSet&   rOutAttrs;
436cdf0e10cSrcweir 
437c7be74b1SArmin Le Grand 	XColorListSharedPtr     maColorTab;
438c7be74b1SArmin Le Grand 	XGradientListSharedPtr  maGradientList;
439cdf0e10cSrcweir 
440cdf0e10cSrcweir 	ChangeType*         pnGradientListState;
441cdf0e10cSrcweir 	ChangeType*         pnColorTableState;
442cdf0e10cSrcweir 	sal_uInt16*             pPageType;
443cdf0e10cSrcweir 	sal_uInt16*             pDlgType;
444cdf0e10cSrcweir 	sal_uInt16*             pPos;
445cdf0e10cSrcweir 	sal_Bool*               pbAreaTP;
446cdf0e10cSrcweir 
447cdf0e10cSrcweir 	XOutdevItemPool*    pXPool;
448cdf0e10cSrcweir 	XFillStyleItem      aXFStyleItem;
449cdf0e10cSrcweir 	XFillGradientItem   aXGradientItem;
450cdf0e10cSrcweir 	XFillAttrSetItem    aXFillAttr;
451cdf0e10cSrcweir 	SfxItemSet&         rXFSet;
452cdf0e10cSrcweir 
453cdf0e10cSrcweir #ifdef _SVX_TPGRADNT_CXX
454cdf0e10cSrcweir 	DECL_LINK( ClickAddHdl_Impl, void * );
455cdf0e10cSrcweir 	DECL_LINK( ClickModifyHdl_Impl, void * );
456cdf0e10cSrcweir 	DECL_LINK( ClickDeleteHdl_Impl, void * );
457cdf0e10cSrcweir 	DECL_LINK( ChangeGradientHdl_Impl, void * );
458cdf0e10cSrcweir 	DECL_LINK( ModifiedHdl_Impl, void * );
459cdf0e10cSrcweir 	DECL_LINK( ClickLoadHdl_Impl, void * );
460cdf0e10cSrcweir 	DECL_LINK( ClickSaveHdl_Impl, void * );
461cdf0e10cSrcweir 
462cdf0e10cSrcweir 	long CheckChanges_Impl();
463cdf0e10cSrcweir 	void SetControlState_Impl( XGradientStyle eXGS );
464cdf0e10cSrcweir #endif
465cdf0e10cSrcweir 
466cdf0e10cSrcweir public:
467cdf0e10cSrcweir 	SvxGradientTabPage( Window* pParent, const SfxItemSet& rInAttrs  );
468cdf0e10cSrcweir 
469cdf0e10cSrcweir 	void    Construct();
470cdf0e10cSrcweir 
471cdf0e10cSrcweir 	static  SfxTabPage* Create( Window*, const SfxItemSet& );
472cdf0e10cSrcweir 	virtual sal_Bool FillItemSet( SfxItemSet& );
473cdf0e10cSrcweir 	virtual void Reset( const SfxItemSet & );
474cdf0e10cSrcweir 
475cdf0e10cSrcweir 	virtual void ActivatePage( const SfxItemSet& rSet );
476cdf0e10cSrcweir 	virtual int  DeactivatePage( SfxItemSet* pSet );
477cdf0e10cSrcweir 
SetColorTable(XColorListSharedPtr aColTab)478c7be74b1SArmin Le Grand 	void    SetColorTable( XColorListSharedPtr aColTab ) { maColorTab = aColTab; }
SetGradientList(XGradientListSharedPtr aGrdLst)479c7be74b1SArmin Le Grand 	void    SetGradientList( XGradientListSharedPtr aGrdLst) { maGradientList = aGrdLst; }
480cdf0e10cSrcweir 
SetPageType(sal_uInt16 * pInType)481cdf0e10cSrcweir 	void    SetPageType( sal_uInt16* pInType ) { pPageType = pInType; }
SetDlgType(sal_uInt16 * pInType)482cdf0e10cSrcweir 	void    SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; }
SetPos(sal_uInt16 * pInPos)483cdf0e10cSrcweir 	void    SetPos( sal_uInt16* pInPos ) { pPos = pInPos; }
SetAreaTP(sal_Bool * pIn)484cdf0e10cSrcweir 	void    SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; }
485cdf0e10cSrcweir 
SetGrdChgd(ChangeType * pIn)486cdf0e10cSrcweir 	void    SetGrdChgd( ChangeType* pIn ) { pnGradientListState = pIn; }
SetColorChgd(ChangeType * pIn)487cdf0e10cSrcweir 	void    SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; }
488cdf0e10cSrcweir };
489cdf0e10cSrcweir 
490cdf0e10cSrcweir /*************************************************************************
491cdf0e10cSrcweir |*
492cdf0e10cSrcweir |* Schraffuren-Tab-Page
493cdf0e10cSrcweir |*
494cdf0e10cSrcweir \************************************************************************/
495cdf0e10cSrcweir 
496cdf0e10cSrcweir class SvxHatchTabPage : public SvxTabPage
497cdf0e10cSrcweir {
498cdf0e10cSrcweir 	using TabPage::ActivatePage;
499cdf0e10cSrcweir 	using TabPage::DeactivatePage;
500cdf0e10cSrcweir 
501cdf0e10cSrcweir private:
502cdf0e10cSrcweir 	FixedText           aFtDistance;
503cdf0e10cSrcweir 	MetricField         aMtrDistance;
504cdf0e10cSrcweir 	FixedText           aFtAngle;
505cdf0e10cSrcweir 	MetricField         aMtrAngle;
506cdf0e10cSrcweir 	SvxRectCtl          aCtlAngle;
507cdf0e10cSrcweir     FixedLine           aFlProp;
508cdf0e10cSrcweir 	FixedText           aFtLineType;
509cdf0e10cSrcweir 	ListBox             aLbLineType;
510cdf0e10cSrcweir 	FixedText           aFtLineColor;
511cdf0e10cSrcweir 	ColorLB             aLbLineColor;
512cdf0e10cSrcweir 	HatchingLB          aLbHatchings;
513cdf0e10cSrcweir 	SvxXRectPreview     aCtlPreview;
514cdf0e10cSrcweir 	PushButton          aBtnAdd;
515cdf0e10cSrcweir 	PushButton          aBtnModify;
516cdf0e10cSrcweir 	PushButton          aBtnDelete;
517cdf0e10cSrcweir 	ImageButton         aBtnLoad;
518cdf0e10cSrcweir 	ImageButton         aBtnSave;
519cdf0e10cSrcweir 
520cdf0e10cSrcweir 	const SfxItemSet&   rOutAttrs;
521cdf0e10cSrcweir 	RECT_POINT          eRP;
522cdf0e10cSrcweir 
523c7be74b1SArmin Le Grand 	XColorListSharedPtr maColorTab;
524c7be74b1SArmin Le Grand 	XHatchListSharedPtr maHatchingList;
525cdf0e10cSrcweir 
526cdf0e10cSrcweir 	ChangeType*         pnHatchingListState;
527cdf0e10cSrcweir 	ChangeType*         pnColorTableState;
528cdf0e10cSrcweir 	sal_uInt16*             pPageType;
529cdf0e10cSrcweir 	sal_uInt16*             pDlgType;
530cdf0e10cSrcweir 	sal_uInt16*             pPos;
531cdf0e10cSrcweir 	sal_Bool*               pbAreaTP;
532cdf0e10cSrcweir 
533cdf0e10cSrcweir 	XOutdevItemPool*    pXPool;
534cdf0e10cSrcweir 	XFillStyleItem      aXFStyleItem;
535cdf0e10cSrcweir 	XFillHatchItem      aXHatchItem;
536cdf0e10cSrcweir 	XFillAttrSetItem    aXFillAttr;
537cdf0e10cSrcweir 	SfxItemSet&         rXFSet;
538cdf0e10cSrcweir 
539cdf0e10cSrcweir 	SfxMapUnit			ePoolUnit;
540cdf0e10cSrcweir 
541cdf0e10cSrcweir #ifdef _SVX_TPHATCH_CXX
542cdf0e10cSrcweir 	DECL_LINK( ChangeHatchHdl_Impl, void * );
543cdf0e10cSrcweir 	DECL_LINK( ModifiedHdl_Impl, void * );
544cdf0e10cSrcweir 	DECL_LINK( ClickAddHdl_Impl, void * );
545cdf0e10cSrcweir 	DECL_LINK( ClickModifyHdl_Impl, void * );
546cdf0e10cSrcweir 	DECL_LINK( ClickDeleteHdl_Impl, void * );
547cdf0e10cSrcweir 	DECL_LINK( ClickLoadHdl_Impl, void * );
548cdf0e10cSrcweir 	DECL_LINK( ClickSaveHdl_Impl, void * );
549cdf0e10cSrcweir 
550cdf0e10cSrcweir 	long CheckChanges_Impl();
551cdf0e10cSrcweir #endif
552cdf0e10cSrcweir 
553cdf0e10cSrcweir public:
554cdf0e10cSrcweir 	SvxHatchTabPage( Window* pParent, const SfxItemSet& rInAttrs  );
555cdf0e10cSrcweir 
556cdf0e10cSrcweir 	void    Construct();
557cdf0e10cSrcweir 
558cdf0e10cSrcweir 	static  SfxTabPage* Create( Window*, const SfxItemSet& );
559cdf0e10cSrcweir 	virtual sal_Bool FillItemSet( SfxItemSet& );
560cdf0e10cSrcweir 	virtual void Reset( const SfxItemSet & );
561cdf0e10cSrcweir 
562cdf0e10cSrcweir 	virtual void ActivatePage( const SfxItemSet& rSet );
563cdf0e10cSrcweir 	virtual int  DeactivatePage( SfxItemSet* pSet );
564cdf0e10cSrcweir 
565cdf0e10cSrcweir 	virtual void PointChanged( Window* pWindow, RECT_POINT eRP );
566cdf0e10cSrcweir 
SetColorTable(XColorListSharedPtr aColTab)567c7be74b1SArmin Le Grand 	void    SetColorTable( XColorListSharedPtr aColTab ) { maColorTab = aColTab; }
SetHatchingList(XHatchListSharedPtr aHtchLst)568c7be74b1SArmin Le Grand 	void    SetHatchingList( XHatchListSharedPtr aHtchLst) { maHatchingList = aHtchLst; }
569cdf0e10cSrcweir 
SetPageType(sal_uInt16 * pInType)570cdf0e10cSrcweir 	void    SetPageType( sal_uInt16* pInType ) { pPageType = pInType; }
SetDlgType(sal_uInt16 * pInType)571cdf0e10cSrcweir 	void    SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; }
SetPos(sal_uInt16 * pInPos)572cdf0e10cSrcweir 	void    SetPos( sal_uInt16* pInPos ) { pPos = pInPos; }
SetAreaTP(sal_Bool * pIn)573cdf0e10cSrcweir 	void    SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; }
574cdf0e10cSrcweir 
SetHtchChgd(ChangeType * pIn)575cdf0e10cSrcweir 	void    SetHtchChgd( ChangeType* pIn ) { pnHatchingListState = pIn; }
SetColorChgd(ChangeType * pIn)576cdf0e10cSrcweir 	void    SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; }
577cdf0e10cSrcweir 
578cdf0e10cSrcweir 	virtual void		DataChanged( const DataChangedEvent& rDCEvt );
579cdf0e10cSrcweir };
580cdf0e10cSrcweir 
581cdf0e10cSrcweir /*************************************************************************
582cdf0e10cSrcweir |*
583cdf0e10cSrcweir |* Bitmap-Tab-Page
584cdf0e10cSrcweir |*
585cdf0e10cSrcweir \************************************************************************/
586cdf0e10cSrcweir 
587cdf0e10cSrcweir class SvxBitmapTabPage : public SvxTabPage
588cdf0e10cSrcweir {
589cdf0e10cSrcweir 	using TabPage::ActivatePage;
590cdf0e10cSrcweir 	using TabPage::DeactivatePage;
591cdf0e10cSrcweir 
592cdf0e10cSrcweir private:
593cdf0e10cSrcweir 	SvxPixelCtl         aCtlPixel;
594cdf0e10cSrcweir     FixedText           aFtPixelEdit;
595cdf0e10cSrcweir 	FixedText           aFtColor;
596cdf0e10cSrcweir 	ColorLB             aLbColor;
597cdf0e10cSrcweir 	FixedText           aFtBackgroundColor;
598cdf0e10cSrcweir 	ColorLB             aLbBackgroundColor;
599cdf0e10cSrcweir 	FixedText           aLbBitmapsHidden;
600cdf0e10cSrcweir 	BitmapLB            aLbBitmaps;
601cdf0e10cSrcweir     FixedLine           aFlProp;
602cdf0e10cSrcweir 	SvxXRectPreview     aCtlPreview;
603cdf0e10cSrcweir 	PushButton          aBtnAdd;
604cdf0e10cSrcweir 	PushButton          aBtnModify;
605cdf0e10cSrcweir 	PushButton          aBtnImport;
606cdf0e10cSrcweir 	PushButton          aBtnDelete;
607cdf0e10cSrcweir 	ImageButton         aBtnLoad;
608cdf0e10cSrcweir 	ImageButton         aBtnSave;
609cdf0e10cSrcweir 
610cdf0e10cSrcweir 	SvxBitmapCtl        aBitmapCtl;
611cdf0e10cSrcweir 
612cdf0e10cSrcweir 	const SfxItemSet&   rOutAttrs;
613cdf0e10cSrcweir 
614c7be74b1SArmin Le Grand 	XColorListSharedPtr     maColorTab;
615c7be74b1SArmin Le Grand 	XBitmapListSharedPtr    maBitmapList;
616cdf0e10cSrcweir 
617cdf0e10cSrcweir 	ChangeType*         pnBitmapListState;
618cdf0e10cSrcweir 	ChangeType*         pnColorTableState;
619cdf0e10cSrcweir 	sal_uInt16*             pPageType;
620cdf0e10cSrcweir 	sal_uInt16*             pDlgType;
621cdf0e10cSrcweir 	sal_uInt16*             pPos;
622cdf0e10cSrcweir 	sal_Bool*               pbAreaTP;
623cdf0e10cSrcweir 
624cdf0e10cSrcweir 	sal_Bool                bBmpChanged;
625cdf0e10cSrcweir 
626cdf0e10cSrcweir 	XOutdevItemPool*    pXPool;
627cdf0e10cSrcweir 	XFillStyleItem      aXFStyleItem;
628cdf0e10cSrcweir 	XFillBitmapItem     aXBitmapItem;
629cdf0e10cSrcweir 	XFillAttrSetItem    aXFillAttr;
630cdf0e10cSrcweir 	SfxItemSet&         rXFSet;
631cdf0e10cSrcweir 
632cdf0e10cSrcweir #ifdef _SVX_TPBITMAP_CXX
633cdf0e10cSrcweir 	DECL_LINK( ClickAddHdl_Impl, void * );
634cdf0e10cSrcweir 	DECL_LINK( ClickImportHdl_Impl, void * );
635cdf0e10cSrcweir 	DECL_LINK( ClickModifyHdl_Impl, void * );
636cdf0e10cSrcweir 	DECL_LINK( ClickDeleteHdl_Impl, void * );
637cdf0e10cSrcweir 	DECL_LINK( ChangeBitmapHdl_Impl, void * );
638cdf0e10cSrcweir 	DECL_LINK( ChangePixelColorHdl_Impl, void * );
639cdf0e10cSrcweir 	DECL_LINK( ChangeBackgrndColorHdl_Impl, void * );
640cdf0e10cSrcweir 	DECL_LINK( ClickLoadHdl_Impl, void * );
641cdf0e10cSrcweir 	DECL_LINK( ClickSaveHdl_Impl, void * );
642cdf0e10cSrcweir 
643cdf0e10cSrcweir 	long CheckChanges_Impl();
644cdf0e10cSrcweir #endif
645cdf0e10cSrcweir 
646cdf0e10cSrcweir public:
647cdf0e10cSrcweir 	SvxBitmapTabPage( Window* pParent, const SfxItemSet& rInAttrs  );
648cdf0e10cSrcweir 
649cdf0e10cSrcweir 	void    Construct();
650cdf0e10cSrcweir 
651cdf0e10cSrcweir 	static  SfxTabPage* Create( Window*, const SfxItemSet& );
652cdf0e10cSrcweir 	virtual sal_Bool FillItemSet( SfxItemSet& );
653cdf0e10cSrcweir 	virtual void Reset( const SfxItemSet & );
654cdf0e10cSrcweir 
655cdf0e10cSrcweir 	virtual void ActivatePage( const SfxItemSet& rSet );
656cdf0e10cSrcweir 	virtual int  DeactivatePage( SfxItemSet* pSet );
657cdf0e10cSrcweir 
658cdf0e10cSrcweir 	virtual void PointChanged( Window* pWindow, RECT_POINT eRP );
659cdf0e10cSrcweir 
SetColorTable(XColorListSharedPtr aColTab)660c7be74b1SArmin Le Grand 	void    SetColorTable( XColorListSharedPtr aColTab ) { maColorTab = aColTab; }
SetBitmapList(XBitmapListSharedPtr aBmpLst)661c7be74b1SArmin Le Grand 	void    SetBitmapList( XBitmapListSharedPtr aBmpLst) { maBitmapList = aBmpLst; }
662cdf0e10cSrcweir 
SetPageType(sal_uInt16 * pInType)663cdf0e10cSrcweir 	void    SetPageType( sal_uInt16* pInType ) { pPageType = pInType; }
SetDlgType(sal_uInt16 * pInType)664cdf0e10cSrcweir 	void    SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; }
SetPos(sal_uInt16 * pInPos)665cdf0e10cSrcweir 	void    SetPos( sal_uInt16* pInPos ) { pPos = pInPos; }
SetAreaTP(sal_Bool * pIn)666cdf0e10cSrcweir 	void    SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; }
667cdf0e10cSrcweir 
SetBmpChgd(ChangeType * pIn)668cdf0e10cSrcweir 	void    SetBmpChgd( ChangeType* pIn ) { pnBitmapListState = pIn; }
SetColorChgd(ChangeType * pIn)669cdf0e10cSrcweir 	void    SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; }
670cdf0e10cSrcweir 
671cdf0e10cSrcweir     /** Return a label that is associated with the given control.  This
672cdf0e10cSrcweir         label is used to the determine the name for the control.
673cdf0e10cSrcweir         @param pLabeled
674cdf0e10cSrcweir             The control for which to return a label.
675cdf0e10cSrcweir         @return
676cdf0e10cSrcweir             Return a label control that provides a name for the specified
677cdf0e10cSrcweir             control.
678cdf0e10cSrcweir     */
679cdf0e10cSrcweir     virtual Window*	GetParentLabeledBy( const Window* pLabeled ) const;
680cdf0e10cSrcweir };
681cdf0e10cSrcweir 
682cdf0e10cSrcweir /*************************************************************************
683cdf0e10cSrcweir |*
684cdf0e10cSrcweir |* Farben-Tab-Page
685cdf0e10cSrcweir |*
686cdf0e10cSrcweir \************************************************************************/
687cdf0e10cSrcweir 
688cdf0e10cSrcweir class SvxColorTabPage : public SfxTabPage
689cdf0e10cSrcweir {
690cdf0e10cSrcweir 	using TabPage::ActivatePage;
691cdf0e10cSrcweir 	using TabPage::DeactivatePage;
692cdf0e10cSrcweir 
693cdf0e10cSrcweir private:
694cdf0e10cSrcweir     FixedLine           aFlProp;
695cdf0e10cSrcweir 	FixedText           aFtName;
696cdf0e10cSrcweir 	Edit                aEdtName;
697cdf0e10cSrcweir     FixedText           aFtColor;
698cdf0e10cSrcweir 	ColorLB             aLbColor;
699cdf0e10cSrcweir 
700cdf0e10cSrcweir     FixedText           aTableNameFT;
70128bcfa49SArmin Le Grand     SvxColorValueSet    aValSetColorTable;
702cdf0e10cSrcweir 
703cdf0e10cSrcweir     SvxXRectPreview     aCtlPreviewOld;
704cdf0e10cSrcweir 	SvxXRectPreview     aCtlPreviewNew;
705cdf0e10cSrcweir 
706cdf0e10cSrcweir     ListBox             aLbColorModel;
707cdf0e10cSrcweir     FixedText           aFtColorModel1;
708cdf0e10cSrcweir 	MetricField         aMtrFldColorModel1;
709cdf0e10cSrcweir     FixedText           aFtColorModel2;
710cdf0e10cSrcweir 	MetricField         aMtrFldColorModel2;
711cdf0e10cSrcweir     FixedText           aFtColorModel3;
712cdf0e10cSrcweir 	MetricField         aMtrFldColorModel3;
713cdf0e10cSrcweir 
714cdf0e10cSrcweir     FixedText           aFtColorModel4;
715cdf0e10cSrcweir 	MetricField         aMtrFldColorModel4;
716cdf0e10cSrcweir 
717cdf0e10cSrcweir     PushButton          aBtnAdd;
718cdf0e10cSrcweir 	PushButton          aBtnModify;
719cdf0e10cSrcweir 	PushButton          aBtnWorkOn;
720cdf0e10cSrcweir 	PushButton          aBtnDelete;
721cdf0e10cSrcweir 	ImageButton         aBtnLoad;
722cdf0e10cSrcweir 	ImageButton         aBtnSave;
723cdf0e10cSrcweir 
724cdf0e10cSrcweir 	const SfxItemSet&   rOutAttrs;
725cdf0e10cSrcweir 
726c7be74b1SArmin Le Grand 	XColorListSharedPtr maColorTab;
727cdf0e10cSrcweir 
728cdf0e10cSrcweir 	ChangeType*         pnColorTableState;
729cdf0e10cSrcweir 	sal_uInt16*             pPageType;
730cdf0e10cSrcweir 	sal_uInt16*             pDlgType;
731cdf0e10cSrcweir 	sal_uInt16*             pPos;
732cdf0e10cSrcweir 	sal_Bool*               pbAreaTP;
733cdf0e10cSrcweir 
734cdf0e10cSrcweir 	XOutdevItemPool*    pXPool;
735cdf0e10cSrcweir 	XFillStyleItem      aXFStyleItem;
736cdf0e10cSrcweir 	XFillColorItem      aXFillColorItem;
737cdf0e10cSrcweir 	XFillAttrSetItem    aXFillAttr;
738cdf0e10cSrcweir 	SfxItemSet&         rXFSet;
739cdf0e10cSrcweir 
740cdf0e10cSrcweir 	ColorModel          eCM;
741cdf0e10cSrcweir 
742cdf0e10cSrcweir 	Color				aAktuellColor;
743cdf0e10cSrcweir 
744cdf0e10cSrcweir #ifdef _SVX_TPCOLOR_CXX
745cdf0e10cSrcweir 	void    ConvertColorValues (Color& rColor, ColorModel eModell);
746cdf0e10cSrcweir 	void    RgbToCmyk_Impl( Color& rColor, sal_uInt16& rK );
747cdf0e10cSrcweir 	void    CmykToRgb_Impl( Color& rColor, const sal_uInt16 nKey );
748cdf0e10cSrcweir 	sal_uInt16  ColorToPercent_Impl( sal_uInt16 nColor );
749cdf0e10cSrcweir 	sal_uInt16  PercentToColor_Impl( sal_uInt16 nPercent );
750cdf0e10cSrcweir 
75128bcfa49SArmin Le Grand     void ImpColorCountChanged();
75228bcfa49SArmin Le Grand 
753cdf0e10cSrcweir 	//-----------------------------------------------------------------------------------------------------
754cdf0e10cSrcweir 	DECL_LINK( ClickAddHdl_Impl, void * );		// Button 'Hinzufuegen'
755cdf0e10cSrcweir 	DECL_LINK( ClickModifyHdl_Impl, void * );	// Button 'Aendern'
756cdf0e10cSrcweir 	DECL_LINK( ClickDeleteHdl_Impl, void * );	// Button 'loeschen'
757cdf0e10cSrcweir 	DECL_LINK( ClickWorkOnHdl_Impl, void * );	// Button 'Bearbeiten'
758cdf0e10cSrcweir 
759cdf0e10cSrcweir 	DECL_LINK( SelectColorLBHdl_Impl, void * );	// Farbe aus Listbox ausw�hlen
760cdf0e10cSrcweir 	DECL_LINK( SelectValSetHdl_Impl, void * );	// Farbe aus Farbpalette (links) ausw�hlen
761cdf0e10cSrcweir 	DECL_LINK( SelectColorModelHdl_Impl, void * );	// Auswahl Listbox 'Farbmodell'
762cdf0e10cSrcweir 	long ChangeColorHdl_Impl( void* p );
763cdf0e10cSrcweir 	DECL_LINK( ModifiedHdl_Impl, void * );		// Inhalt der Farbwerte-Felder wurde ver�ndert
764cdf0e10cSrcweir 	DECL_LINK( ClickLoadHdl_Impl, void * );		// Button 'Farbtabelle laden'
765cdf0e10cSrcweir 	DECL_LINK( ClickSaveHdl_Impl, void * );		// Button 'Farbtabelle sichern'
766cdf0e10cSrcweir 
767cdf0e10cSrcweir 	long CheckChanges_Impl();
768cdf0e10cSrcweir #endif
769cdf0e10cSrcweir 
770cdf0e10cSrcweir public:
771cdf0e10cSrcweir 	SvxColorTabPage( Window* pParent, const SfxItemSet& rInAttrs  );
772cdf0e10cSrcweir 
773cdf0e10cSrcweir 	void    Construct();
774cdf0e10cSrcweir 
775cdf0e10cSrcweir 	static  SfxTabPage* Create( Window*, const SfxItemSet& );
776cdf0e10cSrcweir 	virtual sal_Bool FillItemSet( SfxItemSet& );
777cdf0e10cSrcweir 	virtual void Reset( const SfxItemSet & );
778cdf0e10cSrcweir 
779cdf0e10cSrcweir 	virtual void ActivatePage( const SfxItemSet& rSet );
780cdf0e10cSrcweir 	virtual int  DeactivatePage( SfxItemSet* pSet );
781cdf0e10cSrcweir 
SetColorTable(XColorListSharedPtr aColTab)782c7be74b1SArmin Le Grand 	void    SetColorTable( XColorListSharedPtr aColTab ) { maColorTab = aColTab; }
783cdf0e10cSrcweir 
SetPageType(sal_uInt16 * pInType)784cdf0e10cSrcweir 	void    SetPageType( sal_uInt16* pInType ) { pPageType = pInType; }
SetDlgType(sal_uInt16 * pInType)785cdf0e10cSrcweir 	void    SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; }
SetPos(sal_uInt16 * pInPos)786cdf0e10cSrcweir 	void    SetPos( sal_uInt16* pInPos ) { pPos = pInPos; }
SetAreaTP(sal_Bool * pIn)787cdf0e10cSrcweir 	void    SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; }
788cdf0e10cSrcweir 
SetColorChgd(ChangeType * pIn)789cdf0e10cSrcweir 	void    SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; }
790cdf0e10cSrcweir 
791cdf0e10cSrcweir 	virtual void FillUserData();
792cdf0e10cSrcweir };
793cdf0e10cSrcweir 
794cdf0e10cSrcweir 
795cdf0e10cSrcweir #endif // _CUI_TAB_AREA_HXX
796cdf0e10cSrcweir 
797