1*cdf0e10cSrcweir /************************************************************************* 2*cdf0e10cSrcweir * 3*cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4*cdf0e10cSrcweir * 5*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates. 6*cdf0e10cSrcweir * 7*cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite 8*cdf0e10cSrcweir * 9*cdf0e10cSrcweir * This file is part of OpenOffice.org. 10*cdf0e10cSrcweir * 11*cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify 12*cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3 13*cdf0e10cSrcweir * only, as published by the Free Software Foundation. 14*cdf0e10cSrcweir * 15*cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful, 16*cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of 17*cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18*cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details 19*cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code). 20*cdf0e10cSrcweir * 21*cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License 22*cdf0e10cSrcweir * version 3 along with OpenOffice.org. If not, see 23*cdf0e10cSrcweir * <http://www.openoffice.org/license.html> 24*cdf0e10cSrcweir * for a copy of the LGPLv3 License. 25*cdf0e10cSrcweir * 26*cdf0e10cSrcweir ************************************************************************/ 27*cdf0e10cSrcweir #ifndef _SWUI_CNTTAB_HXX 28*cdf0e10cSrcweir #define _SWUI_CNTTAB_HXX 29*cdf0e10cSrcweir 30*cdf0e10cSrcweir #include <svx/stddlg.hxx> 31*cdf0e10cSrcweir 32*cdf0e10cSrcweir #ifndef _BUTTON_HXX //autogen 33*cdf0e10cSrcweir #include <vcl/button.hxx> 34*cdf0e10cSrcweir #endif 35*cdf0e10cSrcweir 36*cdf0e10cSrcweir #ifndef _EDIT_HXX //autogen 37*cdf0e10cSrcweir #include <vcl/edit.hxx> 38*cdf0e10cSrcweir #endif 39*cdf0e10cSrcweir 40*cdf0e10cSrcweir #ifndef _FIXED_HXX //autogen 41*cdf0e10cSrcweir #include <vcl/fixed.hxx> 42*cdf0e10cSrcweir #endif 43*cdf0e10cSrcweir 44*cdf0e10cSrcweir #ifndef _FIELD_HXX //autogen 45*cdf0e10cSrcweir #include <vcl/field.hxx> 46*cdf0e10cSrcweir #endif 47*cdf0e10cSrcweir #include <vcl/lstbox.hxx> 48*cdf0e10cSrcweir #include <sfx2/tabdlg.hxx> 49*cdf0e10cSrcweir 50*cdf0e10cSrcweir #include "tox.hxx" 51*cdf0e10cSrcweir #include <tools/list.hxx> 52*cdf0e10cSrcweir #include <toxmgr.hxx> 53*cdf0e10cSrcweir #include <svx/checklbx.hxx> 54*cdf0e10cSrcweir #include <tools/resary.hxx> 55*cdf0e10cSrcweir #include <svtools/svtreebx.hxx> 56*cdf0e10cSrcweir #include <vcl/menubtn.hxx> 57*cdf0e10cSrcweir #include <svx/langbox.hxx> 58*cdf0e10cSrcweir #include <cnttab.hxx> 59*cdf0e10cSrcweir class SwWrtShell; 60*cdf0e10cSrcweir class SwTOXMgr; 61*cdf0e10cSrcweir namespace com{namespace sun{namespace star{ 62*cdf0e10cSrcweir namespace text{ 63*cdf0e10cSrcweir class XTextSection; 64*cdf0e10cSrcweir class XDocumentIndex; 65*cdf0e10cSrcweir } 66*cdf0e10cSrcweir }}} 67*cdf0e10cSrcweir 68*cdf0e10cSrcweir //----------------------------------------------------------------------------- 69*cdf0e10cSrcweir struct SwIndexSections_Impl 70*cdf0e10cSrcweir { 71*cdf0e10cSrcweir com::sun::star::uno::Reference< com::sun::star::text::XTextSection > xContainerSection; 72*cdf0e10cSrcweir com::sun::star::uno::Reference< com::sun::star::text::XDocumentIndex > xDocumentIndex; 73*cdf0e10cSrcweir }; 74*cdf0e10cSrcweir 75*cdf0e10cSrcweir //----------------------------------------------------------------------------- 76*cdf0e10cSrcweir class SwOneExampleFrame; 77*cdf0e10cSrcweir struct SwIndexSections_Impl; 78*cdf0e10cSrcweir 79*cdf0e10cSrcweir class SwMultiTOXTabDialog : public SfxTabDialog 80*cdf0e10cSrcweir { 81*cdf0e10cSrcweir Window aExampleContainerWIN; 82*cdf0e10cSrcweir Window aExampleWIN; 83*cdf0e10cSrcweir CheckBox aShowExampleCB; 84*cdf0e10cSrcweir SwTOXMgr* pMgr; 85*cdf0e10cSrcweir SwWrtShell& rSh; 86*cdf0e10cSrcweir 87*cdf0e10cSrcweir SwOneExampleFrame* pExampleFrame; 88*cdf0e10cSrcweir 89*cdf0e10cSrcweir SwTOXDescription** pDescArr; // 90*cdf0e10cSrcweir SwForm** pFormArr; // 91*cdf0e10cSrcweir SwIndexSections_Impl** pxIndexSectionsArr; 92*cdf0e10cSrcweir 93*cdf0e10cSrcweir SwTOXBase* pParamTOXBase; 94*cdf0e10cSrcweir 95*cdf0e10cSrcweir CurTOXType eCurrentTOXType; 96*cdf0e10cSrcweir 97*cdf0e10cSrcweir String sUserDefinedIndex; 98*cdf0e10cSrcweir sal_uInt16 nTypeCount; 99*cdf0e10cSrcweir sal_uInt16 nInitialTOXType; 100*cdf0e10cSrcweir 101*cdf0e10cSrcweir sal_Bool bEditTOX; 102*cdf0e10cSrcweir sal_Bool bExampleCreated; 103*cdf0e10cSrcweir sal_Bool bGlobalFlag; 104*cdf0e10cSrcweir 105*cdf0e10cSrcweir virtual short Ok(); 106*cdf0e10cSrcweir SwTOXDescription* CreateTOXDescFromTOXBase(const SwTOXBase*pCurTOX); 107*cdf0e10cSrcweir 108*cdf0e10cSrcweir DECL_LINK(CreateExample_Hdl, void* ); 109*cdf0e10cSrcweir DECL_LINK(ShowPreviewHdl, CheckBox*); 110*cdf0e10cSrcweir 111*cdf0e10cSrcweir public: 112*cdf0e10cSrcweir SwMultiTOXTabDialog(Window* pParent, const SfxItemSet& rSet, 113*cdf0e10cSrcweir SwWrtShell &rShell, 114*cdf0e10cSrcweir SwTOXBase* pCurTOX, sal_uInt16 nToxType = USHRT_MAX, 115*cdf0e10cSrcweir sal_Bool bGlobal = sal_False); 116*cdf0e10cSrcweir ~SwMultiTOXTabDialog(); 117*cdf0e10cSrcweir 118*cdf0e10cSrcweir virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage ); 119*cdf0e10cSrcweir 120*cdf0e10cSrcweir SwForm* GetForm(CurTOXType eType); 121*cdf0e10cSrcweir 122*cdf0e10cSrcweir CurTOXType GetCurrentTOXType() const { return eCurrentTOXType;} 123*cdf0e10cSrcweir void SetCurrentTOXType(CurTOXType eSet) 124*cdf0e10cSrcweir { 125*cdf0e10cSrcweir eCurrentTOXType = eSet; 126*cdf0e10cSrcweir } 127*cdf0e10cSrcweir 128*cdf0e10cSrcweir void UpdateExample(); 129*cdf0e10cSrcweir sal_Bool IsTOXEditMode() const { return bEditTOX;} 130*cdf0e10cSrcweir 131*cdf0e10cSrcweir SwWrtShell& GetWrtShell() {return rSh;} 132*cdf0e10cSrcweir 133*cdf0e10cSrcweir SwTOXDescription& GetTOXDescription(CurTOXType eTOXTypes); 134*cdf0e10cSrcweir void CreateOrUpdateExample( 135*cdf0e10cSrcweir TOXTypes nTOXIndex, sal_uInt16 nPage = 0, sal_uInt16 nCurLevel = USHRT_MAX); 136*cdf0e10cSrcweir 137*cdf0e10cSrcweir static sal_Bool IsNoNum(SwWrtShell& rSh, const String& rName); 138*cdf0e10cSrcweir }; 139*cdf0e10cSrcweir /* -----------------14.07.99 12:17------------------- 140*cdf0e10cSrcweir 141*cdf0e10cSrcweir --------------------------------------------------*/ 142*cdf0e10cSrcweir class IndexEntryRessource; 143*cdf0e10cSrcweir class IndexEntrySupplierWrapper; 144*cdf0e10cSrcweir 145*cdf0e10cSrcweir class SwTOXSelectTabPage : public SfxTabPage 146*cdf0e10cSrcweir { 147*cdf0e10cSrcweir FixedLine aTypeTitleFL; 148*cdf0e10cSrcweir FixedText aTitleFT; 149*cdf0e10cSrcweir Edit aTitleED; 150*cdf0e10cSrcweir FixedText aTypeFT; 151*cdf0e10cSrcweir ListBox aTypeLB; 152*cdf0e10cSrcweir CheckBox aReadOnlyCB; 153*cdf0e10cSrcweir 154*cdf0e10cSrcweir FixedLine aAreaFL; 155*cdf0e10cSrcweir FixedText aAreaFT; 156*cdf0e10cSrcweir ListBox aAreaLB; 157*cdf0e10cSrcweir FixedText aLevelFT; //content, user 158*cdf0e10cSrcweir NumericField aLevelNF; //content, user 159*cdf0e10cSrcweir 160*cdf0e10cSrcweir //content 161*cdf0e10cSrcweir FixedLine aCreateFromFL; // content, user, illustration 162*cdf0e10cSrcweir CheckBox aFromHeadingsCB; 163*cdf0e10cSrcweir // PushButton aChapterDlgPB; //#outline level,removed by zhaojianwei 164*cdf0e10cSrcweir CheckBox aAddStylesCB; 165*cdf0e10cSrcweir PushButton aAddStylesPB; 166*cdf0e10cSrcweir Point aAddStylesPosDef; 167*cdf0e10cSrcweir Point aAddStylesPosUser; 168*cdf0e10cSrcweir //user 169*cdf0e10cSrcweir CheckBox aFromTablesCB; 170*cdf0e10cSrcweir CheckBox aFromFramesCB; 171*cdf0e10cSrcweir CheckBox aFromGraphicsCB; 172*cdf0e10cSrcweir CheckBox aFromOLECB; 173*cdf0e10cSrcweir CheckBox aLevelFromChapterCB; 174*cdf0e10cSrcweir 175*cdf0e10cSrcweir //illustration + table 176*cdf0e10cSrcweir RadioButton aFromCaptionsRB; 177*cdf0e10cSrcweir RadioButton aFromObjectNamesRB; 178*cdf0e10cSrcweir 179*cdf0e10cSrcweir //illustration and tables 180*cdf0e10cSrcweir FixedText aCaptionSequenceFT; 181*cdf0e10cSrcweir ListBox aCaptionSequenceLB; 182*cdf0e10cSrcweir FixedText aDisplayTypeFT; 183*cdf0e10cSrcweir ListBox aDisplayTypeLB; 184*cdf0e10cSrcweir 185*cdf0e10cSrcweir //all but illustration and table 186*cdf0e10cSrcweir CheckBox aTOXMarksCB; 187*cdf0e10cSrcweir 188*cdf0e10cSrcweir // 189*cdf0e10cSrcweir 190*cdf0e10cSrcweir //index only 191*cdf0e10cSrcweir FixedLine aIdxOptionsFL; 192*cdf0e10cSrcweir CheckBox aCollectSameCB; 193*cdf0e10cSrcweir CheckBox aUseFFCB; 194*cdf0e10cSrcweir CheckBox aUseDashCB; 195*cdf0e10cSrcweir CheckBox aCaseSensitiveCB; 196*cdf0e10cSrcweir CheckBox aInitialCapsCB; 197*cdf0e10cSrcweir CheckBox aKeyAsEntryCB; 198*cdf0e10cSrcweir CheckBox aFromFileCB; 199*cdf0e10cSrcweir MenuButton aAutoMarkPB; 200*cdf0e10cSrcweir 201*cdf0e10cSrcweir // object only 202*cdf0e10cSrcweir SwOLENames aFromNames; 203*cdf0e10cSrcweir SvxCheckListBox aFromObjCLB; 204*cdf0e10cSrcweir FixedLine aFromObjFL; 205*cdf0e10cSrcweir 206*cdf0e10cSrcweir CheckBox aSequenceCB; 207*cdf0e10cSrcweir FixedText aBracketFT; 208*cdf0e10cSrcweir ListBox aBracketLB; 209*cdf0e10cSrcweir FixedLine aAuthorityFormatFL; 210*cdf0e10cSrcweir 211*cdf0e10cSrcweir //all 212*cdf0e10cSrcweir FixedLine aSortOptionsFL; 213*cdf0e10cSrcweir FixedText aLanguageFT; 214*cdf0e10cSrcweir SvxLanguageBox aLanguageLB; 215*cdf0e10cSrcweir FixedText aSortAlgorithmFT; 216*cdf0e10cSrcweir ListBox aSortAlgorithmLB; 217*cdf0e10cSrcweir 218*cdf0e10cSrcweir IndexEntryRessource* pIndexRes; 219*cdf0e10cSrcweir 220*cdf0e10cSrcweir Point aCBLeftPos1; 221*cdf0e10cSrcweir Point aCBLeftPos2; 222*cdf0e10cSrcweir Point aCBLeftPos3; 223*cdf0e10cSrcweir 224*cdf0e10cSrcweir String aStyleArr[MAXLEVEL]; 225*cdf0e10cSrcweir String sAutoMarkURL; 226*cdf0e10cSrcweir String sAutoMarkType; 227*cdf0e10cSrcweir String sAddStyleUser; 228*cdf0e10cSrcweir String sAddStyleContent; 229*cdf0e10cSrcweir 230*cdf0e10cSrcweir const IndexEntrySupplierWrapper* pIndexEntryWrapper; 231*cdf0e10cSrcweir 232*cdf0e10cSrcweir sal_Bool bFirstCall; 233*cdf0e10cSrcweir 234*cdf0e10cSrcweir DECL_LINK(TOXTypeHdl, ListBox* ); 235*cdf0e10cSrcweir DECL_LINK(TOXAreaHdl, ListBox* ); 236*cdf0e10cSrcweir // DECL_LINK(ChapterHdl, PushButton* ); //#outline level,removed by zhaojianwei 237*cdf0e10cSrcweir DECL_LINK(AddStylesHdl, PushButton* ); 238*cdf0e10cSrcweir DECL_LINK(MenuEnableHdl, Menu*); 239*cdf0e10cSrcweir DECL_LINK(MenuExecuteHdl, Menu*); 240*cdf0e10cSrcweir DECL_LINK(LanguageHdl, ListBox*); 241*cdf0e10cSrcweir 242*cdf0e10cSrcweir DECL_LINK(CheckBoxHdl, CheckBox* ); 243*cdf0e10cSrcweir DECL_LINK(RadioButtonHdl, RadioButton* ); 244*cdf0e10cSrcweir DECL_LINK(ModifyHdl, void*); 245*cdf0e10cSrcweir 246*cdf0e10cSrcweir void ApplyTOXDescription(); 247*cdf0e10cSrcweir void FillTOXDescription(); 248*cdf0e10cSrcweir 249*cdf0e10cSrcweir using SfxTabPage::ActivatePage; 250*cdf0e10cSrcweir using SfxTabPage::DeactivatePage; 251*cdf0e10cSrcweir 252*cdf0e10cSrcweir public: 253*cdf0e10cSrcweir SwTOXSelectTabPage(Window* pParent, const SfxItemSet& rAttrSet); 254*cdf0e10cSrcweir ~SwTOXSelectTabPage(); 255*cdf0e10cSrcweir 256*cdf0e10cSrcweir virtual sal_Bool FillItemSet( SfxItemSet& ); 257*cdf0e10cSrcweir virtual void Reset( const SfxItemSet& ); 258*cdf0e10cSrcweir 259*cdf0e10cSrcweir virtual void ActivatePage( const SfxItemSet& ); 260*cdf0e10cSrcweir virtual int DeactivatePage( SfxItemSet* pSet = 0 ); 261*cdf0e10cSrcweir 262*cdf0e10cSrcweir static SfxTabPage* Create( Window* pParent, 263*cdf0e10cSrcweir const SfxItemSet& rAttrSet); 264*cdf0e10cSrcweir 265*cdf0e10cSrcweir void SelectType(TOXTypes eSet); //preset TOXType, GlobalDoc 266*cdf0e10cSrcweir void SetWrtShell(SwWrtShell& rSh); 267*cdf0e10cSrcweir }; 268*cdf0e10cSrcweir /* -----------------16.06.99 08:33------------------- 269*cdf0e10cSrcweir 270*cdf0e10cSrcweir --------------------------------------------------*/ 271*cdf0e10cSrcweir 272*cdf0e10cSrcweir DECLARE_LIST(TOXControlList, Control*) 273*cdf0e10cSrcweir 274*cdf0e10cSrcweir class SwTOXEdit; 275*cdf0e10cSrcweir class SwTOXButton; 276*cdf0e10cSrcweir class SwTOXEntryTabPage; 277*cdf0e10cSrcweir 278*cdf0e10cSrcweir class SwTokenWindow : public Window 279*cdf0e10cSrcweir { 280*cdf0e10cSrcweir ImageButton aLeftScrollWin; 281*cdf0e10cSrcweir Window aCtrlParentWin; 282*cdf0e10cSrcweir ImageButton aRightScrollWin; 283*cdf0e10cSrcweir TOXControlList aControlList; 284*cdf0e10cSrcweir SwForm* pForm; 285*cdf0e10cSrcweir sal_uInt16 nLevel; 286*cdf0e10cSrcweir sal_Bool bValid; 287*cdf0e10cSrcweir String aButtonTexts[TOKEN_END]; // Text of the buttons 288*cdf0e10cSrcweir String aButtonHelpTexts[TOKEN_END]; // QuickHelpText of the buttons 289*cdf0e10cSrcweir String sCharStyle; 290*cdf0e10cSrcweir Link aButtonSelectedHdl; 291*cdf0e10cSrcweir Control* pActiveCtrl; 292*cdf0e10cSrcweir Link aModifyHdl; 293*cdf0e10cSrcweir 294*cdf0e10cSrcweir SwTOXEntryTabPage* m_pParent; 295*cdf0e10cSrcweir 296*cdf0e10cSrcweir DECL_LINK(EditResize, Edit*); 297*cdf0e10cSrcweir DECL_LINK(NextItemHdl, SwTOXEdit* ); 298*cdf0e10cSrcweir DECL_LINK(TbxFocusHdl, SwTOXEdit* ); 299*cdf0e10cSrcweir DECL_LINK(NextItemBtnHdl, SwTOXButton* ); 300*cdf0e10cSrcweir DECL_LINK(TbxFocusBtnHdl, SwTOXButton* ); 301*cdf0e10cSrcweir DECL_LINK(ScrollHdl, ImageButton* ); 302*cdf0e10cSrcweir 303*cdf0e10cSrcweir void SetActiveControl(Control* pSet); 304*cdf0e10cSrcweir 305*cdf0e10cSrcweir Control* InsertItem(const String& rText, const SwFormToken& aToken); 306*cdf0e10cSrcweir void AdjustPositions(); 307*cdf0e10cSrcweir void AdjustScrolling(); 308*cdf0e10cSrcweir void MoveControls(long nOffset); 309*cdf0e10cSrcweir 310*cdf0e10cSrcweir public: 311*cdf0e10cSrcweir SwTokenWindow(SwTOXEntryTabPage* pParent, const ResId& rResId); 312*cdf0e10cSrcweir ~SwTokenWindow(); 313*cdf0e10cSrcweir 314*cdf0e10cSrcweir void SetForm(SwForm& rForm, sal_uInt16 nLevel); 315*cdf0e10cSrcweir sal_uInt16 GetLastLevel()const {return nLevel;}; 316*cdf0e10cSrcweir 317*cdf0e10cSrcweir sal_Bool IsValid() const {return bValid;} 318*cdf0e10cSrcweir 319*cdf0e10cSrcweir void SetInvalid() {bValid = sal_False;} 320*cdf0e10cSrcweir 321*cdf0e10cSrcweir String GetPattern() const; 322*cdf0e10cSrcweir 323*cdf0e10cSrcweir void SetButtonSelectedHdl(const Link& rLink) 324*cdf0e10cSrcweir { aButtonSelectedHdl = rLink;} 325*cdf0e10cSrcweir 326*cdf0e10cSrcweir void SetModifyHdl(const Link& rLink){aModifyHdl = rLink;} 327*cdf0e10cSrcweir 328*cdf0e10cSrcweir Control* GetActiveControl() 329*cdf0e10cSrcweir { return pActiveCtrl;} 330*cdf0e10cSrcweir 331*cdf0e10cSrcweir void InsertAtSelection(const String& rText, const SwFormToken& aToken); 332*cdf0e10cSrcweir void RemoveControl(SwTOXButton* pDel, sal_Bool bInternalCall = sal_False); 333*cdf0e10cSrcweir 334*cdf0e10cSrcweir sal_Bool Contains(FormTokenType) const; 335*cdf0e10cSrcweir 336*cdf0e10cSrcweir sal_Bool DetermineLinkStart(); 337*cdf0e10cSrcweir 338*cdf0e10cSrcweir //helper for pattern buttons and edits 339*cdf0e10cSrcweir sal_Bool CreateQuickHelp(Control* pCtrl, 340*cdf0e10cSrcweir const SwFormToken& rToken, const HelpEvent& ); 341*cdf0e10cSrcweir 342*cdf0e10cSrcweir virtual void Resize(); 343*cdf0e10cSrcweir virtual void GetFocus(); 344*cdf0e10cSrcweir }; 345*cdf0e10cSrcweir /* -----------------------------23.12.99 14:16-------------------------------- 346*cdf0e10cSrcweir 347*cdf0e10cSrcweir ---------------------------------------------------------------------------*/ 348*cdf0e10cSrcweir class SwTOXEntryTabPage; 349*cdf0e10cSrcweir class SwIdxTreeListBox : public SvTreeListBox 350*cdf0e10cSrcweir { 351*cdf0e10cSrcweir SwTOXEntryTabPage* pParent; 352*cdf0e10cSrcweir 353*cdf0e10cSrcweir virtual void RequestHelp( const HelpEvent& rHEvt ); 354*cdf0e10cSrcweir public: 355*cdf0e10cSrcweir SwIdxTreeListBox(SwTOXEntryTabPage* pPar, const ResId& rResId); 356*cdf0e10cSrcweir }; 357*cdf0e10cSrcweir 358*cdf0e10cSrcweir /* -----------------16.06.99 12:49------------------- 359*cdf0e10cSrcweir 360*cdf0e10cSrcweir --------------------------------------------------*/ 361*cdf0e10cSrcweir class SwTOXEntryTabPage : public SfxTabPage 362*cdf0e10cSrcweir { 363*cdf0e10cSrcweir FixedText aLevelFT; 364*cdf0e10cSrcweir SwIdxTreeListBox aLevelLB; 365*cdf0e10cSrcweir 366*cdf0e10cSrcweir FixedLine aEntryFL; 367*cdf0e10cSrcweir FixedText aTokenFT; 368*cdf0e10cSrcweir SwTokenWindow aTokenWIN; 369*cdf0e10cSrcweir PushButton aAllLevelsPB; 370*cdf0e10cSrcweir 371*cdf0e10cSrcweir PushButton aEntryNoPB; 372*cdf0e10cSrcweir PushButton aEntryPB; 373*cdf0e10cSrcweir PushButton aTabPB; 374*cdf0e10cSrcweir PushButton aChapterInfoPB; 375*cdf0e10cSrcweir PushButton aPageNoPB; 376*cdf0e10cSrcweir PushButton aHyperLinkPB; 377*cdf0e10cSrcweir 378*cdf0e10cSrcweir ListBox aAuthFieldsLB; 379*cdf0e10cSrcweir PushButton aAuthInsertPB; 380*cdf0e10cSrcweir PushButton aAuthRemovePB; 381*cdf0e10cSrcweir 382*cdf0e10cSrcweir FixedText aCharStyleFT; 383*cdf0e10cSrcweir ListBox aCharStyleLB; // character style of the current token 384*cdf0e10cSrcweir PushButton aEditStylePB; 385*cdf0e10cSrcweir 386*cdf0e10cSrcweir FixedText aChapterEntryFT; 387*cdf0e10cSrcweir ListBox aChapterEntryLB; // type of chapter info 388*cdf0e10cSrcweir 389*cdf0e10cSrcweir FixedText aNumberFormatFT; 390*cdf0e10cSrcweir ListBox aNumberFormatLB; //!< format for numbering (E#) 391*cdf0e10cSrcweir 392*cdf0e10cSrcweir FixedText aEntryOutlineLevelFT; //!< Fixed text, for i53420 393*cdf0e10cSrcweir NumericField aEntryOutlineLevelNF; //!< level to evaluate outline level to, for i53420 394*cdf0e10cSrcweir FixedText aFillCharFT; 395*cdf0e10cSrcweir ComboBox aFillCharCB; // fill char for tab stop 396*cdf0e10cSrcweir FixedText aTabPosFT; 397*cdf0e10cSrcweir MetricField aTabPosMF; // tab stop position 398*cdf0e10cSrcweir CheckBox aAutoRightCB; 399*cdf0e10cSrcweir FixedLine aFormatFL; 400*cdf0e10cSrcweir 401*cdf0e10cSrcweir CheckBox aRelToStyleCB; // position relative to the right margin of the para style 402*cdf0e10cSrcweir FixedText aMainEntryStyleFT; 403*cdf0e10cSrcweir ListBox aMainEntryStyleLB; // character style of main entries in indexes 404*cdf0e10cSrcweir CheckBox aAlphaDelimCB; 405*cdf0e10cSrcweir CheckBox aCommaSeparatedCB; 406*cdf0e10cSrcweir 407*cdf0e10cSrcweir RadioButton aSortDocPosRB; 408*cdf0e10cSrcweir RadioButton aSortContentRB; 409*cdf0e10cSrcweir FixedLine aSortingFL; 410*cdf0e10cSrcweir 411*cdf0e10cSrcweir FixedText aFirstKeyFT; 412*cdf0e10cSrcweir ListBox aFirstKeyLB; 413*cdf0e10cSrcweir ImageRadioButton aFirstSortUpRB; 414*cdf0e10cSrcweir ImageRadioButton aFirstSortDownRB; 415*cdf0e10cSrcweir 416*cdf0e10cSrcweir FixedText aSecondKeyFT; 417*cdf0e10cSrcweir ListBox aSecondKeyLB; 418*cdf0e10cSrcweir ImageRadioButton aSecondSortUpRB; 419*cdf0e10cSrcweir ImageRadioButton aSecondSortDownRB; 420*cdf0e10cSrcweir 421*cdf0e10cSrcweir FixedText aThirdKeyFT; 422*cdf0e10cSrcweir ListBox aThirdKeyLB; 423*cdf0e10cSrcweir ImageRadioButton aThirdSortUpRB; 424*cdf0e10cSrcweir ImageRadioButton aThirdSortDownRB; 425*cdf0e10cSrcweir 426*cdf0e10cSrcweir FixedLine aSortKeyFL; 427*cdf0e10cSrcweir 428*cdf0e10cSrcweir String sDelimStr; 429*cdf0e10cSrcweir String sLevelStr; 430*cdf0e10cSrcweir String sAuthTypeStr; 431*cdf0e10cSrcweir 432*cdf0e10cSrcweir String sNoCharStyle; 433*cdf0e10cSrcweir String sNoCharSortKey; 434*cdf0e10cSrcweir Point aButtonPositions[5]; 435*cdf0e10cSrcweir SwForm* m_pCurrentForm; 436*cdf0e10cSrcweir 437*cdf0e10cSrcweir Point aRelToStylePos; 438*cdf0e10cSrcweir Point aRelToStyleIdxPos; 439*cdf0e10cSrcweir Size aLevelFLSize; 440*cdf0e10cSrcweir 441*cdf0e10cSrcweir CurTOXType aLastTOXType; 442*cdf0e10cSrcweir sal_Bool bInLevelHdl; 443*cdf0e10cSrcweir 444*cdf0e10cSrcweir Point aChapterEntryFTPosition; //!< holds position of ChapterEntryFT control, 445*cdf0e10cSrcweir //to be used in moving the element among different tokens 446*cdf0e10cSrcweir Point aEntryOutlineLevelFTPosition;//!< holds position ofrEntryOutlineLevelFT control 447*cdf0e10cSrcweir sal_Int32 nBiasToEntryPoint; 448*cdf0e10cSrcweir 449*cdf0e10cSrcweir DECL_LINK(StyleSelectHdl, ListBox*); 450*cdf0e10cSrcweir DECL_LINK(EditStyleHdl, PushButton*); 451*cdf0e10cSrcweir DECL_LINK(InsertTokenHdl, PushButton*); 452*cdf0e10cSrcweir DECL_LINK(LevelHdl, SvTreeListBox*); 453*cdf0e10cSrcweir DECL_LINK(AutoRightHdl, CheckBox*); 454*cdf0e10cSrcweir DECL_LINK(TokenSelectedHdl, SwFormToken*); 455*cdf0e10cSrcweir DECL_LINK(TabPosHdl, MetricField*); 456*cdf0e10cSrcweir DECL_LINK(FillCharHdl, ComboBox*); 457*cdf0e10cSrcweir DECL_LINK(RemoveInsertAuthHdl, PushButton*); 458*cdf0e10cSrcweir DECL_LINK(SortKeyHdl, RadioButton*); 459*cdf0e10cSrcweir DECL_LINK(ChapterInfoHdl, ListBox*); 460*cdf0e10cSrcweir DECL_LINK(ChapterInfoOutlineHdl, NumericField*); 461*cdf0e10cSrcweir DECL_LINK(NumberFormatHdl, ListBox*); 462*cdf0e10cSrcweir 463*cdf0e10cSrcweir DECL_LINK(AllLevelsHdl, PushButton*); 464*cdf0e10cSrcweir 465*cdf0e10cSrcweir void EnableButtons(); 466*cdf0e10cSrcweir void WriteBackLevel(); 467*cdf0e10cSrcweir void UpdateDescriptor(); 468*cdf0e10cSrcweir DECL_LINK(ModifyHdl, void*); 469*cdf0e10cSrcweir 470*cdf0e10cSrcweir using SfxTabPage::ActivatePage; 471*cdf0e10cSrcweir using SfxTabPage::DeactivatePage; 472*cdf0e10cSrcweir 473*cdf0e10cSrcweir public: 474*cdf0e10cSrcweir SwTOXEntryTabPage(Window* pParent, const SfxItemSet& rAttrSet); 475*cdf0e10cSrcweir ~SwTOXEntryTabPage(); 476*cdf0e10cSrcweir 477*cdf0e10cSrcweir virtual sal_Bool FillItemSet( SfxItemSet& ); 478*cdf0e10cSrcweir virtual void Reset( const SfxItemSet& ); 479*cdf0e10cSrcweir virtual void ActivatePage( const SfxItemSet& ); 480*cdf0e10cSrcweir virtual int DeactivatePage( SfxItemSet* pSet = 0 ); 481*cdf0e10cSrcweir 482*cdf0e10cSrcweir static SfxTabPage* Create( Window* pParent, 483*cdf0e10cSrcweir const SfxItemSet& rAttrSet); 484*cdf0e10cSrcweir void SetWrtShell(SwWrtShell& rSh); 485*cdf0e10cSrcweir 486*cdf0e10cSrcweir String GetLevelHelp(sal_uInt16 nLevel) const; 487*cdf0e10cSrcweir 488*cdf0e10cSrcweir void PreTokenButtonRemoved(const SwFormToken& rToken); 489*cdf0e10cSrcweir }; 490*cdf0e10cSrcweir /* -----------------05.07.99 13:00------------------- 491*cdf0e10cSrcweir 492*cdf0e10cSrcweir --------------------------------------------------*/ 493*cdf0e10cSrcweir class SwTOXStylesTabPage : public SfxTabPage 494*cdf0e10cSrcweir { 495*cdf0e10cSrcweir FixedLine aFormatFL; 496*cdf0e10cSrcweir FixedText aLevelFT2; 497*cdf0e10cSrcweir ListBox aLevelLB; 498*cdf0e10cSrcweir ImageButton aAssignBT; 499*cdf0e10cSrcweir FixedText aTemplateFT; 500*cdf0e10cSrcweir ListBox aParaLayLB; 501*cdf0e10cSrcweir PushButton aStdBT; 502*cdf0e10cSrcweir PushButton aEditStyleBT; 503*cdf0e10cSrcweir 504*cdf0e10cSrcweir SwForm* m_pCurrentForm; 505*cdf0e10cSrcweir // void UpdatePattern(); 506*cdf0e10cSrcweir 507*cdf0e10cSrcweir DECL_LINK( EditStyleHdl, Button *); 508*cdf0e10cSrcweir DECL_LINK( StdHdl, Button * ); 509*cdf0e10cSrcweir DECL_LINK( EnableSelectHdl, ListBox * ); 510*cdf0e10cSrcweir DECL_LINK( DoubleClickHdl, Button * ); 511*cdf0e10cSrcweir DECL_LINK( AssignHdl, Button * ); 512*cdf0e10cSrcweir DECL_LINK( ModifyHdl, void*); 513*cdf0e10cSrcweir 514*cdf0e10cSrcweir SwForm& GetForm() 515*cdf0e10cSrcweir { 516*cdf0e10cSrcweir SwMultiTOXTabDialog* pDlg = (SwMultiTOXTabDialog*)GetTabDialog(); 517*cdf0e10cSrcweir return *pDlg->GetForm(pDlg->GetCurrentTOXType()); 518*cdf0e10cSrcweir } 519*cdf0e10cSrcweir 520*cdf0e10cSrcweir using SfxTabPage::ActivatePage; 521*cdf0e10cSrcweir using SfxTabPage::DeactivatePage; 522*cdf0e10cSrcweir 523*cdf0e10cSrcweir public: 524*cdf0e10cSrcweir SwTOXStylesTabPage(Window* pParent, const SfxItemSet& rAttrSet); 525*cdf0e10cSrcweir ~SwTOXStylesTabPage(); 526*cdf0e10cSrcweir 527*cdf0e10cSrcweir virtual sal_Bool FillItemSet( SfxItemSet& ); 528*cdf0e10cSrcweir virtual void Reset( const SfxItemSet& ); 529*cdf0e10cSrcweir 530*cdf0e10cSrcweir virtual void ActivatePage( const SfxItemSet& ); 531*cdf0e10cSrcweir virtual int DeactivatePage( SfxItemSet* pSet = 0 ); 532*cdf0e10cSrcweir 533*cdf0e10cSrcweir static SfxTabPage* Create( Window* pParent, 534*cdf0e10cSrcweir const SfxItemSet& rAttrSet); 535*cdf0e10cSrcweir 536*cdf0e10cSrcweir }; 537*cdf0e10cSrcweir 538*cdf0e10cSrcweir #endif // _SWUI_CNTTAB_HXX 539*cdf0e10cSrcweir 540