/src/libreoffice/include/editeng/CustomPropertyField.hxx
Line | Count | Source |
1 | | /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ |
2 | | /* |
3 | | * This file is part of the LibreOffice project. |
4 | | * |
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/. |
8 | | * |
9 | | */ |
10 | | |
11 | | #ifndef INCLUDED_EDITENG_CUSTOMPROPERTYFIELD_HXX |
12 | | #define INCLUDED_EDITENG_CUSTOMPROPERTYFIELD_HXX |
13 | | |
14 | | #include <editeng/editengdllapi.h> |
15 | | |
16 | | #include <editeng/flditem.hxx> |
17 | | |
18 | | #include <com/sun/star/text/textfield/Type.hpp> |
19 | | |
20 | | namespace com::sun::star::document { class XDocumentProperties; } |
21 | | |
22 | | |
23 | | namespace editeng |
24 | | { |
25 | | |
26 | | class EDITENG_DLLPUBLIC CustomPropertyField final : public SvxFieldData |
27 | | { |
28 | | private: |
29 | | OUString msName; |
30 | | OUString msCurrentPresentation; |
31 | | |
32 | | public: |
33 | | explicit CustomPropertyField(OUString aName, OUString aCurrentPresentation); |
34 | | |
35 | | virtual ~CustomPropertyField() override; |
36 | | |
37 | 0 | virtual sal_Int32 GetClassId() const override { return css::text::textfield::Type::DOCINFO_CUSTOM; } |
38 | | |
39 | | virtual std::unique_ptr<SvxFieldData> Clone() const override; |
40 | | virtual bool operator==(const SvxFieldData&) const override; |
41 | | |
42 | | const OUString & GetFormatted(css::uno::Reference<css::document::XDocumentProperties> const & xDocumentProperties); |
43 | | |
44 | | OUString const & GetName() const |
45 | 0 | { |
46 | 0 | return msName; |
47 | 0 | } |
48 | | |
49 | | OUString const & GetCurrentPresentation() const |
50 | 0 | { |
51 | 0 | return msCurrentPresentation; |
52 | 0 | } |
53 | | }; |
54 | | |
55 | | } // end editeng namespace |
56 | | |
57 | | #endif // INCLUDED_EDITENG_CUSTOMPROPERTYFIELD_HXX |
58 | | |
59 | | /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |