1 /************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27 #ifndef _ENVFMT_HXX 28 #define _ENVFMT_HXX 29 30 31 #ifndef _SVSTDARR_HXX 32 #define _SVSTDARR_USHORTS 33 #include <svl/svstdarr.hxx> 34 #endif 35 #include <svtools/stdctrl.hxx> 36 #ifndef _FIELD_HXX //autogen 37 #include <vcl/field.hxx> 38 #endif 39 #ifndef _MENUBTN_HXX //autogen 40 #include <vcl/menubtn.hxx> 41 #endif 42 #ifndef _GROUP_HXX //autogen 43 #include <vcl/group.hxx> 44 #endif 45 46 #include "envlop.hxx" 47 48 class SwTxtFmtColl; 49 50 // class SwEnvFmtPage --------------------------------------------------------- 51 52 class SwEnvFmtPage : public SfxTabPage 53 { 54 55 FixedLine aAddrFL; 56 FixedInfo aAddrPosInfo; 57 FixedText aAddrLeftText; 58 MetricField aAddrLeftField; 59 FixedText aAddrTopText; 60 MetricField aAddrTopField; 61 FixedInfo aAddrFormatInfo; 62 MenuButton aAddrEditButton; 63 FixedLine aSendFL; 64 FixedInfo aSendPosInfo; 65 FixedText aSendLeftText; 66 MetricField aSendLeftField; 67 FixedText aSendTopText; 68 MetricField aSendTopField; 69 FixedInfo aSendFormatInfo; 70 MenuButton aSendEditButton; 71 FixedLine aSizeFL; 72 FixedText aSizeFormatText; 73 ListBox aSizeFormatBox; 74 FixedText aSizeWidthText; 75 MetricField aSizeWidthField; 76 FixedText aSizeHeightText; 77 MetricField aSizeHeightField; 78 SwEnvPreview aPreview; 79 80 SvUShorts aIDs; 81 82 SwEnvFmtPage(Window* pParent, const SfxItemSet& rSet); 83 ~SwEnvFmtPage(); 84 85 DECL_LINK( ModifyHdl, Edit * ); 86 DECL_LINK( EditHdl, MenuButton * ); 87 DECL_LINK( FormatHdl, ListBox * ); 88 89 void SetMinMax(); 90 91 SfxItemSet *GetCollItemSet(SwTxtFmtColl* pColl, sal_Bool bSender); 92 93 using Window::GetParent; 94 SwEnvDlg *GetParent() {return (SwEnvDlg*) SfxTabPage::GetParent()->GetParent();} 95 96 using TabPage::ActivatePage; 97 using TabPage::DeactivatePage; 98 99 public: 100 101 static SfxTabPage* Create(Window* pParent, const SfxItemSet& rSet); 102 103 virtual void ActivatePage(const SfxItemSet& rSet); 104 virtual int DeactivatePage(SfxItemSet* pSet = 0); 105 void FillItem(SwEnvItem& rItem); 106 virtual sal_Bool FillItemSet(SfxItemSet& rSet); 107 virtual void Reset(const SfxItemSet& rSet); 108 }; 109 110 #endif 111 112 113