2010-10-14 08:30:41 +02:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
2011-03-31 10:05:04 +02:00
|
|
|
/*
|
|
|
|
* This file is part of the LibreOffice project.
|
|
|
|
*
|
|
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
*
|
|
|
|
* This file incorporates work covered by the following license notice:
|
|
|
|
*
|
|
|
|
* Licensed to the Apache Software Foundation (ASF) under one or more
|
|
|
|
* contributor license agreements. See the NOTICE file distributed
|
|
|
|
* with this work for additional information regarding copyright
|
|
|
|
* ownership. The ASF licenses this file to you under the Apache
|
|
|
|
* License, Version 2.0 (the "License"); you may not use this file
|
|
|
|
* except in compliance with the License. You may obtain a copy of
|
|
|
|
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
|
|
|
|
*/
|
2013-11-05 02:17:53 +01:00
|
|
|
#ifndef INCLUDED_SW_SOURCE_UI_INC_OUTLINE_HXX
|
|
|
|
#define INCLUDED_SW_SOURCE_UI_INC_OUTLINE_HXX
|
2000-09-18 16:15:01 +00:00
|
|
|
|
|
|
|
#include <sfx2/tabdlg.hxx>
|
|
|
|
|
|
|
|
|
|
|
|
#include <vcl/menu.hxx>
|
|
|
|
|
|
|
|
#include <vcl/button.hxx>
|
|
|
|
#include <svtools/stdctrl.hxx>
|
|
|
|
|
|
|
|
#include <vcl/fixed.hxx>
|
|
|
|
|
|
|
|
#include <vcl/lstbox.hxx>
|
|
|
|
|
|
|
|
#include <vcl/edit.hxx>
|
|
|
|
|
|
|
|
#include <vcl/field.hxx>
|
|
|
|
|
2013-10-22 15:58:57 +03:00
|
|
|
#include "swtypes.hxx"
|
2000-09-18 16:15:01 +00:00
|
|
|
#include <numprevw.hxx>
|
2001-03-02 13:10:47 +00:00
|
|
|
#include <numberingtypelistbox.hxx>
|
2013-08-24 18:01:05 +02:00
|
|
|
#include "rtl/ustring.hxx"
|
2000-09-18 16:15:01 +00:00
|
|
|
|
|
|
|
class SwWrtShell;
|
|
|
|
class SwNumRule;
|
|
|
|
class SwChapterNumRules;
|
|
|
|
|
|
|
|
class SwOutlineTabDialog : public SfxTabDialog
|
|
|
|
{
|
2011-01-17 15:06:54 +01:00
|
|
|
static sal_uInt16 nNumLevel;
|
2005-03-01 14:28:14 +00:00
|
|
|
|
2013-01-19 12:08:26 +00:00
|
|
|
sal_uInt16 m_nNumPosId;
|
|
|
|
sal_uInt16 m_nOutlineId;
|
|
|
|
|
2013-08-24 18:01:05 +02:00
|
|
|
OUString aCollNames[MAXLEVEL];
|
2000-09-18 16:15:01 +00:00
|
|
|
|
|
|
|
SwWrtShell& rWrtSh;
|
|
|
|
SwNumRule* pNumRule;
|
|
|
|
SwChapterNumRules* pChapterNumRules;
|
|
|
|
|
2011-01-17 15:06:54 +01:00
|
|
|
sal_Bool bModified : 1;
|
2000-09-18 16:15:01 +00:00
|
|
|
|
|
|
|
protected:
|
2012-03-01 18:00:32 +01:00
|
|
|
DECL_LINK(CancelHdl, void *);
|
2000-09-18 16:15:01 +00:00
|
|
|
DECL_LINK( FormHdl, Button * );
|
|
|
|
DECL_LINK( MenuSelectHdl, Menu * );
|
|
|
|
|
2011-01-17 15:06:54 +01:00
|
|
|
virtual void PageCreated(sal_uInt16 nPageId, SfxTabPage& rPage);
|
2000-09-18 16:15:01 +00:00
|
|
|
virtual short Ok();
|
|
|
|
|
|
|
|
public:
|
|
|
|
SwOutlineTabDialog(Window* pParent,
|
|
|
|
const SfxItemSet* pSwItemSet,
|
|
|
|
SwWrtShell &);
|
|
|
|
~SwOutlineTabDialog();
|
|
|
|
|
|
|
|
SwNumRule* GetNumRule() {return pNumRule;}
|
2013-10-08 15:28:31 +02:00
|
|
|
sal_uInt16 GetLevel(const OUString &rFmtName) const;
|
2013-08-24 18:01:05 +02:00
|
|
|
OUString* GetCollNames() {return aCollNames;}
|
2005-03-01 14:28:14 +00:00
|
|
|
|
2011-01-17 15:06:54 +01:00
|
|
|
static sal_uInt16 GetActNumLevel() {return nNumLevel;}
|
|
|
|
static void SetActNumLevel(sal_uInt16 nSet) {nNumLevel = nSet;}
|
2000-09-18 16:15:01 +00:00
|
|
|
};
|
2010-10-13 10:32:10 +05:30
|
|
|
|
2000-09-18 16:15:01 +00:00
|
|
|
class SwOutlineSettingsTabPage : public SfxTabPage
|
|
|
|
{
|
2012-12-03 13:36:07 +00:00
|
|
|
ListBox* m_pLevelLB;
|
|
|
|
|
|
|
|
ListBox* m_pCollBox;
|
|
|
|
SwNumberingTypeListBox* m_pNumberBox;
|
|
|
|
ListBox* m_pCharFmtLB;
|
|
|
|
FixedText* m_pAllLevelFT;
|
|
|
|
NumericField* m_pAllLevelNF;
|
|
|
|
Edit* m_pPrefixED;
|
|
|
|
Edit* m_pSuffixED;
|
|
|
|
NumericField* m_pStartEdit;
|
|
|
|
NumberingPreview* m_pPreviewWIN;
|
2000-09-18 16:15:01 +00:00
|
|
|
|
2013-10-08 15:28:31 +02:00
|
|
|
OUString aNoFmtName;
|
|
|
|
OUString aSaveCollNames[MAXLEVEL];
|
2000-09-18 16:15:01 +00:00
|
|
|
SwWrtShell* pSh;
|
|
|
|
SwNumRule* pNumRule;
|
2013-08-24 18:01:05 +02:00
|
|
|
OUString* pCollNames;
|
2011-01-17 15:06:54 +01:00
|
|
|
sal_uInt16 nActLevel;
|
2000-09-18 16:15:01 +00:00
|
|
|
|
|
|
|
DECL_LINK( LevelHdl, ListBox * );
|
|
|
|
DECL_LINK( ToggleComplete, NumericField * );
|
|
|
|
DECL_LINK( CollSelect, ListBox * );
|
2012-03-01 18:00:32 +01:00
|
|
|
DECL_LINK(CollSelectGetFocus, void *);
|
2001-03-02 13:10:47 +00:00
|
|
|
DECL_LINK( NumberSelect, SwNumberingTypeListBox * );
|
2012-03-01 18:00:32 +01:00
|
|
|
DECL_LINK(DelimModify, void *);
|
2000-09-18 16:15:01 +00:00
|
|
|
DECL_LINK( StartModified, NumericField * );
|
2012-03-01 18:00:32 +01:00
|
|
|
DECL_LINK(CharFmtHdl, void *);
|
2000-09-18 16:15:01 +00:00
|
|
|
|
|
|
|
void Update();
|
|
|
|
|
2012-12-03 13:36:07 +00:00
|
|
|
void SetModified(){m_pPreviewWIN->Invalidate();}
|
2002-11-07 13:45:01 +00:00
|
|
|
void CheckForStartValue_Impl(sal_uInt16 nNumberingType);
|
2000-09-18 16:15:01 +00:00
|
|
|
|
2008-05-06 14:24:08 +00:00
|
|
|
using SfxTabPage::ActivatePage;
|
|
|
|
using SfxTabPage::DeactivatePage;
|
2007-10-22 14:21:26 +00:00
|
|
|
|
2000-09-18 16:15:01 +00:00
|
|
|
public:
|
|
|
|
SwOutlineSettingsTabPage(Window* pParent, const SfxItemSet& rSet);
|
|
|
|
~SwOutlineSettingsTabPage();
|
|
|
|
|
|
|
|
void SetWrtShell(SwWrtShell* pShell);
|
|
|
|
|
|
|
|
virtual void ActivatePage(const SfxItemSet& rSet);
|
|
|
|
virtual int DeactivatePage(SfxItemSet *pSet);
|
2007-09-27 11:06:55 +00:00
|
|
|
|
2011-01-17 15:06:54 +01:00
|
|
|
virtual sal_Bool FillItemSet( SfxItemSet& rSet );
|
2000-09-18 16:15:01 +00:00
|
|
|
virtual void Reset( const SfxItemSet& rSet );
|
|
|
|
static SfxTabPage* Create( Window* pParent,
|
|
|
|
const SfxItemSet& rAttrSet);
|
|
|
|
};
|
2010-10-13 10:32:10 +05:30
|
|
|
|
2000-09-18 16:15:01 +00:00
|
|
|
#endif
|
2010-10-14 08:30:41 +02:00
|
|
|
|
|
|
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|