1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
22 #include <svx/stddlg.hxx>
24 #include <vcl/fixed.hxx>
26 #include <vcl/lstbox.hxx>
28 #include <vcl/edit.hxx>
30 #include <vcl/group.hxx>
32 #include <vcl/button.hxx>
33 #include <actctrl.hxx>
36 #include <com/sun/star/container/XEnumerationAccess.hpp>
37 #include <com/sun/star/container/XHierarchicalNameAccess.hpp>
38 #include <com/sun/star/container/XNameAccess.hpp>
39 #include <com/sun/star/container/XContentEnumerationAccess.hpp>
40 #include <com/sun/star/container/XEnumeration.hpp>
41 #include <com/sun/star/container/XElementAccess.hpp>
42 #include <com/sun/star/container/XIndexAccess.hpp>
43 #include <com/sun/star/container/XNamed.hpp>
49 #include "optload.hxx"
52 class CategoryBox
: public ComboBox
55 CategoryBox( Window
* pParent
, WinBits nStyle
= 0 )
56 : ComboBox( pParent
, nStyle
)
59 virtual long PreNotify( NotifyEvent
& rNEvt
);
63 class SwCaptionDialog
: public SvxStandardDialog
66 CategoryBox
* m_pCategoryBox
;
67 FixedText
* m_pFormatText
;
68 ListBox
* m_pFormatBox
;
69 //#i61007# order of captions
70 FixedText
* m_pNumberingSeparatorFT
;
71 Edit
* m_pNumberingSeparatorED
;
72 FixedText
* m_pSepText
;
74 FixedText
* m_pPosText
;
76 OKButton
* m_pOKButton
;
77 PushButton
* m_pAutoCaptionButton
;
78 PushButton
* m_pOptionButton
;
80 SwCaptionPreview
* m_pPreview
;
84 SwView
&rView
; // search per active, avoid ::com::sun::star::sdbcx::View
85 SwFldMgr
*pMgr
; // pointer to save the include
88 String sCharacterStyle
;
91 bool bOrderNumberingFirst
; //#i61007# order of captions
93 ::com::sun::star::uno::Reference
< ::com::sun::star::container::XNameAccess
> xNameAccess
;
94 ::com::sun::star::uno::Reference
< ::com::sun::star::container::XNamed
> xNamed
;
96 DECL_LINK(SelectHdl
, void *);
97 DECL_LINK(ModifyHdl
, void *);
98 DECL_LINK(OptionHdl
, Button
*);
99 DECL_LINK(CaptionHdl
, void *);
101 virtual void Apply();
104 void CheckButtonWidth();
105 void ApplyCaptionOrder(); //#i61007# order of captions
107 static String our_aSepTextSave
; // Save caption separator text
109 SwCaptionDialog( Window
*pParent
, SwView
&rV
);
116 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */