fdo#74697 Add Bluez 5 support for impress remote.
[LibreOffice.git] / sw / inc / unotextbodyhf.hxx
blob494aaff9653513969d9cd44fc266dbcfbb71bcf2
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
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 .
20 #ifndef SW_UNOTEXTBODYHF_HXX
21 #define SW_UNOTEXTBODYHF_HXX
23 #include <com/sun/star/lang/XUnoTunnel.hpp>
24 #include <com/sun/star/lang/XServiceInfo.hpp>
25 #include <com/sun/star/container/XEnumerationAccess.hpp>
27 #include <cppuhelper/implbase2.hxx>
29 #include <unotext.hxx>
32 class SwDoc;
33 class SwFrmFmt;
34 class SwXTextCursor;
37 typedef ::cppu::WeakAggImplHelper2
38 < ::com::sun::star::lang::XServiceInfo
39 , ::com::sun::star::container::XEnumerationAccess
40 > SwXBodyText_Base;
42 class SwXBodyText
43 : public SwXBodyText_Base
44 , public SwXText
47 protected:
49 virtual ~SwXBodyText();
51 public:
53 SwXBodyText(SwDoc *const pDoc);
55 SwXTextCursor * CreateTextCursor(const bool bIgnoreTables = false);
57 // XInterface
58 virtual ::com::sun::star::uno::Any SAL_CALL queryInterface(
59 const ::com::sun::star::uno::Type& rType)
60 throw (::com::sun::star::uno::RuntimeException);
61 virtual void SAL_CALL acquire() throw() { OWeakObject::acquire(); }
62 virtual void SAL_CALL release() throw() { OWeakObject::release(); }
64 // XAggregation
65 virtual ::com::sun::star::uno::Any SAL_CALL queryAggregation(
66 const ::com::sun::star::uno::Type& rType)
67 throw (::com::sun::star::uno::RuntimeException);
69 // XTypeProvider
70 virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type >
71 SAL_CALL getTypes()
72 throw (::com::sun::star::uno::RuntimeException);
73 virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL
74 getImplementationId()
75 throw (::com::sun::star::uno::RuntimeException);
77 // XServiceInfo
78 virtual OUString SAL_CALL getImplementationName()
79 throw (::com::sun::star::uno::RuntimeException);
80 virtual sal_Bool SAL_CALL supportsService(
81 const OUString& rServiceName)
82 throw (::com::sun::star::uno::RuntimeException);
83 virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL
84 getSupportedServiceNames()
85 throw (::com::sun::star::uno::RuntimeException);
87 // XElementAccess
88 virtual ::com::sun::star::uno::Type SAL_CALL getElementType()
89 throw (::com::sun::star::uno::RuntimeException);
90 virtual sal_Bool SAL_CALL hasElements()
91 throw (::com::sun::star::uno::RuntimeException);
93 // XEnumerationAccess
94 virtual ::com::sun::star::uno::Reference<
95 ::com::sun::star::container::XEnumeration > SAL_CALL
96 createEnumeration()
97 throw (::com::sun::star::uno::RuntimeException);
99 // XSimpleText
100 virtual ::com::sun::star::uno::Reference<
101 ::com::sun::star::text::XTextCursor > SAL_CALL
102 createTextCursor()
103 throw (::com::sun::star::uno::RuntimeException);
104 virtual ::com::sun::star::uno::Reference<
105 ::com::sun::star::text::XTextCursor > SAL_CALL
106 createTextCursorByRange(
107 const ::com::sun::star::uno::Reference<
108 ::com::sun::star::text::XTextRange > & xTextPosition)
109 throw (::com::sun::star::uno::RuntimeException);
114 typedef ::cppu::WeakImplHelper2
115 < ::com::sun::star::lang::XServiceInfo
116 , ::com::sun::star::container::XEnumerationAccess
117 > SwXHeadFootText_Base;
119 class SwXHeadFootText
120 : public SwXHeadFootText_Base
121 , public SwXText
124 private:
126 class Impl;
127 ::sw::UnoImplPtr<Impl> m_pImpl;
129 protected:
131 virtual const SwStartNode *GetStartNode() const;
132 virtual ::com::sun::star::uno::Reference<
133 ::com::sun::star::text::XTextCursor >
134 CreateCursor()
135 throw (::com::sun::star::uno::RuntimeException);
137 virtual ~SwXHeadFootText();
139 SwXHeadFootText(SwFrmFmt & rHeadFootFmt, const bool bIsHeader);
141 public:
143 static ::com::sun::star::uno::Reference< ::com::sun::star::text::XText >
144 CreateXHeadFootText(SwFrmFmt & rHeadFootFmt, const bool bIsHeader);
145 static bool IsXHeadFootText(SwClient *const pClient);
147 // XInterface
148 virtual ::com::sun::star::uno::Any SAL_CALL queryInterface(
149 const ::com::sun::star::uno::Type& rType)
150 throw (::com::sun::star::uno::RuntimeException);
151 virtual void SAL_CALL acquire() throw() { OWeakObject::acquire(); }
152 virtual void SAL_CALL release() throw() { OWeakObject::release(); }
154 // XTypeProvider
155 virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type >
156 SAL_CALL getTypes()
157 throw (::com::sun::star::uno::RuntimeException);
158 virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL
159 getImplementationId()
160 throw (::com::sun::star::uno::RuntimeException);
162 // XServiceInfo
163 virtual OUString SAL_CALL getImplementationName()
164 throw (::com::sun::star::uno::RuntimeException);
165 virtual sal_Bool SAL_CALL supportsService(
166 const OUString& rServiceName)
167 throw (::com::sun::star::uno::RuntimeException);
168 virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL
169 getSupportedServiceNames()
170 throw (::com::sun::star::uno::RuntimeException);
172 // XElementAccess
173 virtual ::com::sun::star::uno::Type SAL_CALL getElementType()
174 throw (::com::sun::star::uno::RuntimeException);
175 virtual sal_Bool SAL_CALL hasElements()
176 throw (::com::sun::star::uno::RuntimeException);
178 // XEnumerationAccess
179 virtual ::com::sun::star::uno::Reference<
180 ::com::sun::star::container::XEnumeration > SAL_CALL
181 createEnumeration()
182 throw (::com::sun::star::uno::RuntimeException);
184 // XSimpleText
185 virtual ::com::sun::star::uno::Reference<
186 ::com::sun::star::text::XTextCursor > SAL_CALL
187 createTextCursor()
188 throw (::com::sun::star::uno::RuntimeException);
189 virtual ::com::sun::star::uno::Reference<
190 ::com::sun::star::text::XTextCursor > SAL_CALL
191 createTextCursorByRange(
192 const ::com::sun::star::uno::Reference<
193 ::com::sun::star::text::XTextRange > & xTextPosition)
194 throw (::com::sun::star::uno::RuntimeException);
198 #endif // SW_UNOTEXTBODYHF_HXX
200 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */