LibreOffice Module sw (master) 1
unostyle.hxx
Go to the documentation of this file.
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 * This file incorporates work covered by the following license notice:
10 *
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 .
18 */
19#pragma once
20
21#include <svl/listener.hxx>
22#include <svl/style.hxx>
23#include "unocoll.hxx"
24#include "tblafmt.hxx"
25#include <com/sun/star/style/XStyle.hpp>
26#include <com/sun/star/style/XStyleLoader.hpp>
27#include <com/sun/star/container/XNameContainer.hpp>
28#include <com/sun/star/beans/XPropertySet.hpp>
29#include <com/sun/star/beans/XPropertyState.hpp>
31
32#include <com/sun/star/style/XAutoStyleFamily.hpp>
33#include <com/sun/star/style/XAutoStyles.hpp>
34#include <com/sun/star/style/XAutoStyle.hpp>
35
36#include "istyleaccess.hxx"
37#include <memory>
38#include <map>
39
40namespace com::sun::star::document { class XEventsSupplier; }
41
42class SwDocShell;
44class SfxItemSet;
45
46class SwXStyleFamilies final : public cppu::WeakImplHelper
47<
48 css::container::XIndexAccess,
49 css::container::XNameAccess,
50 css::lang::XServiceInfo,
51 css::style::XStyleLoader
52>,
53 public SwUnoCollection
54{
56
57 std::map<SfxStyleFamily, css::uno::Reference<css::container::XNameContainer>> m_vFamilies;
58
59 virtual ~SwXStyleFamilies() override;
60public:
61 SwXStyleFamilies(SwDocShell& rDocShell);
62
63 //XNameAccess
64 virtual css::uno::Any SAL_CALL getByName(const OUString& Name) override;
65 virtual css::uno::Sequence< OUString > SAL_CALL getElementNames() override;
66 virtual sal_Bool SAL_CALL hasByName(const OUString& Name) override;
67
68 //XIndexAccess
69 virtual sal_Int32 SAL_CALL getCount() override;
70 virtual css::uno::Any SAL_CALL getByIndex(sal_Int32 nIndex) override;
71
72 //XElementAccess
73 virtual css::uno::Type SAL_CALL getElementType( ) override;
74 virtual sal_Bool SAL_CALL hasElements( ) override;
75
76 //XStyleLoader
77 virtual void SAL_CALL loadStylesFromURL(const OUString& rURL, const css::uno::Sequence< css::beans::PropertyValue >& aOptions) override;
78 virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getStyleLoaderOptions() override;
79
80 //XServiceInfo
81 virtual OUString SAL_CALL getImplementationName() override;
82 virtual sal_Bool SAL_CALL supportsService(const OUString& ServiceName) override;
83 virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override;
84
85 static css::uno::Reference<css::style::XStyle> CreateStyle(SfxStyleFamily eFamily, SwDoc& rDoc);
86 // FIXME: This is very ugly as is the whole conditional paragraph style
87 // hackety. Should be folded into CreateStyle hopefully one day
88 static css::uno::Reference<css::style::XStyle> CreateStyleCondParagraph(SwDoc& rDoc);
89};
90
91namespace sw
92{
94 {
95 public:
96 virtual void SetItem(sal_uInt16 eAtr, const SfxPoolItem& rItem) =0;
97 virtual const SfxPoolItem* GetItem(sal_uInt16 eAtr) =0;
98 virtual css::document::XEventsSupplier& GetEventsSupplier() =0;
99 virtual ~ICoreFrameStyle() {};
100 };
101}
102
103// access to all automatic style families
104class SwXAutoStyles final :
105 public cppu::WeakImplHelper< css::style::XAutoStyles >,
106 public SwUnoCollection
107{
109 css::uno::Reference< css::style::XAutoStyleFamily > m_xAutoCharStyles;
110 css::uno::Reference< css::style::XAutoStyleFamily > m_xAutoRubyStyles;
111 css::uno::Reference< css::style::XAutoStyleFamily > m_xAutoParaStyles;
112 virtual ~SwXAutoStyles() override;
113
114public:
115 SwXAutoStyles(SwDocShell& rDocShell);
116
117 //XIndexAccess
118 virtual sal_Int32 SAL_CALL getCount() override;
119 virtual css::uno::Any SAL_CALL getByIndex(sal_Int32 nIndex) override;
120
121 //XElementAccess
122 virtual css::uno::Type SAL_CALL getElementType( ) override;
123 virtual sal_Bool SAL_CALL hasElements( ) override;
124
125 //XNameAccess
126 virtual css::uno::Any SAL_CALL getByName(const OUString& Name) override;
127 virtual css::uno::Sequence< OUString > SAL_CALL getElementNames() override;
128 virtual sal_Bool SAL_CALL hasByName(const OUString& Name) override;
129
130};
131
132// access to a family of automatic styles (character or paragraph or ...)
133class SwXAutoStyleFamily final : public cppu::WeakImplHelper< css::style::XAutoStyleFamily >, public SvtListener
134{
137
138
139public:
141 virtual ~SwXAutoStyleFamily() override;
142
143 //XAutoStyleFamily
144 virtual css::uno::Reference< css::style::XAutoStyle > SAL_CALL insertStyle( const css::uno::Sequence< css::beans::PropertyValue >& Values ) override;
145
146 //XEnumerationAccess
147 virtual css::uno::Reference< css::container::XEnumeration > SAL_CALL createEnumeration( ) override;
148
149 //XElementAccess
150 virtual css::uno::Type SAL_CALL getElementType( ) override;
151 virtual sal_Bool SAL_CALL hasElements( ) override;
152
153 virtual void Notify( const SfxHint&) override;
154};
155
156class SwXAutoStylesEnumerator final : public cppu::WeakImplHelper< css::container::XEnumeration >, public SvtListener
157{
158 std::unique_ptr<SwAutoStylesEnumImpl> m_pImpl;
159public:
161 virtual ~SwXAutoStylesEnumerator() override;
162
163 //XEnumeration
164 virtual sal_Bool SAL_CALL hasMoreElements( ) override;
165 virtual css::uno::Any SAL_CALL nextElement( ) override;
166
167 virtual void Notify( const SfxHint&) override;
168};
169
170// an automatic style
171class SwXAutoStyle final : public cppu::WeakImplHelper
172<
173 css::beans::XPropertySet,
174 css::beans::XPropertyState,
175 css::style::XAutoStyle
176>,
177 public SvtListener
178{
179private:
180 std::shared_ptr<SfxItemSet> mpSet;
183
187 css::uno::Sequence< css::uno::Any > GetPropertyValues_Impl( const css::uno::Sequence< OUString >& aPropertyNames );
188
189public:
190
191 SwXAutoStyle( SwDoc* pDoc, std::shared_ptr<SfxItemSet> pInitSet, IStyleAccess::SwAutoStyleFamily eFam );
192 virtual ~SwXAutoStyle() override;
193
194 //XPropertySet
195 virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) override;
196 virtual void SAL_CALL setPropertyValue( const OUString& aPropertyName, const css::uno::Any& aValue ) override;
197 virtual css::uno::Any SAL_CALL getPropertyValue( const OUString& PropertyName ) override;
198 virtual void SAL_CALL addPropertyChangeListener( const OUString& aPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener >& xListener ) override;
199 virtual void SAL_CALL removePropertyChangeListener( const OUString& aPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener >& aListener ) override;
200 virtual void SAL_CALL addVetoableChangeListener( const OUString& PropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener >& aListener ) override;
201 virtual void SAL_CALL removeVetoableChangeListener( const OUString& PropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener >& aListener ) override;
202
203 //XMultiPropertySet
204 virtual void SAL_CALL setPropertyValues( const css::uno::Sequence< OUString >& aPropertyNames, const css::uno::Sequence< css::uno::Any >& aValues ) override;
205 virtual css::uno::Sequence< css::uno::Any > SAL_CALL getPropertyValues( const css::uno::Sequence< OUString >& aPropertyNames ) override;
206 virtual void SAL_CALL addPropertiesChangeListener( const css::uno::Sequence< OUString >& aPropertyNames, const css::uno::Reference< css::beans::XPropertiesChangeListener >& xListener ) override;
207 virtual void SAL_CALL removePropertiesChangeListener( const css::uno::Reference< css::beans::XPropertiesChangeListener >& xListener ) override;
208 virtual void SAL_CALL firePropertiesChangeEvent( const css::uno::Sequence< OUString >& aPropertyNames, const css::uno::Reference< css::beans::XPropertiesChangeListener >& xListener ) override;
209
210 //XPropertyState
211 virtual css::beans::PropertyState SAL_CALL getPropertyState( const OUString& PropertyName ) override;
212 virtual css::uno::Sequence< css::beans::PropertyState > SAL_CALL getPropertyStates( const css::uno::Sequence< OUString >& aPropertyName ) override;
213 virtual void SAL_CALL setPropertyToDefault( const OUString& PropertyName ) override;
214 virtual css::uno::Any SAL_CALL getPropertyDefault( const OUString& aPropertyName ) override;
215
216 //XMultiPropertyStates
217 virtual void SAL_CALL setAllPropertiesToDefault( ) override;
218 virtual void SAL_CALL setPropertiesToDefault( const css::uno::Sequence< OUString >& aPropertyNames ) override;
219 virtual css::uno::Sequence< css::uno::Any > SAL_CALL getPropertyDefaults( const css::uno::Sequence< OUString >& aPropertyNames ) override;
220
221 // Special
222 virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getProperties() override;
223
224 virtual void Notify( const SfxHint& ) override;
225
226};
227
228typedef std::map<OUString, sal_Int32> CellStyleNameMap;
229
231class SwXTextTableStyle final : public cppu::WeakImplHelper
232<
233 css::style::XStyle,
234 css::beans::XPropertySet,
235 css::container::XNameContainer,
236 css::lang::XServiceInfo
237>
238{
242 std::unique_ptr<SwTableAutoFormat> m_pTableAutoFormat_Impl;
245
246 enum {
257 // loext namespace
265 };
266
270 css::uno::Reference<css::style::XStyle> m_aCellStyles[STYLE_COUNT];
271public:
272 SwXTextTableStyle(SwDocShell* pDocShell, SwTableAutoFormat* pTableAutoFormat);
274 SwXTextTableStyle(SwDocShell* pDocShell, const OUString& rTableAutoFormatName);
275
277 static SwTableAutoFormat* GetTableAutoFormat(SwDocShell* pDocShell, std::u16string_view sName);
280 void SetPhysical();
281
282 //XStyle
283 virtual sal_Bool SAL_CALL isUserDefined() override;
284 virtual sal_Bool SAL_CALL isInUse() override;
285 virtual OUString SAL_CALL getParentStyle() override;
286 virtual void SAL_CALL setParentStyle(const OUString& aParentStyle ) override;
287
288 //XNamed
289 virtual OUString SAL_CALL getName() override;
290 virtual void SAL_CALL setName(const OUString& rName) override;
291
292 //XPropertySet
293 virtual css::uno::Reference<css::beans::XPropertySetInfo> SAL_CALL getPropertySetInfo() override;
294 virtual void SAL_CALL setPropertyValue(const OUString& aPropertyName, const css::uno::Any& aValue) override;
295 virtual css::uno::Any SAL_CALL getPropertyValue(const OUString& PropertyName) override;
296 virtual void SAL_CALL addPropertyChangeListener(const OUString& aPropertyName, const css::uno::Reference<css::beans::XPropertyChangeListener>& xListener) override;
297 virtual void SAL_CALL removePropertyChangeListener(const OUString& aPropertyName, const css::uno::Reference<css::beans::XPropertyChangeListener>& aListener) override;
298 virtual void SAL_CALL addVetoableChangeListener(const OUString& PropertyName, const css::uno::Reference<css::beans::XVetoableChangeListener>& aListener) override;
299 virtual void SAL_CALL removeVetoableChangeListener(const OUString& PropertyName, const css::uno::Reference<css::beans::XVetoableChangeListener>& aListener) override;
300
301 //XNameAccess
302 virtual css::uno::Any SAL_CALL getByName(const OUString& rName) override;
303 virtual css::uno::Sequence<OUString> SAL_CALL getElementNames() override;
304 virtual sal_Bool SAL_CALL hasByName(const OUString& rName) override;
305
306 //XNameContainer
307 virtual void SAL_CALL insertByName(const OUString& rName, const css::uno::Any& aElement) override;
308 virtual void SAL_CALL replaceByName(const OUString& rName, const css::uno::Any& aElement) override;
309 virtual void SAL_CALL removeByName(const OUString& rName) override;
310
311 //XElementAccess
312 virtual css::uno::Type SAL_CALL getElementType() override;
313 virtual sal_Bool SAL_CALL hasElements() override;
314
315 //XServiceInfo
316 virtual OUString SAL_CALL getImplementationName() override;
317 virtual sal_Bool SAL_CALL supportsService(const OUString& rServiceName) override;
318 virtual css::uno::Sequence<OUString> SAL_CALL getSupportedServiceNames() override;
319
320 static css::uno::Reference<css::style::XStyle> CreateXTextTableStyle(SwDocShell* pDocShell, const OUString& rTableAutoFormatName);
321};
322
324class SwXTextCellStyle final : public cppu::WeakImplHelper
325<
326 css::style::XStyle,
327 css::beans::XPropertySet,
328 css::beans::XPropertyState,
329 css::lang::XServiceInfo
330>
331{
335 std::shared_ptr<SwBoxAutoFormat> m_pBoxAutoFormat_Impl;
337 OUString m_sName;
340
341 public:
342 SwXTextCellStyle(SwDocShell* pDocShell, SwBoxAutoFormat* pBoxAutoFormat, OUString sParentStyle);
344 SwXTextCellStyle(SwDocShell* pDocShell, OUString sName);
345
353 static SwBoxAutoFormat* GetBoxAutoFormat(SwDocShell* pDocShell, std::u16string_view sName, OUString* pParentName);
357 void SetBoxFormat(SwBoxAutoFormat* pBoxFormat);
358 void SetPhysical();
359 bool IsPhysical() const;
360
361 //XStyle
362 virtual sal_Bool SAL_CALL isUserDefined() override;
363 virtual sal_Bool SAL_CALL isInUse() override;
364 virtual OUString SAL_CALL getParentStyle() override;
365 virtual void SAL_CALL setParentStyle(const OUString& aParentStyle ) override;
366
367 //XNamed
368 virtual OUString SAL_CALL getName() override;
369 virtual void SAL_CALL setName(const OUString& sName) override;
370
371 //XPropertySet
372 virtual css::uno::Reference<css::beans::XPropertySetInfo> SAL_CALL getPropertySetInfo() override;
373 virtual void SAL_CALL setPropertyValue(const OUString& aPropertyName, const css::uno::Any& aValue) override;
374 virtual css::uno::Any SAL_CALL getPropertyValue(const OUString& PropertyName) override;
375 virtual void SAL_CALL addPropertyChangeListener(const OUString& aPropertyName, const css::uno::Reference<css::beans::XPropertyChangeListener>& xListener) override;
376 virtual void SAL_CALL removePropertyChangeListener(const OUString& aPropertyName, const css::uno::Reference<css::beans::XPropertyChangeListener>& aListener) override;
377 virtual void SAL_CALL addVetoableChangeListener(const OUString& PropertyName, const css::uno::Reference<css::beans::XVetoableChangeListener>& aListener) override;
378 virtual void SAL_CALL removeVetoableChangeListener(const OUString& PropertyName, const css::uno::Reference<css::beans::XVetoableChangeListener>& aListener) override;
379
380 //XPropertyState
381 virtual css::beans::PropertyState SAL_CALL getPropertyState(const OUString& PropertyName) override;
382 virtual css::uno::Sequence<css::beans::PropertyState> SAL_CALL getPropertyStates(const css::uno::Sequence< OUString >& aPropertyName) override;
383 virtual void SAL_CALL setPropertyToDefault(const OUString& PropertyName) override;
384 virtual css::uno::Any SAL_CALL getPropertyDefault(const OUString& aPropertyName) override;
385
386 //XServiceInfo
387 virtual OUString SAL_CALL getImplementationName() override;
388 virtual sal_Bool SAL_CALL supportsService(const OUString& rServiceName) override;
389 virtual css::uno::Sequence<OUString> SAL_CALL getSupportedServiceNames() override;
390
391 static css::uno::Reference<css::style::XStyle> CreateXTextCellStyle(SwDocShell* pDocShell, const OUString& sName);
392};
393
394/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Definition: doc.hxx:195
virtual css::uno::Type SAL_CALL getElementType() override
Definition: unostyle.cxx:3742
virtual void Notify(const SfxHint &) override
Definition: unostyle.cxx:3502
SwDocShell * m_pDocShell
Definition: unostyle.hxx:135
virtual ~SwXAutoStyleFamily() override
Definition: unostyle.cxx:3498
virtual css::uno::Reference< css::container::XEnumeration > SAL_CALL createEnumeration() override
Definition: unostyle.cxx:3734
IStyleAccess::SwAutoStyleFamily m_eFamily
Definition: unostyle.hxx:136
virtual css::uno::Reference< css::style::XAutoStyle > SAL_CALL insertStyle(const css::uno::Sequence< css::beans::PropertyValue > &Values) override
Definition: unostyle.cxx:3508
virtual sal_Bool SAL_CALL hasElements() override
Definition: unostyle.cxx:3747
SwXAutoStyleFamily(SwDocShell *pDocShell, IStyleAccess::SwAutoStyleFamily eFamily)
Definition: unostyle.cxx:3491
virtual void SAL_CALL removePropertyChangeListener(const OUString &aPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &aListener) override
Definition: unostyle.cxx:3903
virtual void SAL_CALL setAllPropertiesToDefault() override
Definition: unostyle.cxx:4206
SwDoc & mrDoc
Definition: unostyle.hxx:182
virtual void Notify(const SfxHint &) override
Definition: unostyle.cxx:3850
virtual css::uno::Sequence< css::beans::PropertyState > SAL_CALL getPropertyStates(const css::uno::Sequence< OUString > &aPropertyName) override
Definition: unostyle.cxx:4122
IStyleAccess::SwAutoStyleFamily meFamily
Definition: unostyle.hxx:181
virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo() override
Definition: unostyle.cxx:3856
virtual void SAL_CALL addPropertiesChangeListener(const css::uno::Sequence< OUString > &aPropertyNames, const css::uno::Reference< css::beans::XPropertiesChangeListener > &xListener) override
Definition: unostyle.cxx:4086
css::uno::Sequence< css::uno::Any > GetPropertyValues_Impl(const css::uno::Sequence< OUString > &aPropertyNames)
Definition: unostyle.cxx:3924
SwXAutoStyle(SwDoc *pDoc, std::shared_ptr< SfxItemSet > pInitSet, IStyleAccess::SwAutoStyleFamily eFam)
Definition: unostyle.cxx:3834
virtual void SAL_CALL removePropertiesChangeListener(const css::uno::Reference< css::beans::XPropertiesChangeListener > &xListener) override
Definition: unostyle.cxx:4092
virtual css::uno::Sequence< css::uno::Any > SAL_CALL getPropertyDefaults(const css::uno::Sequence< OUString > &aPropertyNames) override
Definition: unostyle.cxx:4215
virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getProperties() override
Definition: unostyle.cxx:4221
virtual css::uno::Sequence< css::uno::Any > SAL_CALL getPropertyValues(const css::uno::Sequence< OUString > &aPropertyNames) override
Definition: unostyle.cxx:4061
virtual void SAL_CALL firePropertiesChangeEvent(const css::uno::Sequence< OUString > &aPropertyNames, const css::uno::Reference< css::beans::XPropertiesChangeListener > &xListener) override
Definition: unostyle.cxx:4097
virtual void SAL_CALL removeVetoableChangeListener(const OUString &PropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &aListener) override
Definition: unostyle.cxx:3913
std::shared_ptr< SfxItemSet > mpSet
Definition: unostyle.hxx:180
virtual css::uno::Any SAL_CALL getPropertyDefault(const OUString &aPropertyName) override
Definition: unostyle.cxx:4116
virtual ~SwXAutoStyle() override
Definition: unostyle.cxx:3846
virtual void SAL_CALL addPropertyChangeListener(const OUString &aPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &xListener) override
Definition: unostyle.cxx:3898
virtual void SAL_CALL setPropertiesToDefault(const css::uno::Sequence< OUString > &aPropertyNames) override
Definition: unostyle.cxx:4210
virtual css::beans::PropertyState SAL_CALL getPropertyState(const OUString &PropertyName) override
Definition: unostyle.cxx:4103
virtual css::uno::Any SAL_CALL getPropertyValue(const OUString &PropertyName) override
Definition: unostyle.cxx:3891
virtual void SAL_CALL setPropertyValue(const OUString &aPropertyName, const css::uno::Any &aValue) override
Definition: unostyle.cxx:3887
virtual void SAL_CALL setPropertyToDefault(const OUString &PropertyName) override
Definition: unostyle.cxx:4112
virtual void SAL_CALL addVetoableChangeListener(const OUString &PropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &aListener) override
Definition: unostyle.cxx:3908
virtual void SAL_CALL setPropertyValues(const css::uno::Sequence< OUString > &aPropertyNames, const css::uno::Sequence< css::uno::Any > &aValues) override
Definition: unostyle.cxx:3918
virtual css::uno::Any SAL_CALL nextElement() override
Definition: unostyle.cxx:3812
SwXAutoStylesEnumerator(SwDoc &rDoc, IStyleAccess::SwAutoStyleFamily eFam)
Definition: unostyle.cxx:3788
virtual sal_Bool SAL_CALL hasMoreElements() override
Definition: unostyle.cxx:3805
virtual void Notify(const SfxHint &) override
Definition: unostyle.cxx:3799
std::unique_ptr< SwAutoStylesEnumImpl > m_pImpl
Definition: unostyle.hxx:158
virtual ~SwXAutoStylesEnumerator() override
Definition: unostyle.cxx:3795
SwDocShell * m_pDocShell
Definition: unostyle.hxx:108
SwXAutoStyles(SwDocShell &rDocShell)
Definition: unostyle.cxx:3390
virtual css::uno::Any SAL_CALL getByName(const OUString &Name) override
Definition: unostyle.cxx:3457
virtual sal_Bool SAL_CALL hasByName(const OUString &Name) override
Definition: unostyle.cxx:3481
css::uno::Reference< css::style::XAutoStyleFamily > m_xAutoRubyStyles
Definition: unostyle.hxx:110
css::uno::Reference< css::style::XAutoStyleFamily > m_xAutoCharStyles
Definition: unostyle.hxx:109
virtual sal_Bool SAL_CALL hasElements() override
Definition: unostyle.cxx:3452
virtual sal_Int32 SAL_CALL getCount() override
Definition: unostyle.cxx:3399
css::uno::Reference< css::style::XAutoStyleFamily > m_xAutoParaStyles
Definition: unostyle.hxx:111
virtual css::uno::Sequence< OUString > SAL_CALL getElementNames() override
Definition: unostyle.cxx:3471
virtual css::uno::Type SAL_CALL getElementType() override
Definition: unostyle.cxx:3447
virtual ~SwXAutoStyles() override
Definition: unostyle.cxx:3395
virtual css::uno::Any SAL_CALL getByIndex(sal_Int32 nIndex) override
Definition: unostyle.cxx:3404
virtual sal_Bool SAL_CALL hasByName(const OUString &Name) override
Definition: unostyle.cxx:887
virtual ~SwXStyleFamilies() override
Definition: unostyle.cxx:862
virtual OUString SAL_CALL getImplementationName() override
Definition: unostyle.cxx:846
virtual css::uno::Sequence< OUString > SAL_CALL getElementNames() override
Definition: unostyle.cxx:878
std::map< SfxStyleFamily, css::uno::Reference< css::container::XNameContainer > > m_vFamilies
Definition: unostyle.hxx:57
virtual css::uno::Any SAL_CALL getByIndex(sal_Int32 nIndex) override
Definition: unostyle.cxx:899
virtual void SAL_CALL loadStylesFromURL(const OUString &rURL, const css::uno::Sequence< css::beans::PropertyValue > &aOptions) override
Definition: unostyle.cxx:923
virtual css::uno::Type SAL_CALL getElementType() override
Definition: unostyle.cxx:915
virtual sal_Int32 SAL_CALL getCount() override
Definition: unostyle.cxx:894
virtual sal_Bool SAL_CALL supportsService(const OUString &ServiceName) override
Definition: unostyle.cxx:849
static css::uno::Reference< css::style::XStyle > CreateStyle(SfxStyleFamily eFamily, SwDoc &rDoc)
Definition: unostyle.cxx:997
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: unostyle.cxx:854
virtual sal_Bool SAL_CALL hasElements() override
Definition: unostyle.cxx:920
SwDocShell * m_pDocShell
Definition: unostyle.hxx:55
virtual css::uno::Any SAL_CALL getByName(const OUString &Name) override
Definition: unostyle.cxx:865
virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getStyleLoaderOptions() override
Definition: unostyle.cxx:968
static css::uno::Reference< css::style::XStyle > CreateStyleCondParagraph(SwDoc &rDoc)
Definition: unostyle.cxx:1006
SwXStyleFamilies(SwDocShell &rDocShell)
Definition: unostyle.cxx:857
A text cell style is a UNO API wrapper for a SwBoxAutoFormat core class.
Definition: unostyle.hxx:331
virtual void SAL_CALL setParentStyle(const OUString &aParentStyle) override
Definition: unostyle.cxx:4776
bool m_bPhysical
If true, then it points to a core object, if false, then this is a created, but not-yet-inserted form...
Definition: unostyle.hxx:339
virtual sal_Bool SAL_CALL isUserDefined() override
Definition: unostyle.cxx:4736
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: unostyle.cxx:5578
SwDocShell * m_pDocShell
Definition: unostyle.hxx:332
static css::uno::Reference< css::style::XStyle > CreateXTextCellStyle(SwDocShell *pDocShell, const OUString &sName)
Definition: unostyle.cxx:4705
virtual sal_Bool SAL_CALL supportsService(const OUString &rServiceName) override
Definition: unostyle.cxx:5573
virtual void SAL_CALL removePropertyChangeListener(const OUString &aPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &aListener) override
Definition: unostyle.cxx:5185
void SetBoxFormat(SwBoxAutoFormat *pBoxFormat)
Sets the address of SwBoxAutoFormat this style is bound to. Usable only when style is physical.
Definition: unostyle.cxx:4633
SwBoxAutoFormat * GetBoxFormat()
returns box format assigned to this style
Definition: unostyle.cxx:4628
virtual sal_Bool SAL_CALL isInUse() override
Definition: unostyle.cxx:4746
virtual css::uno::Sequence< css::beans::PropertyState > SAL_CALL getPropertyStates(const css::uno::Sequence< OUString > &aPropertyName) override
Definition: unostyle.cxx:5209
virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo() override
Definition: unostyle.cxx:4821
virtual css::beans::PropertyState SAL_CALL getPropertyState(const OUString &PropertyName) override
Definition: unostyle.cxx:5201
virtual OUString SAL_CALL getName() override
Definition: unostyle.cxx:4783
SwBoxAutoFormat * m_pBoxAutoFormat
Definition: unostyle.hxx:333
bool IsPhysical() const
Definition: unostyle.cxx:4660
virtual void SAL_CALL setPropertyValue(const OUString &aPropertyName, const css::uno::Any &aValue) override
Definition: unostyle.cxx:4827
virtual OUString SAL_CALL getImplementationName() override
Definition: unostyle.cxx:5568
virtual void SAL_CALL setPropertyToDefault(const OUString &PropertyName) override
Definition: unostyle.cxx:5359
virtual void SAL_CALL addPropertyChangeListener(const OUString &aPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &xListener) override
Definition: unostyle.cxx:5180
virtual void SAL_CALL setName(const OUString &sName) override
Definition: unostyle.cxx:4810
OUString m_sParentStyle
Definition: unostyle.hxx:336
SwXTextCellStyle(SwDocShell *pDocShell, SwBoxAutoFormat *pBoxAutoFormat, OUString sParentStyle)
Definition: unostyle.cxx:4612
std::shared_ptr< SwBoxAutoFormat > m_pBoxAutoFormat_Impl
Stores SwBoxAutoFormat when this is not a physical style.
Definition: unostyle.hxx:335
virtual OUString SAL_CALL getParentStyle() override
Definition: unostyle.cxx:4770
virtual void SAL_CALL addVetoableChangeListener(const OUString &PropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &aListener) override
Definition: unostyle.cxx:5190
static SwBoxAutoFormat * GetBoxAutoFormat(SwDocShell *pDocShell, std::u16string_view sName, OUString *pParentName)
This function looks for a SwBoxAutoFormat with given name.
Definition: unostyle.cxx:4665
virtual css::uno::Any SAL_CALL getPropertyValue(const OUString &PropertyName) override
Definition: unostyle.cxx:5016
virtual css::uno::Any SAL_CALL getPropertyDefault(const OUString &aPropertyName) override
Definition: unostyle.cxx:5560
OUString m_sName
Definition: unostyle.hxx:337
virtual void SAL_CALL removeVetoableChangeListener(const OUString &PropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &aListener) override
Definition: unostyle.cxx:5195
A text table style is a UNO API wrapper for a SwTableAutoFormat.
Definition: unostyle.hxx:238
SwTableAutoFormat * m_pTableAutoFormat
Definition: unostyle.hxx:240
virtual void SAL_CALL setParentStyle(const OUString &aParentStyle) override
Definition: unostyle.cxx:4443
SwDocShell * m_pDocShell
Definition: unostyle.hxx:239
virtual void SAL_CALL insertByName(const OUString &rName, const css::uno::Any &aElement) override
Definition: unostyle.cxx:4539
virtual void SAL_CALL setName(const OUString &rName) override
Definition: unostyle.cxx:4455
static const CellStyleNameMap & GetCellStyleNameMap()
Definition: unostyle.cxx:4328
virtual void SAL_CALL removeByName(const OUString &rName) override
Definition: unostyle.cxx:4579
virtual OUString SAL_CALL getParentStyle() override
Definition: unostyle.cxx:4438
virtual sal_Bool SAL_CALL hasElements() override
Definition: unostyle.cxx:4590
SwXTextTableStyle(SwDocShell *pDocShell, SwTableAutoFormat *pTableAutoFormat)
Definition: unostyle.cxx:4273
bool m_bPhysical
If true, then it points to a core object, if false, then this is a created, but not-yet-inserted form...
Definition: unostyle.hxx:244
void UpdateCellStylesMapping()
Fills m_aCellStyles with SwXTextCellStyles pointing to children of this style.
Definition: unostyle.cxx:4311
virtual css::uno::Sequence< OUString > SAL_CALL getElementNames() override
Definition: unostyle.cxx:4526
virtual void SAL_CALL removePropertyChangeListener(const OUString &aPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &aListener) override
Definition: unostyle.cxx:4499
virtual OUString SAL_CALL getName() override
Definition: unostyle.cxx:4447
virtual css::uno::Type SAL_CALL getElementType() override
Definition: unostyle.cxx:4585
virtual css::uno::Any SAL_CALL getPropertyValue(const OUString &PropertyName) override
Definition: unostyle.cxx:4473
virtual sal_Bool SAL_CALL isInUse() override
Definition: unostyle.cxx:4417
static css::uno::Reference< css::style::XStyle > CreateXTextTableStyle(SwDocShell *pDocShell, const OUString &rTableAutoFormatName)
Definition: unostyle.cxx:4286
virtual void SAL_CALL addPropertyChangeListener(const OUString &aPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &xListener) override
Definition: unostyle.cxx:4494
virtual void SAL_CALL replaceByName(const OUString &rName, const css::uno::Any &aElement) override
Definition: unostyle.cxx:4544
virtual void SAL_CALL setPropertyValue(const OUString &aPropertyName, const css::uno::Any &aValue) override
Definition: unostyle.cxx:4468
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: unostyle.cxx:4606
virtual sal_Bool SAL_CALL isUserDefined() override
Definition: unostyle.cxx:4407
std::unique_ptr< SwTableAutoFormat > m_pTableAutoFormat_Impl
Stores SwTableAutoFormat when this is not a physical style.
Definition: unostyle.hxx:242
virtual void SAL_CALL addVetoableChangeListener(const OUString &PropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &aListener) override
Definition: unostyle.cxx:4504
virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo() override
Definition: unostyle.cxx:4462
virtual void SAL_CALL removeVetoableChangeListener(const OUString &PropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &aListener) override
Definition: unostyle.cxx:4509
@ FIRST_ROW_START_COLUMN_STYLE
Definition: unostyle.hxx:258
virtual css::uno::Any SAL_CALL getByName(const OUString &rName) override
Definition: unostyle.cxx:4515
virtual sal_Bool SAL_CALL hasByName(const OUString &rName) override
Definition: unostyle.cxx:4531
virtual OUString SAL_CALL getImplementationName() override
Definition: unostyle.cxx:4596
SwTableAutoFormat * GetTableFormat()
Returns box format assigned to this style.
Definition: unostyle.cxx:4353
static SwTableAutoFormat * GetTableAutoFormat(SwDocShell *pDocShell, std::u16string_view sName)
This function looks for a SwTableAutoFormat with given name. Returns nullptr if could not be found.
Definition: unostyle.cxx:4358
css::uno::Reference< css::style::XStyle > m_aCellStyles[STYLE_COUNT]
Definition: unostyle.hxx:270
virtual sal_Bool SAL_CALL supportsService(const OUString &rServiceName) override
Definition: unostyle.cxx:4601
virtual ~ICoreFrameStyle()
Definition: unostyle.hxx:99
virtual const SfxPoolItem * GetItem(sal_uInt16 eAtr)=0
virtual css::document::XEventsSupplier & GetEventsSupplier()=0
virtual void SetItem(sal_uInt16 eAtr, const SfxPoolItem &rItem)=0
std::map< OUString, sal_Int32 > CellStyleNameMap
Dialog to specify the properties of date form field.
SfxStyleFamily
unsigned char sal_Bool
std::map< OUString, sal_Int32 > CellStyleNameMap
Definition: unostyle.hxx:228