LibreOffice Module sw (master) 1
SwXDocumentSettings.cxx
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
20#include <config_features.h>
21#include <config_fuzzers.h>
22
23#include <sal/config.h>
24#include <sal/log.hxx>
25
26#include <utility>
27
28#include <o3tl/any.hxx>
33#include <com/sun/star/beans/PropertyAttribute.hpp>
34#include <com/sun/star/i18n/XForbiddenCharacters.hpp>
35#include <com/sun/star/document/PrinterIndependentLayout.hpp>
36#include <doc.hxx>
40#include <docsh.hxx>
41#include <fldupde.hxx>
42#include <linkenum.hxx>
43#include <sfx2/printer.hxx>
44#include <editsh.hxx>
45#include <unotxdoc.hxx>
46#include <cmdid.h>
47#include <unomod.hxx>
48#include <vcl/svapp.hxx>
49#include <svl/asiancfg.hxx>
50#include <tools/stream.hxx>
51
52#include <cfgitems.hxx>
53#include <dbmgr.hxx>
54
55using namespace comphelper;
56using namespace ::com::sun::star;
57using namespace ::com::sun::star::uno;
58using namespace ::com::sun::star::beans;
59using namespace ::com::sun::star::lang;
60using namespace ::com::sun::star::i18n;
61
62namespace {
63
64enum SwDocumentSettingsPropertyHandles
65{
66 HANDLE_FORBIDDEN_CHARS,
67 HANDLE_LINK_UPDATE_MODE,
68 HANDLE_FIELD_AUTO_UPDATE,
69 HANDLE_CHART_AUTO_UPDATE,
70 HANDLE_ADD_PARA_TABLE_SPACING,
71 HANDLE_ADD_PARA_TABLE_SPACING_AT_START,
72 HANDLE_ALIGN_TAB_STOP_POSITION,
73 HANDLE_PRINTER_NAME,
74 HANDLE_PRINTER_SETUP,
75 HANDLE_PRINTER_PAPER,
76 HANDLE_IS_KERN_ASIAN_PUNCTUATION,
77 HANDLE_CHARACTER_COMPRESSION_TYPE,
78 HANDLE_APPLY_USER_DATA,
79 HANDLE_SAVE_THUMBNAIL,
80 HANDLE_SAVE_GLOBAL_DOCUMENT_LINKS,
81 HANDLE_CURRENT_DATABASE_DATA_SOURCE,
82 HANDLE_CURRENT_DATABASE_COMMAND,
83 HANDLE_CURRENT_DATABASE_COMMAND_TYPE,
84 HANDLE_EMBEDDED_DATABASE_NAME,
85 HANDLE_SAVE_VERSION_ON_CLOSE,
86 HANDLE_UPDATE_FROM_TEMPLATE,
87 HANDLE_PRINTER_INDEPENDENT_LAYOUT,
88 HANDLE_IS_LABEL_DOC,
89 HANDLE_IS_ADD_FLY_OFFSET,
90 HANDLE_IS_ADD_VERTICAL_FLY_OFFSET,
91 HANDLE_IS_ADD_EXTERNAL_LEADING,
92 HANDLE_OLD_NUMBERING,
93 HANDLE_OUTLINELEVEL_YIELDS_NUMBERING,
94 /* Stampit It disable the print cancel button of the shown progress dialog. */
95 HANDLE_ALLOW_PRINTJOB_CANCEL,
96 HANDLE_USE_FORMER_LINE_SPACING,
97 HANDLE_ADD_PARA_SPACING_TO_TABLE_CELLS,
98 HANDLE_ADD_PARA_LINE_SPACING_TO_TABLE_CELLS,
99 HANDLE_USE_FORMER_OBJECT_POSITIONING,
100 HANDLE_USE_FORMER_TEXT_WRAPPING,
101 HANDLE_CHANGES_PASSWORD,
102 HANDLE_CONSIDER_WRAP_ON_OBJPOS,
103 HANDLE_IGNORE_FIRST_LINE_INDENT_IN_NUMBERING,
104 HANDLE_DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK,
105 HANDLE_DO_NOT_RESET_PARA_ATTRS_FOR_NUM_FONT,
106 HANDLE_TABLE_ROW_KEEP,
107 HANDLE_IGNORE_TABS_AND_BLANKS_FOR_LINE_CALCULATION,
108 HANDLE_LOAD_READONLY,
109 HANDLE_DO_NOT_CAPTURE_DRAW_OBJS_ON_PAGE,
110 HANDLE_CLIP_AS_CHARACTER_ANCHORED_WRITER_FLY_FRAMES,
111 HANDLE_UNIX_FORCE_ZERO_EXT_LEADING,
112 HANDLE_USE_OLD_PRINTER_METRICS,
113 HANDLE_PROTECT_FORM,
114 HANDLE_MS_WORD_COMP_TRAILING_BLANKS,
115 HANDLE_MS_WORD_COMP_MIN_LINE_HEIGHT_BY_FLY,
116 HANDLE_TABS_RELATIVE_TO_INDENT,
117 HANDLE_RSID,
118 HANDLE_RSID_ROOT,
119 HANDLE_TAB_AT_LEFT_INDENT_FOR_PARA_IN_LIST,
120 HANDLE_MODIFYPASSWORDINFO,
121 HANDLE_MATH_BASELINE_ALIGNMENT,
122 HANDLE_INVERT_BORDER_SPACING,
123 HANDLE_COLLAPSE_EMPTY_CELL_PARA,
124 HANDLE_SMALL_CAPS_PERCENTAGE_66,
125 HANDLE_TAB_OVERFLOW,
126 HANDLE_UNBREAKABLE_NUMBERINGS,
127 HANDLE_STYLES_NODEFAULT,
128 HANDLE_FLOATTABLE_NOMARGINS,
129 HANDLE_CLIPPED_PICTURES,
130 HANDLE_BACKGROUND_PARA_OVER_DRAWINGS,
131 HANDLE_EMBED_FONTS,
132 HANDLE_EMBED_USED_FONTS,
133 HANDLE_EMBED_LATIN_SCRIPT_FONTS,
134 HANDLE_EMBED_ASIAN_SCRIPT_FONTS,
135 HANDLE_EMBED_COMPLEX_SCRIPT_FONTS,
136 HANDLE_EMBED_SYSTEM_FONTS,
137 HANDLE_TAB_OVER_MARGIN,
138 HANDLE_TAB_OVER_SPACING,
139 HANDLE_TREAT_SINGLE_COLUMN_BREAK_AS_PAGE_BREAK,
140 HANDLE_SURROUND_TEXT_WRAP_SMALL,
141 HANDLE_APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING,
142 HANDLE_PROP_LINE_SPACING_SHRINKS_FIRST_LINE,
143 HANDLE_SUBTRACT_FLYS,
144 HANDLE_DISABLE_OFF_PAGE_POSITIONING,
145 HANDLE_EMPTY_DB_FIELD_HIDES_PARA,
146 HANDLE_CONTINUOUS_ENDNOTES,
147 HANDLE_PROTECT_BOOKMARKS,
148 HANDLE_PROTECT_FIELDS,
149 HANDLE_HEADER_SPACING_BELOW_LAST_PARA,
150 HANDLE_FRAME_AUTOWIDTH_WITH_MORE_PARA,
151 HANDLE_GUTTER_AT_TOP,
152 HANDLE_FOOTNOTE_IN_COLUMN_TO_PAGEEND,
153 HANDLE_IMAGE_PREFERRED_DPI,
154 HANDLE_AUTO_FIRST_LINE_INDENT_DISREGARD_LINE_SPACE,
155 HANDLE_WORD_LIKE_WRAP_FOR_AS_CHAR_FLYS,
156 HANDLE_NO_NUMBERING_SHOW_FOLLOWBY,
157 HANDLE_DROP_CAP_PUNCTUATION
158};
159
160}
161
163{
164 static PropertyInfo const aWriterSettingsInfoMap[] =
165 {
166 { OUString("ForbiddenCharacters"), HANDLE_FORBIDDEN_CHARS, cppu::UnoType<css::i18n::XForbiddenCharacters>::get(), 0},
167 { OUString("LinkUpdateMode"), HANDLE_LINK_UPDATE_MODE, cppu::UnoType<sal_Int16>::get(), 0},
168 { OUString("FieldAutoUpdate"), HANDLE_FIELD_AUTO_UPDATE, cppu::UnoType<bool>::get(), 0},
169 { OUString("ChartAutoUpdate"), HANDLE_CHART_AUTO_UPDATE, cppu::UnoType<bool>::get(), 0},
170 { OUString("AddParaTableSpacing"), HANDLE_ADD_PARA_TABLE_SPACING, cppu::UnoType<bool>::get(), 0},
171 { OUString("AddParaTableSpacingAtStart"), HANDLE_ADD_PARA_TABLE_SPACING_AT_START, cppu::UnoType<bool>::get(), 0},
172 { OUString("AlignTabStopPosition"), HANDLE_ALIGN_TAB_STOP_POSITION, cppu::UnoType<bool>::get(), 0},
173 { OUString("PrinterName"), HANDLE_PRINTER_NAME, cppu::UnoType<OUString>::get(), 0},
174 { OUString("PrinterSetup"), HANDLE_PRINTER_SETUP, cppu::UnoType< cppu::UnoSequenceType<sal_Int8> >::get(), 0},
175 { OUString("PrinterPaperFromSetup"), HANDLE_PRINTER_PAPER, cppu::UnoType<bool>::get(), 0},
176 { OUString("IsKernAsianPunctuation"), HANDLE_IS_KERN_ASIAN_PUNCTUATION, cppu::UnoType<bool>::get(), 0},
177 { OUString("CharacterCompressionType"), HANDLE_CHARACTER_COMPRESSION_TYPE, cppu::UnoType<sal_Int16>::get(), 0},
178 { OUString("ApplyUserData"), HANDLE_APPLY_USER_DATA, cppu::UnoType<bool>::get(), 0 },
179 { OUString("SaveThumbnail"), HANDLE_SAVE_THUMBNAIL, cppu::UnoType<bool>::get(), 0 },
180 { OUString("SaveGlobalDocumentLinks"), HANDLE_SAVE_GLOBAL_DOCUMENT_LINKS, cppu::UnoType<bool>::get(), 0},
181 { OUString("CurrentDatabaseDataSource"), HANDLE_CURRENT_DATABASE_DATA_SOURCE, cppu::UnoType<OUString>::get(), 0},
182 { OUString("CurrentDatabaseCommand"), HANDLE_CURRENT_DATABASE_COMMAND, cppu::UnoType<OUString>::get(), 0},
183 { OUString("CurrentDatabaseCommandType"), HANDLE_CURRENT_DATABASE_COMMAND_TYPE, cppu::UnoType<sal_Int32>::get(), 0},
184 { OUString("EmbeddedDatabaseName"), HANDLE_EMBEDDED_DATABASE_NAME, cppu::UnoType<OUString>::get(), 0},
185 { OUString("SaveVersionOnClose"), HANDLE_SAVE_VERSION_ON_CLOSE, cppu::UnoType<bool>::get(), 0},
186 { OUString("UpdateFromTemplate"), HANDLE_UPDATE_FROM_TEMPLATE, cppu::UnoType<bool>::get(), 0},
187
188 { OUString("PrinterIndependentLayout"), HANDLE_PRINTER_INDEPENDENT_LAYOUT, cppu::UnoType<sal_Int16>::get(), 0},
189 { OUString("IsLabelDocument"), HANDLE_IS_LABEL_DOC, cppu::UnoType<bool>::get(), 0},
190 { OUString("AddFrameOffsets"), HANDLE_IS_ADD_FLY_OFFSET, cppu::UnoType<bool>::get(), 0},
191 { OUString("AddVerticalFrameOffsets"), HANDLE_IS_ADD_VERTICAL_FLY_OFFSET, cppu::UnoType<bool>::get(), 0},
192 { OUString("AddExternalLeading"), HANDLE_IS_ADD_EXTERNAL_LEADING, cppu::UnoType<bool>::get(), 0},
193 { OUString("UseOldNumbering"), HANDLE_OLD_NUMBERING, cppu::UnoType<bool>::get(), 0},
194 { OUString("OutlineLevelYieldsNumbering"), HANDLE_OUTLINELEVEL_YIELDS_NUMBERING, cppu::UnoType<bool>::get(), 0},
195 /* Stampit It disable the print cancel button of the shown progress dialog. */
196 { OUString("AllowPrintJobCancel"), HANDLE_ALLOW_PRINTJOB_CANCEL, cppu::UnoType<bool>::get(), 0},
197 { OUString("UseFormerLineSpacing"), HANDLE_USE_FORMER_LINE_SPACING, cppu::UnoType<bool>::get(), 0},
198 { OUString("AddParaSpacingToTableCells"), HANDLE_ADD_PARA_SPACING_TO_TABLE_CELLS, cppu::UnoType<bool>::get(), 0},
199 { OUString("AddParaLineSpacingToTableCells"), HANDLE_ADD_PARA_LINE_SPACING_TO_TABLE_CELLS, cppu::UnoType<bool>::get(), 0},
200 { OUString("UseFormerObjectPositioning"), HANDLE_USE_FORMER_OBJECT_POSITIONING, cppu::UnoType<bool>::get(), 0},
201 { OUString("UseFormerTextWrapping"), HANDLE_USE_FORMER_TEXT_WRAPPING, cppu::UnoType<bool>::get(), 0},
202 { OUString("RedlineProtectionKey"), HANDLE_CHANGES_PASSWORD, cppu::UnoType< cppu::UnoSequenceType<sal_Int8> >::get(), 0},
203 { OUString("ConsiderTextWrapOnObjPos"), HANDLE_CONSIDER_WRAP_ON_OBJPOS, cppu::UnoType<bool>::get(), 0},
204 { OUString("IgnoreFirstLineIndentInNumbering"), HANDLE_IGNORE_FIRST_LINE_INDENT_IN_NUMBERING, cppu::UnoType<bool>::get(), 0},
205 { OUString("DoNotJustifyLinesWithManualBreak"), HANDLE_DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK, cppu::UnoType<bool>::get(), 0},
206 { OUString("DoNotResetParaAttrsForNumFont"), HANDLE_DO_NOT_RESET_PARA_ATTRS_FOR_NUM_FONT, cppu::UnoType<bool>::get(), 0},
207 { OUString("TableRowKeep"), HANDLE_TABLE_ROW_KEEP, cppu::UnoType<bool>::get(), 0},
208 { OUString("IgnoreTabsAndBlanksForLineCalculation"), HANDLE_IGNORE_TABS_AND_BLANKS_FOR_LINE_CALCULATION, cppu::UnoType<bool>::get(), 0},
209 { OUString("LoadReadonly"), HANDLE_LOAD_READONLY, cppu::UnoType<bool>::get(), 0},
210 { OUString("DoNotCaptureDrawObjsOnPage"), HANDLE_DO_NOT_CAPTURE_DRAW_OBJS_ON_PAGE, cppu::UnoType<bool>::get(), 0},
211 { OUString("ClipAsCharacterAnchoredWriterFlyFrames"), HANDLE_CLIP_AS_CHARACTER_ANCHORED_WRITER_FLY_FRAMES, cppu::UnoType<bool>::get(), 0},
212 { OUString("UnxForceZeroExtLeading"), HANDLE_UNIX_FORCE_ZERO_EXT_LEADING, cppu::UnoType<bool>::get(), 0},
213 { OUString("UseOldPrinterMetrics"), HANDLE_USE_OLD_PRINTER_METRICS, cppu::UnoType<bool>::get(), 0},
214 { OUString("TabsRelativeToIndent"), HANDLE_TABS_RELATIVE_TO_INDENT, cppu::UnoType<bool>::get(), 0},
215 { OUString("Rsid"), HANDLE_RSID, cppu::UnoType<sal_Int32>::get(), 0},
216 { OUString("RsidRoot"), HANDLE_RSID_ROOT, cppu::UnoType<sal_Int32>::get(), 0},
217 { OUString("ProtectForm"), HANDLE_PROTECT_FORM, cppu::UnoType<bool>::get(), 0},
218 { OUString("MsWordCompTrailingBlanks"), HANDLE_MS_WORD_COMP_TRAILING_BLANKS, cppu::UnoType<bool>::get(), 0 },
219 { OUString("MsWordCompMinLineHeightByFly"), HANDLE_MS_WORD_COMP_MIN_LINE_HEIGHT_BY_FLY, cppu::UnoType<bool>::get(), 0 },
220 { OUString("TabAtLeftIndentForParagraphsInList"), HANDLE_TAB_AT_LEFT_INDENT_FOR_PARA_IN_LIST, cppu::UnoType<bool>::get(), 0},
221 { OUString("ModifyPasswordInfo"), HANDLE_MODIFYPASSWORDINFO, cppu::UnoType< cppu::UnoSequenceType<css::beans::PropertyValue> >::get(), 0},
222 { OUString("MathBaselineAlignment"), HANDLE_MATH_BASELINE_ALIGNMENT, cppu::UnoType<bool>::get(), 0},
223 { OUString("InvertBorderSpacing"), HANDLE_INVERT_BORDER_SPACING, cppu::UnoType<bool>::get(), 0},
224 { OUString("CollapseEmptyCellPara"), HANDLE_COLLAPSE_EMPTY_CELL_PARA, cppu::UnoType<bool>::get(), 0},
225 { OUString("SmallCapsPercentage66"), HANDLE_SMALL_CAPS_PERCENTAGE_66, cppu::UnoType<bool>::get(), 0},
226 { OUString("TabOverflow"), HANDLE_TAB_OVERFLOW, cppu::UnoType<bool>::get(), 0},
227 { OUString("UnbreakableNumberings"), HANDLE_UNBREAKABLE_NUMBERINGS, cppu::UnoType<bool>::get(), 0},
228 { OUString("StylesNoDefault"), HANDLE_STYLES_NODEFAULT, cppu::UnoType<bool>::get(), 0},
229 { OUString("FloattableNomargins"), HANDLE_FLOATTABLE_NOMARGINS, cppu::UnoType<bool>::get(), 0},
230 { OUString("ClippedPictures"), HANDLE_CLIPPED_PICTURES, cppu::UnoType<bool>::get(), 0},
231 { OUString("BackgroundParaOverDrawings"), HANDLE_BACKGROUND_PARA_OVER_DRAWINGS, cppu::UnoType<bool>::get(), 0},
232 { OUString("EmbedFonts"), HANDLE_EMBED_FONTS, cppu::UnoType<bool>::get(), 0},
233 { OUString("EmbedOnlyUsedFonts"), HANDLE_EMBED_USED_FONTS, cppu::UnoType<bool>::get(), 0},
234 { OUString("EmbedLatinScriptFonts"), HANDLE_EMBED_LATIN_SCRIPT_FONTS, cppu::UnoType<bool>::get(), 0},
235 { OUString("EmbedAsianScriptFonts"), HANDLE_EMBED_ASIAN_SCRIPT_FONTS, cppu::UnoType<bool>::get(), 0},
236 { OUString("EmbedComplexScriptFonts"), HANDLE_EMBED_COMPLEX_SCRIPT_FONTS, cppu::UnoType<bool>::get(), 0},
237 { OUString("EmbedSystemFonts"), HANDLE_EMBED_SYSTEM_FONTS, cppu::UnoType<bool>::get(), 0},
238 { OUString("TabOverMargin"), HANDLE_TAB_OVER_MARGIN, cppu::UnoType<bool>::get(), 0},
239 { OUString("TabOverSpacing"), HANDLE_TAB_OVER_SPACING, cppu::UnoType<bool>::get(), 0},
240 { OUString("TreatSingleColumnBreakAsPageBreak"), HANDLE_TREAT_SINGLE_COLUMN_BREAK_AS_PAGE_BREAK, cppu::UnoType<bool>::get(), 0},
241 { OUString("SurroundTextWrapSmall"), HANDLE_SURROUND_TEXT_WRAP_SMALL, cppu::UnoType<bool>::get(), 0},
242 { OUString("ApplyParagraphMarkFormatToNumbering"), HANDLE_APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING, cppu::UnoType<bool>::get(), 0},
243 { OUString("PropLineSpacingShrinksFirstLine"), HANDLE_PROP_LINE_SPACING_SHRINKS_FIRST_LINE, cppu::UnoType<bool>::get(), 0},
244 { OUString("SubtractFlysAnchoredAtFlys"), HANDLE_SUBTRACT_FLYS, cppu::UnoType<bool>::get(), 0},
245 { OUString("DisableOffPagePositioning"), HANDLE_DISABLE_OFF_PAGE_POSITIONING, cppu::UnoType<bool>::get(), 0},
246 { OUString("EmptyDbFieldHidesPara"), HANDLE_EMPTY_DB_FIELD_HIDES_PARA, cppu::UnoType<bool>::get(), 0 },
247 { OUString("ContinuousEndnotes"), HANDLE_CONTINUOUS_ENDNOTES, cppu::UnoType<bool>::get(), 0 },
248 { OUString("ProtectBookmarks"), HANDLE_PROTECT_BOOKMARKS, cppu::UnoType<bool>::get(), 0 },
249 { OUString("ProtectFields"), HANDLE_PROTECT_FIELDS, cppu::UnoType<bool>::get(), 0 },
250 { OUString("HeaderSpacingBelowLastPara"), HANDLE_HEADER_SPACING_BELOW_LAST_PARA, cppu::UnoType<bool>::get(), 0 },
251 { OUString("FrameAutowidthWithMorePara"), HANDLE_FRAME_AUTOWIDTH_WITH_MORE_PARA, cppu::UnoType<bool>::get(), 0 },
252 { OUString("GutterAtTop"), HANDLE_GUTTER_AT_TOP, cppu::UnoType<bool>::get(), 0 },
253 { OUString("FootnoteInColumnToPageEnd"), HANDLE_FOOTNOTE_IN_COLUMN_TO_PAGEEND, cppu::UnoType<bool>::get(), 0 },
254 { OUString("ImagePreferredDPI"), HANDLE_IMAGE_PREFERRED_DPI, cppu::UnoType<sal_Int32>::get(), 0 },
255 { OUString("AutoFirstLineIndentDisregardLineSpace"), HANDLE_AUTO_FIRST_LINE_INDENT_DISREGARD_LINE_SPACE, cppu::UnoType<bool>::get(), 0 },
256 { OUString("WordLikeWrapForAsCharFlys"), HANDLE_WORD_LIKE_WRAP_FOR_AS_CHAR_FLYS, cppu::UnoType<bool>::get(), 0 },
257 { OUString("NoNumberingShowFollowBy"), HANDLE_NO_NUMBERING_SHOW_FOLLOWBY, cppu::UnoType<bool>::get(), 0 },
258 { OUString("DropCapPunctuation"), HANDLE_DROP_CAP_PUNCTUATION, cppu::UnoType<bool>::get(), 0 },
259
260/*
261 * As OS said, we don't have a view when we need to set this, so I have to
262 * find another solution before adding them to this property set - MTG
263 { OUString("IsGridVisible"), HANDLE_IS_GRID_VISIBLE, cppu::UnoType<bool>::get(), 0, 0},
264 { OUString("IsSnapToGrid"), HANDLE_IS_SNAP_TO_GRID, cppu::UnoType<bool>::get(), 0, 0},
265 { OUString("IsSynchroniseAxes"), HANDLE_IS_SYNCHRONISE_AXES, cppu::UnoType<bool>::get(), 0, 0},
266 { OUString("HorizontalGridResolution"), HANDLE_HORIZONTAL_GRID_RESOLUTION, cppu::UnoType<sal_Int32>::get(), 0, 0},
267 { OUString("HorizontalGridSubdivision"), HANDLE_HORIZONTAL_GRID_SUBDIVISION, cppu::UnoType<sal_Int16>::get(), 0, 0},
268 { OUString("VerticalGridResolution"), HANDLE_VERTICAL_GRID_RESOLUTION, cppu::UnoType<sal_Int32>::get(), 0, 0},
269 { OUString("VerticalGridSubdivision"), HANDLE_VERTICAL_GRID_SUBDIVISION, cppu::UnoType<sal_Int16>::get(), 0, 0},
270
271 { OUString("ShowParagraphEnd"), HANDLE_SHOW_PARAGRAPH_END, cppu::UnoType<bool>::get(), 0, 0},
272 { OUString("ShowOptionalHyphens"), HANDLE_SHOW_OPTIONAL_HYPHENS, cppu::UnoType<bool>::get(), 0, 0},
273 { OUString("ShowSpaces"), HANDLE_SHOW_SPACES, cppu::UnoType<bool>::get(), 0, 0},
274 { OUString("ShowTabs"), HANDLE_SHOW_TABS, cppu::UnoType<bool>::get(), 0, 0},
275 { OUString("ShowBreaks"), HANDLE_SHOW_BREAKS, cppu::UnoType<bool>::get(), 0, 0},
276 { OUString("ShowHiddenText"), HANDLE_SHOW_HIDDEN_TEXT, cppu::UnoType<bool>::get(), 0, 0},
277 { OUString("ShowHiddenParagraphs"), HANDLE_SHOW_HIDDEN_PARAGRAPHS, cppu::UnoType<bool>::get(), 0, 0},
278
279 { OUString("ShowTextLimitGuide"), HANDLE_SHOW_TEXT_LIMIT_GUIDE, cppu::UnoType<bool>::get(), 0, 0},
280 { OUString("ShowTableLimitGuide"), HANDLE_SHOW_TABLE_LIMIT_GUIDE, cppu::UnoType<bool>::get(), 0, 0},
281 { OUString("ShowSectionLimitGuide"), HANDLE_SHOW_SECTION_LIMIT_GUIDE, cppu::UnoType<bool>::get(), 0, 0},
282 { OUString("ShowGuidesWhileMoving"), HANDLE_SHOW_GUIDES_WHILE_MOVING, cppu::UnoType<bool>::get(), 0, 0},
283*/
284 { OUString(), 0, css::uno::Type(), 0}
285 };
286 return new MasterPropertySetInfo ( aWriterSettingsInfoMap );
287}
288
291 &Application::GetSolarMutex () )
292, mpModel ( pModel )
293, mpDocSh ( nullptr )
294, mpDoc ( nullptr )
295, mpPrinter( nullptr )
296, mbPreferPrinterPapersize( false )
297{
299}
300
302 noexcept
303{
304}
305
307{
308 return ::cppu::queryInterface(rType,
309 // OWeakObject interfaces
310 static_cast<XInterface*>(static_cast<OWeakObject*>(this)),
311 static_cast<XWeak*>(this),
312 // my own interfaces
313 static_cast<XPropertySet*>(this),
314 static_cast<XPropertyState*>(this),
315 static_cast<XMultiPropertySet*>(this),
316 static_cast<XServiceInfo*>(this),
317 static_cast<XTypeProvider*>(this));
318}
320 noexcept
321{
322 OWeakObject::acquire();
323}
325 noexcept
326{
327 OWeakObject::release();
328}
329
330uno::Sequence< uno::Type > SAL_CALL SwXDocumentSettings::getTypes( )
331{
332 static const uno::Sequence< uno::Type > aTypes {
333 // from MasterPropertySet
339 };
340 return aTypes;
341}
342
343uno::Sequence< sal_Int8 > SAL_CALL SwXDocumentSettings::getImplementationId( )
344{
345 return css::uno::Sequence<sal_Int8>();
346}
347
349{
351 if (nullptr == mpDocSh)
352 throw UnknownPropertyException();
353
354 mpDoc = mpDocSh->GetDoc();
355 if (nullptr == mpDoc)
356 throw UnknownPropertyException();
357}
358
360{
361 if (rInfo.mnAttributes & PropertyAttribute::READONLY)
362 throw PropertyVetoException ("Property is read-only: " + rInfo.maName, static_cast < cppu::OWeakObject * > ( nullptr ) );
363
364 switch( rInfo.mnHandle )
365 {
366 case HANDLE_FORBIDDEN_CHARS:
367 break;
368 case HANDLE_LINK_UPDATE_MODE:
369 {
370 sal_Int16 nMode = 0;
371 rValue >>= nMode;
372 switch (nMode)
373 {
374 case NEVER:
375 case MANUAL:
376 case AUTOMATIC:
377 case GLOBALSETTING:
378 break;
379 default:
380 throw IllegalArgumentException();
381 }
383 }
384 break;
385 case HANDLE_FIELD_AUTO_UPDATE:
386 {
387 bool bUpdateField = *o3tl::doAccess<bool>(rValue);
390 nFlag == AUTOUPD_FIELD_AND_CHARTS ?
393 AUTOUPD_OFF );
394 }
395 break;
396 case HANDLE_CHART_AUTO_UPDATE:
397 {
398 bool bUpdateChart = *o3tl::doAccess<bool>(rValue);
401 bUpdateChart ?
404 AUTOUPD_OFF );
405 }
406 break;
407 case HANDLE_ADD_PARA_TABLE_SPACING:
408 {
409 bool bParaSpace = false;
410 rValue >>= bParaSpace;
412 }
413 break;
414 case HANDLE_ADD_PARA_TABLE_SPACING_AT_START:
415 {
416 bool bParaSpacePage = false;
417 rValue >>= bParaSpacePage;
419 }
420 break;
421 case HANDLE_ALIGN_TAB_STOP_POSITION:
422 {
423 bool bAlignTab = *o3tl::doAccess<bool>(rValue);
425 }
426 break;
427 case HANDLE_PRINTER_NAME:
428 {
429 //the printer must be created
430 OUString sPrinterName;
431 if( !(rValue >>= sPrinterName) )
432 throw IllegalArgumentException();
433
434 if( !mpPrinter && !sPrinterName.isEmpty() && mpDocSh->GetCreateMode() != SfxObjectCreateMode::EMBEDDED )
435 {
437 if ( pPrinter->GetName() != sPrinterName )
438 {
439 VclPtrInstance<SfxPrinter> pNewPrinter( pPrinter->GetOptions().Clone(), sPrinterName );
440 assert (! pNewPrinter->isDisposed() );
441 if( pNewPrinter->IsKnown() )
442 {
443 // set printer only once; in _postSetValues
444 mpPrinter = pNewPrinter;
445 }
446 else
447 {
448 pNewPrinter.disposeAndClear();
449 }
450 }
451 }
452
453 }
454 break;
455 case HANDLE_PRINTER_SETUP:
456 {
457 Sequence < sal_Int8 > aSequence;
458 if ( !(rValue >>= aSequence) )
459 throw IllegalArgumentException();
460
461 sal_uInt32 nSize = aSequence.getLength();
462 if( nSize > 0 )
463 {
464 SvMemoryStream aStream (aSequence.getArray(), nSize,
465 StreamMode::READ );
466 aStream.Seek ( STREAM_SEEK_TO_BEGIN );
467 auto pItemSet = std::make_unique<SfxItemSetFixed<
468 SID_PRINTER_NOTFOUND_WARN, SID_PRINTER_NOTFOUND_WARN,
469 SID_PRINTER_CHANGESTODOC, SID_PRINTER_CHANGESTODOC,
470 SID_HTML_MODE, SID_HTML_MODE,
472 VclPtr<SfxPrinter> pPrinter = SfxPrinter::Create ( aStream, std::move(pItemSet) );
473 assert (! pPrinter->isDisposed() );
474 // set printer only once; in _postSetValues
476 mpPrinter = pPrinter;
477 }
478
479 }
480 break;
481 case HANDLE_PRINTER_PAPER:
482 {
483 bool bPreferPrinterPapersize = {}; // spurious -Werror=maybe-uninitialized
484 if(!(rValue >>= bPreferPrinterPapersize))
485 throw IllegalArgumentException();
486 mbPreferPrinterPapersize = bPreferPrinterPapersize;
487 }
488 break;
489 case HANDLE_IS_KERN_ASIAN_PUNCTUATION:
490 {
491 bool bIsKern = *o3tl::doAccess<bool>(rValue);
493 SwEditShell* pEditSh = mpDoc->GetEditShell();
494 if(pEditSh)
495 pEditSh->ChgHyphenation();
496 }
497 break;
498 case HANDLE_CHARACTER_COMPRESSION_TYPE:
499 {
500 sal_Int16 nMode = 0;
501 rValue >>= nMode;
502 switch (static_cast<CharCompressType>(nMode))
503 {
504 case CharCompressType::NONE:
505 case CharCompressType::PunctuationOnly:
506 case CharCompressType::PunctuationAndKana:
507 break;
508 default:
509 throw IllegalArgumentException();
510 }
512 }
513 break;
514 case HANDLE_APPLY_USER_DATA:
515 {
516 mpDocSh->SetUseUserData(*o3tl::doAccess<bool>(rValue));
517 }
518 break;
519 case HANDLE_SAVE_THUMBNAIL:
520 {
521 mpDocSh->SetUseThumbnailSave(*o3tl::doAccess<bool>(rValue));
522 }
523 break;
524 case HANDLE_SAVE_GLOBAL_DOCUMENT_LINKS:
525 {
526 bool bSaveGlobal = *o3tl::doAccess<bool>(rValue);
528 }
529 break;
530 case HANDLE_CURRENT_DATABASE_DATA_SOURCE:
531 {
533 if ( rValue >>= aData.sDataSource )
535 }
536 break;
537 case HANDLE_CURRENT_DATABASE_COMMAND:
538 {
540
541 if ( rValue >>= aData.sCommand )
543
544 SAL_WARN_IF( aData.sDataSource.isEmpty() && !aData.sCommand.isEmpty(), "sw.uno",
545 "\"CurrentDatabaseCommand\" property possibly set before \"CurrentDatabaseDataSource\"" );
546 }
547 break;
548 case HANDLE_CURRENT_DATABASE_COMMAND_TYPE:
549 {
551 if ( rValue >>= aData.nCommandType )
553 SAL_WARN_IF( aData.nCommandType && aData.sDataSource.isEmpty(), "sw.uno",
554 "\"CurrentDatabaseCommandType\" property possibly set before \"CurrentDatabaseDataSource\"" );
555 SAL_WARN_IF( aData.nCommandType && aData.sCommand.isEmpty(), "sw.uno",
556 "\"CurrentDatabaseCommandType\" property possibly set before \"CurrentDatabaseCommand\"" );
557 }
558 break;
559 case HANDLE_EMBEDDED_DATABASE_NAME:
560 {
561#if HAVE_FEATURE_DBCONNECTIVITY && !ENABLE_FUZZERS
562 OUString sEmbeddedName;
563 if (rValue >>= sEmbeddedName)
564 mpDoc->GetDBManager()->setEmbeddedName(sEmbeddedName, *mpDocSh);
565#endif
566 }
567 break;
568 case HANDLE_SAVE_VERSION_ON_CLOSE:
569 {
570 mpDocSh->SetSaveVersionOnClose( *o3tl::doAccess<bool>(rValue) );
571 }
572 break;
573 case HANDLE_UPDATE_FROM_TEMPLATE:
574 {
575 mpDocSh->SetQueryLoadTemplate( *o3tl::doAccess<bool>(rValue) );
576 }
577 break;
578 case HANDLE_PRINTER_INDEPENDENT_LAYOUT:
579 {
580 sal_Int16 nTmp = 0;
581 rValue >>= nTmp;
582
583 bool bUseVirDev = true;
584 bool bHiResVirDev = true;
585 if( nTmp == document::PrinterIndependentLayout::DISABLED )
586 bUseVirDev = false;
587 else if ( nTmp == document::PrinterIndependentLayout::LOW_RESOLUTION )
588 bHiResVirDev = false;
589 else if ( nTmp != document::PrinterIndependentLayout::HIGH_RESOLUTION )
590 throw IllegalArgumentException();
591
592 mpDoc->getIDocumentDeviceAccess().setReferenceDeviceType( bUseVirDev, bHiResVirDev );
593 }
594 break;
595 case HANDLE_IS_LABEL_DOC :
596 {
597 bool bSet = false;
598 if(!(rValue >>= bSet))
599 throw IllegalArgumentException();
601 }
602 break;
603 case HANDLE_IS_ADD_FLY_OFFSET:
604 {
605 bool bTmp = *o3tl::doAccess<bool>(rValue);
607 }
608 break;
609 case HANDLE_IS_ADD_VERTICAL_FLY_OFFSET:
610 {
611 bool bTmp = *o3tl::doAccess<bool>(rValue);
613 }
614 break;
615 case HANDLE_IS_ADD_EXTERNAL_LEADING:
616 {
617 bool bTmp = *o3tl::doAccess<bool>(rValue);
619 }
620 break;
621 case HANDLE_OLD_NUMBERING:
622 {
623 bool bTmp = *o3tl::doAccess<bool>(rValue);
625 }
626 break;
627 case HANDLE_OUTLINELEVEL_YIELDS_NUMBERING:
628 {
629 // ignore - this is a dead property
630 }
631 break;
632 case HANDLE_ALLOW_PRINTJOB_CANCEL:
633 {
634 bool bState = false;
635 if (!(rValue >>= bState))
636 throw IllegalArgumentException();
638 }
639 break;
640 case HANDLE_USE_FORMER_LINE_SPACING:
641 {
642 bool bTmp = *o3tl::doAccess<bool>(rValue);
644 }
645 break;
646 case HANDLE_ADD_PARA_SPACING_TO_TABLE_CELLS:
647 {
648 bool bTmp = *o3tl::doAccess<bool>(rValue);
650 }
651 break;
652 case HANDLE_ADD_PARA_LINE_SPACING_TO_TABLE_CELLS:
653 {
654 bool bTmp = *o3tl::doAccess<bool>(rValue);
656 }
657 break;
658 case HANDLE_USE_FORMER_OBJECT_POSITIONING:
659 {
660 bool bTmp = *o3tl::doAccess<bool>(rValue);
662 }
663 break;
664 case HANDLE_USE_FORMER_TEXT_WRAPPING:
665 {
666 bool bTmp = *o3tl::doAccess<bool>(rValue);
668 }
669 break;
670 case HANDLE_CHANGES_PASSWORD:
671 {
672 Sequence <sal_Int8> aNew;
673 if(rValue >>= aNew)
674 {
676 if(aNew.hasElements())
677 {
681 }
682 }
683 }
684 break;
685 case HANDLE_CONSIDER_WRAP_ON_OBJPOS:
686 {
687 bool bTmp = *o3tl::doAccess<bool>(rValue);
689 }
690 break;
691 case HANDLE_IGNORE_FIRST_LINE_INDENT_IN_NUMBERING:
692 {
693 bool bTmp = *o3tl::doAccess<bool>(rValue);
695 }
696 break;
697 case HANDLE_DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK:
698 {
699 bool bTmp = *o3tl::doAccess<bool>(rValue);
701 }
702 break;
703 case HANDLE_DO_NOT_RESET_PARA_ATTRS_FOR_NUM_FONT:
704 {
705 bool bTmp = *o3tl::doAccess<bool>(rValue);
707 }
708 break;
709 case HANDLE_TABLE_ROW_KEEP:
710 {
711 bool bTmp = *o3tl::doAccess<bool>(rValue);
713 }
714 break;
715 case HANDLE_IGNORE_TABS_AND_BLANKS_FOR_LINE_CALCULATION:
716 {
717 bool bTmp = *o3tl::doAccess<bool>(rValue);
719 }
720 break;
721 case HANDLE_LOAD_READONLY:
722 {
723 mpDocSh->SetLoadReadonly( *o3tl::doAccess<bool>(rValue) );
724 }
725 break;
726 case HANDLE_DO_NOT_CAPTURE_DRAW_OBJS_ON_PAGE:
727 {
728 bool bTmp = *o3tl::doAccess<bool>(rValue);
730 }
731 break;
732 case HANDLE_CLIP_AS_CHARACTER_ANCHORED_WRITER_FLY_FRAMES:
733 {
734 bool bTmp = *o3tl::doAccess<bool>(rValue);
736 }
737 break;
738 case HANDLE_UNIX_FORCE_ZERO_EXT_LEADING:
739 {
740 bool bTmp = *o3tl::doAccess<bool>(rValue);
742 }
743 break;
744 case HANDLE_USE_OLD_PRINTER_METRICS:
745 // ignore - this is a dead property
746 break;
747 case HANDLE_TABS_RELATIVE_TO_INDENT:
748 {
749 bool bTmp = *o3tl::doAccess<bool>(rValue);
751 }
752 break;
753 case HANDLE_RSID:
754 {
755 sal_uInt32 nTmp = 0;
756 rValue >>= nTmp;
757 mpDoc->setRsid( nTmp );
758 }
759 break;
760 case HANDLE_RSID_ROOT:
761 {
762 sal_uInt32 nTmp = 0;
763 rValue >>= nTmp;
764 mpDoc->setRsidRoot( nTmp );
765 }
766 break;
767 case HANDLE_PROTECT_FORM:
768 {
769 bool bTmp = *o3tl::doAccess<bool>(rValue);
771 }
772 break;
773 case HANDLE_MS_WORD_COMP_TRAILING_BLANKS:
774 {
775 bool bTmp = *o3tl::doAccess<bool>(rValue);
777 }
778 break;
779 case HANDLE_MS_WORD_COMP_MIN_LINE_HEIGHT_BY_FLY:
780 {
781 bool bTmp = *o3tl::doAccess<bool>(rValue);
783 }
784 break;
785 case HANDLE_TAB_AT_LEFT_INDENT_FOR_PARA_IN_LIST:
786 {
787 bool bTmp = *o3tl::doAccess<bool>(rValue);
789 }
790 break;
791 case HANDLE_MODIFYPASSWORDINFO:
792 {
793 uno::Sequence< beans::PropertyValue > aInfo;
794 if ( !( rValue >>= aInfo ) )
795 throw lang::IllegalArgumentException(
796 "Value of type Sequence<PropertyValue> expected!",
797 uno::Reference< uno::XInterface >(),
798 2 );
799
800 if ( !mpDocSh->SetModifyPasswordInfo( aInfo ) )
801 throw beans::PropertyVetoException(
802 "The hash is not allowed to be changed now!",
803 uno::Reference< uno::XInterface >() );
804 }
805 break;
806 case HANDLE_MATH_BASELINE_ALIGNMENT:
807 {
808 bool bTmp = *o3tl::doAccess<bool>(rValue);
810 }
811 break;
812 case HANDLE_INVERT_BORDER_SPACING:
813 {
814 bool bTmp = *o3tl::doAccess<bool>(rValue);
816 }
817 break;
818 case HANDLE_COLLAPSE_EMPTY_CELL_PARA:
819 {
820 bool bTmp = *o3tl::doAccess<bool>(rValue);
822 }
823 break;
824 case HANDLE_SMALL_CAPS_PERCENTAGE_66:
825 {
826 bool bTmp = *o3tl::doAccess<bool>(rValue);
828 }
829 break;
830 case HANDLE_TAB_OVERFLOW:
831 {
832 bool bTmp = *o3tl::doAccess<bool>(rValue);
834 }
835 break;
836 case HANDLE_UNBREAKABLE_NUMBERINGS:
837 {
838 bool bTmp = *o3tl::doAccess<bool>(rValue);
840 }
841 break;
842 case HANDLE_STYLES_NODEFAULT:
843 {
844 bool bTmp = *o3tl::doAccess<bool>(rValue);
846 }
847 break;
848 case HANDLE_FLOATTABLE_NOMARGINS:
849 {
850 bool bTmp = *o3tl::doAccess<bool>(rValue);
852 }
853 break;
854 case HANDLE_CLIPPED_PICTURES:
855 {
856 bool bTmp = *o3tl::doAccess<bool>(rValue);
858 }
859 break;
860 case HANDLE_BACKGROUND_PARA_OVER_DRAWINGS:
861 {
862 bool bTmp = *o3tl::doAccess<bool>(rValue);
864 }
865 break;
866 case HANDLE_EMBED_FONTS:
867 {
868 bool bTmp = *o3tl::doAccess<bool>(rValue);
870 }
871 break;
872 case HANDLE_EMBED_USED_FONTS:
873 {
874 bool bTmp = *o3tl::doAccess<bool>(rValue);
876 }
877 break;
878 case HANDLE_EMBED_LATIN_SCRIPT_FONTS:
879 {
880 bool bTmp = *o3tl::doAccess<bool>(rValue);
882 }
883 break;
884 case HANDLE_EMBED_ASIAN_SCRIPT_FONTS:
885 {
886 bool bTmp = *o3tl::doAccess<bool>(rValue);
888 }
889 break;
890 case HANDLE_EMBED_COMPLEX_SCRIPT_FONTS:
891 {
892 bool bTmp = *o3tl::doAccess<bool>(rValue);
894 }
895 break;
896 case HANDLE_EMBED_SYSTEM_FONTS:
897 {
898 bool bTmp = *o3tl::doAccess<bool>(rValue);
900 }
901 break;
902 case HANDLE_TAB_OVER_MARGIN:
903 {
904 bool bTmp = *o3tl::doAccess<bool>(rValue);
906 }
907 break;
908 case HANDLE_TAB_OVER_SPACING:
909 {
910 bool bTmp = *o3tl::doAccess<bool>(rValue);
912 }
913 break;
914 case HANDLE_TREAT_SINGLE_COLUMN_BREAK_AS_PAGE_BREAK:
915 {
916 bool bTmp = *o3tl::doAccess<bool>(rValue);
918 }
919 break;
920 case HANDLE_SURROUND_TEXT_WRAP_SMALL:
921 {
922 bool bTmp = *o3tl::doAccess<bool>(rValue);
924 }
925 break;
926 case HANDLE_APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING:
927 {
928 bool bTmp = *o3tl::doAccess<bool>(rValue);
930 }
931 break;
932 case HANDLE_PROP_LINE_SPACING_SHRINKS_FIRST_LINE:
933 {
934 bool bTmp;
935 if (rValue >>= bTmp)
936 {
939 }
940 }
941 break;
942 case HANDLE_SUBTRACT_FLYS:
943 {
944 bool bTmp;
945 if (rValue >>= bTmp)
946 {
949 }
950 }
951 break;
952 case HANDLE_DISABLE_OFF_PAGE_POSITIONING:
953 {
954 bool bTmp;
955 if (rValue >>= bTmp)
956 {
959 }
960 }
961 break;
962 case HANDLE_EMPTY_DB_FIELD_HIDES_PARA:
963 {
964 bool bTmp;
965 if (rValue >>= bTmp)
966 {
968 bTmp);
969 }
970 }
971 break;
972 case HANDLE_CONTINUOUS_ENDNOTES:
973 {
974 bool bTmp;
975 if (rValue >>= bTmp)
976 {
978 bTmp);
979 }
980 }
981 break;
982 case HANDLE_PROTECT_BOOKMARKS:
983 {
984 bool bTmp;
985 if (rValue >>= bTmp)
986 {
988 bTmp);
989 }
990 }
991 break;
992 case HANDLE_PROTECT_FIELDS:
993 {
994 bool bTmp;
995 if (rValue >>= bTmp)
996 {
998 bTmp);
999 }
1000 }
1001 break;
1002 case HANDLE_HEADER_SPACING_BELOW_LAST_PARA:
1003 {
1004 bool bTmp;
1005 if (rValue >>= bTmp)
1006 {
1009 }
1010 }
1011 break;
1012 case HANDLE_FRAME_AUTOWIDTH_WITH_MORE_PARA:
1013 {
1014 bool bTmp;
1015 if (rValue >>= bTmp)
1016 {
1019 }
1020 }
1021 break;
1022 case HANDLE_GUTTER_AT_TOP:
1023 {
1024 bool bTmp;
1025 if (rValue >>= bTmp)
1026 {
1028 }
1029 }
1030 break;
1031 case HANDLE_FOOTNOTE_IN_COLUMN_TO_PAGEEND:
1032 {
1033 bool bTmp;
1034 if (rValue >>= bTmp)
1035 {
1038 }
1039 }
1040 break;
1041 case HANDLE_IMAGE_PREFERRED_DPI:
1042 {
1043 sal_uInt32 nValue = 0;
1044 if (rValue >>= nValue)
1045 {
1047 }
1048 }
1049 break;
1050 case HANDLE_AUTO_FIRST_LINE_INDENT_DISREGARD_LINE_SPACE:
1051 {
1052 bool bTmp;
1053 if (rValue >>= bTmp)
1054 {
1057 }
1058 }
1059 break;
1060 case HANDLE_WORD_LIKE_WRAP_FOR_AS_CHAR_FLYS:
1061 {
1062 bool bTmp;
1063 if (rValue >>= bTmp)
1066 }
1067 break;
1068 case HANDLE_NO_NUMBERING_SHOW_FOLLOWBY:
1069 {
1070 bool bTmp;
1071 if (rValue >>= bTmp)
1074 }
1075 break;
1076 case HANDLE_DROP_CAP_PUNCTUATION:
1077 {
1078 bool bTmp;
1079 if (rValue >>= bTmp)
1082 }
1083 break;
1084 default:
1085 throw UnknownPropertyException(OUString::number(rInfo.mnHandle));
1086 }
1087}
1088
1090{
1091 // set printer only once, namely here!
1092 if( mpPrinter != nullptr )
1093 {
1094 // #i86352# the printer is also used as container for options by sfx
1095 // when setting a printer it should have decent default options
1096 SfxItemSet aOptions( mpPrinter->GetOptions() );
1098 SwAddPrinterItem aAddPrinterItem (aPrtData);
1099 aOptions.Put(aAddPrinterItem);
1100 mpPrinter->SetOptions( aOptions );
1101 mpPrinter->SetPrinterSettingsPreferred( mbPreferPrinterPapersize );
1102
1104 }
1105
1106 mpPrinter = nullptr;
1107 mpDocSh = nullptr;
1108 mpDoc = nullptr;
1109}
1110
1112{
1114 if (nullptr == mpDocSh)
1115 throw UnknownPropertyException();
1116 mpDoc = mpDocSh->GetDoc();
1117 if (nullptr == mpDoc)
1118 throw UnknownPropertyException();
1119}
1120
1122{
1123 switch( rInfo.mnHandle )
1124 {
1125 case HANDLE_FORBIDDEN_CHARS:
1126 {
1127 rValue <<= Reference<XForbiddenCharacters>(mpModel->GetPropertyHelper());
1128 }
1129 break;
1130 case HANDLE_LINK_UPDATE_MODE:
1131 {
1132 rValue <<= static_cast < sal_Int16 > ( mpDoc->getIDocumentSettingAccess().getLinkUpdateMode(true) );
1133 }
1134 break;
1135 case HANDLE_FIELD_AUTO_UPDATE:
1136 {
1138 rValue <<= nFlags == AUTOUPD_FIELD_ONLY || nFlags == AUTOUPD_FIELD_AND_CHARTS;
1139 }
1140 break;
1141 case HANDLE_CHART_AUTO_UPDATE:
1142 {
1144 rValue <<= nFlags == AUTOUPD_FIELD_AND_CHARTS;
1145 }
1146 break;
1147 case HANDLE_ADD_PARA_TABLE_SPACING:
1148 {
1150 }
1151 break;
1152 case HANDLE_ADD_PARA_TABLE_SPACING_AT_START:
1153 {
1155 }
1156 break;
1157 case HANDLE_ALIGN_TAB_STOP_POSITION:
1158 {
1160 }
1161 break;
1162 case HANDLE_PRINTER_NAME:
1163 {
1164 SfxPrinter *pPrinter = mpDoc->getIDocumentDeviceAccess().getPrinter( false );
1165 rValue <<= pPrinter ? pPrinter->GetName() : OUString();
1166 }
1167 break;
1168 case HANDLE_PRINTER_SETUP:
1169 {
1170 SfxPrinter *pPrinter = mpDoc->getIDocumentDeviceAccess().getPrinter( false );
1171 if (pPrinter)
1172 {
1173 SvMemoryStream aStream;
1174 pPrinter->Store( aStream );
1175 sal_uInt32 nSize = aStream.TellEnd();
1176 aStream.Seek ( STREAM_SEEK_TO_BEGIN );
1177 Sequence < sal_Int8 > aSequence( nSize );
1178 aStream.ReadBytes(aSequence.getArray(), nSize);
1179 rValue <<= aSequence;
1180 }
1181 else
1182 {
1183 Sequence < sal_Int8 > aSequence ( 0 );
1184 rValue <<= aSequence;
1185 }
1186 }
1187 break;
1188 case HANDLE_PRINTER_PAPER:
1189 {
1190 SfxPrinter *pTempPrinter = mpDoc->getIDocumentDeviceAccess().getPrinter( false );
1191 rValue <<= pTempPrinter && pTempPrinter->GetPrinterSettingsPreferred();
1192 }
1193 break;
1194 case HANDLE_IS_KERN_ASIAN_PUNCTUATION:
1195 {
1197 }
1198 break;
1199 case HANDLE_APPLY_USER_DATA:
1200 {
1201 rValue <<= mpDocSh->IsUseUserData();
1202 }
1203 break;
1204 case HANDLE_SAVE_THUMBNAIL:
1205 {
1206 rValue <<= mpDocSh->IsUseThumbnailSave();
1207 }
1208 break;
1209 case HANDLE_CHARACTER_COMPRESSION_TYPE:
1210 {
1211 rValue <<= static_cast < sal_Int16 > (mpDoc->getIDocumentSettingAccess().getCharacterCompressionType());
1212 }
1213 break;
1214 case HANDLE_SAVE_GLOBAL_DOCUMENT_LINKS:
1215 {
1217 }
1218 break;
1219 case HANDLE_CURRENT_DATABASE_DATA_SOURCE:
1220 {
1221 const SwDBData& rData = mpDoc->GetDBData();
1222 rValue <<= rData.sDataSource;
1223 }
1224 break;
1225 case HANDLE_CURRENT_DATABASE_COMMAND:
1226 {
1227 const SwDBData& rData = mpDoc->GetDBData();
1228 rValue <<= rData.sCommand;
1229 }
1230 break;
1231 case HANDLE_CURRENT_DATABASE_COMMAND_TYPE:
1232 {
1233 const SwDBData& rData = mpDoc->GetDBData();
1234 rValue <<= rData.nCommandType;
1235 }
1236 break;
1237 case HANDLE_EMBEDDED_DATABASE_NAME:
1238 {
1239#if HAVE_FEATURE_DBCONNECTIVITY && !ENABLE_FUZZERS
1240 rValue <<= mpDoc->GetDBManager()->getEmbeddedName();
1241#else
1242 rValue = uno::Any();
1243#endif
1244 }
1245 break;
1246 case HANDLE_SAVE_VERSION_ON_CLOSE:
1247 {
1248 rValue <<= mpDocSh->IsSaveVersionOnClose();
1249 }
1250 break;
1251 case HANDLE_UPDATE_FROM_TEMPLATE:
1252 {
1253 rValue <<= mpDocSh->IsQueryLoadTemplate();
1254 }
1255 break;
1256 case HANDLE_PRINTER_INDEPENDENT_LAYOUT:
1257 {
1258 // returns short (see css.document.PrinterIndependentLayout)
1261 document::PrinterIndependentLayout::HIGH_RESOLUTION :
1262 document::PrinterIndependentLayout::LOW_RESOLUTION ) :
1263 document::PrinterIndependentLayout::DISABLED;
1264 rValue <<= nVirDevType;
1265 }
1266 break;
1267 case HANDLE_IS_LABEL_DOC:
1268 {
1270 rValue <<= bLabel;
1271 }
1272 break;
1273 case HANDLE_IS_ADD_FLY_OFFSET:
1274 {
1276 }
1277 break;
1278 case HANDLE_IS_ADD_VERTICAL_FLY_OFFSET:
1279 {
1281 }
1282 break;
1283 case HANDLE_IS_ADD_EXTERNAL_LEADING:
1284 {
1286 }
1287 break;
1288 case HANDLE_OLD_NUMBERING:
1289 {
1291 }
1292 break;
1293 case HANDLE_OUTLINELEVEL_YIELDS_NUMBERING:
1294 {
1295 rValue <<= false;
1296 }
1297 break;
1298 case HANDLE_ALLOW_PRINTJOB_CANCEL:
1299 {
1300 rValue <<= mpDocSh->Stamp_GetPrintCancelState();
1301 }
1302 break;
1303 case HANDLE_USE_FORMER_LINE_SPACING:
1304 {
1306 }
1307 break;
1308 case HANDLE_ADD_PARA_SPACING_TO_TABLE_CELLS:
1309 {
1311 }
1312 break;
1313 case HANDLE_ADD_PARA_LINE_SPACING_TO_TABLE_CELLS:
1314 {
1316 }
1317 break;
1318 case HANDLE_USE_FORMER_OBJECT_POSITIONING:
1319 {
1321 }
1322 break;
1323 case HANDLE_USE_FORMER_TEXT_WRAPPING:
1324 {
1326 }
1327 break;
1328 case HANDLE_CHANGES_PASSWORD:
1329 {
1331 }
1332 break;
1333 case HANDLE_CONSIDER_WRAP_ON_OBJPOS:
1334 {
1336 }
1337 break;
1338 case HANDLE_IGNORE_FIRST_LINE_INDENT_IN_NUMBERING:
1339 {
1341 }
1342 break;
1343 case HANDLE_DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK:
1344 {
1346 }
1347 break;
1348 case HANDLE_DO_NOT_RESET_PARA_ATTRS_FOR_NUM_FONT:
1349 {
1351 }
1352 break;
1353 case HANDLE_TABLE_ROW_KEEP :
1354 {
1356 }
1357 break;
1358 case HANDLE_IGNORE_TABS_AND_BLANKS_FOR_LINE_CALCULATION:
1359 {
1361 }
1362 break;
1363 case HANDLE_LOAD_READONLY:
1364 {
1365 rValue <<= mpDocSh->IsLoadReadonly();
1366 }
1367 break;
1368 case HANDLE_DO_NOT_CAPTURE_DRAW_OBJS_ON_PAGE:
1369 {
1371 }
1372 break;
1373 case HANDLE_CLIP_AS_CHARACTER_ANCHORED_WRITER_FLY_FRAMES:
1374 {
1376 }
1377 break;
1378 case HANDLE_UNIX_FORCE_ZERO_EXT_LEADING:
1379 {
1381 }
1382 break;
1383 case HANDLE_USE_OLD_PRINTER_METRICS:
1384 {
1385 rValue <<= false;
1386 }
1387 break;
1388 case HANDLE_TABS_RELATIVE_TO_INDENT:
1389 {
1391 }
1392 break;
1393 case HANDLE_RSID:
1394 {
1395 rValue <<= static_cast < sal_Int32 > ( mpDoc->getRsid() );
1396 }
1397 break;
1398 case HANDLE_RSID_ROOT:
1399 {
1400 rValue <<= static_cast < sal_Int32 > ( mpDoc->getRsidRoot() );
1401 }
1402 break;
1403 case HANDLE_PROTECT_FORM:
1404 {
1406 }
1407 break;
1408 case HANDLE_MS_WORD_COMP_TRAILING_BLANKS:
1409 {
1411 }
1412 break;
1413 case HANDLE_MS_WORD_COMP_MIN_LINE_HEIGHT_BY_FLY:
1414 {
1416 }
1417 break;
1418 case HANDLE_TAB_AT_LEFT_INDENT_FOR_PARA_IN_LIST:
1419 {
1421 }
1422 break;
1423 case HANDLE_MODIFYPASSWORDINFO:
1424 {
1425 rValue <<= mpDocSh->GetModifyPasswordInfo();
1426 }
1427 break;
1428 case HANDLE_MATH_BASELINE_ALIGNMENT:
1429 {
1431 }
1432 break;
1433 case HANDLE_INVERT_BORDER_SPACING:
1434 {
1436 }
1437 break;
1438 case HANDLE_COLLAPSE_EMPTY_CELL_PARA:
1439 {
1441 }
1442 break;
1443 case HANDLE_SMALL_CAPS_PERCENTAGE_66:
1444 {
1446 }
1447 break;
1448 case HANDLE_TAB_OVERFLOW:
1449 {
1451 }
1452 break;
1453 case HANDLE_UNBREAKABLE_NUMBERINGS:
1454 {
1456 }
1457 break;
1458 case HANDLE_STYLES_NODEFAULT:
1459 {
1461 }
1462 break;
1463 case HANDLE_FLOATTABLE_NOMARGINS:
1464 {
1466 }
1467 break;
1468 case HANDLE_CLIPPED_PICTURES:
1469 {
1471 }
1472 break;
1473 case HANDLE_BACKGROUND_PARA_OVER_DRAWINGS:
1474 {
1476 }
1477 break;
1478 case HANDLE_EMBED_FONTS:
1479 {
1481 }
1482 break;
1483 case HANDLE_EMBED_USED_FONTS:
1484 {
1486 }
1487 break;
1488 case HANDLE_EMBED_LATIN_SCRIPT_FONTS:
1489 {
1491 }
1492 break;
1493 case HANDLE_EMBED_ASIAN_SCRIPT_FONTS:
1494 {
1496 }
1497 break;
1498 case HANDLE_EMBED_COMPLEX_SCRIPT_FONTS:
1499 {
1501 }
1502 break;
1503 case HANDLE_EMBED_SYSTEM_FONTS:
1504 {
1506 }
1507 break;
1508 case HANDLE_TAB_OVER_MARGIN:
1509 {
1511 }
1512 break;
1513 case HANDLE_TAB_OVER_SPACING:
1514 {
1516 }
1517 break;
1518 case HANDLE_TREAT_SINGLE_COLUMN_BREAK_AS_PAGE_BREAK:
1519 {
1521 }
1522 break;
1523 case HANDLE_SURROUND_TEXT_WRAP_SMALL:
1524 {
1526 }
1527 break;
1528 case HANDLE_APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING:
1529 {
1531 }
1532 break;
1533 case HANDLE_PROP_LINE_SPACING_SHRINKS_FIRST_LINE:
1534 {
1536 }
1537 break;
1538 case HANDLE_SUBTRACT_FLYS:
1539 {
1541 }
1542 break;
1543 case HANDLE_DISABLE_OFF_PAGE_POSITIONING:
1544 {
1546 }
1547 break;
1548 case HANDLE_EMPTY_DB_FIELD_HIDES_PARA:
1549 {
1550 rValue <<= mpDoc->getIDocumentSettingAccess().get(
1552 }
1553 break;
1554 case HANDLE_CONTINUOUS_ENDNOTES:
1555 {
1556 rValue
1558 }
1559 break;
1560 case HANDLE_PROTECT_BOOKMARKS:
1561 {
1562 rValue <<= mpDoc->getIDocumentSettingAccess().get(
1564 }
1565 break;
1566 case HANDLE_PROTECT_FIELDS:
1567 {
1568 rValue <<= mpDoc->getIDocumentSettingAccess().get(
1570 }
1571 break;
1572 case HANDLE_HEADER_SPACING_BELOW_LAST_PARA:
1573 {
1574 rValue <<= mpDoc->getIDocumentSettingAccess().get(
1576 }
1577 break;
1578 case HANDLE_FRAME_AUTOWIDTH_WITH_MORE_PARA:
1579 {
1580 rValue <<= mpDoc->getIDocumentSettingAccess().get(
1582 }
1583 break;
1584 case HANDLE_GUTTER_AT_TOP:
1585 {
1587 }
1588 break;
1589 case HANDLE_FOOTNOTE_IN_COLUMN_TO_PAGEEND:
1590 {
1591 rValue <<= mpDoc->getIDocumentSettingAccess().get(
1593 }
1594 break;
1595 case HANDLE_IMAGE_PREFERRED_DPI:
1596 {
1598 }
1599 break;
1600 case HANDLE_AUTO_FIRST_LINE_INDENT_DISREGARD_LINE_SPACE:
1601 {
1602 rValue <<= mpDoc->getIDocumentSettingAccess().get(
1604 }
1605 break;
1606 case HANDLE_WORD_LIKE_WRAP_FOR_AS_CHAR_FLYS:
1607 {
1608 rValue <<= mpDoc->getIDocumentSettingAccess().get(
1610 }
1611 break;
1612 case HANDLE_NO_NUMBERING_SHOW_FOLLOWBY:
1613 {
1614 rValue <<= mpDoc->getIDocumentSettingAccess().get(
1616 }
1617 break;
1618 case HANDLE_DROP_CAP_PUNCTUATION:
1619 {
1620 rValue <<= mpDoc->getIDocumentSettingAccess().get(
1622 }
1623 break;
1624 default:
1625 throw UnknownPropertyException(OUString::number(rInfo.mnHandle));
1626 }
1627}
1628
1630{
1631 mpDocSh = nullptr;
1632 mpDoc = nullptr;
1633}
1634
1635// XServiceInfo
1637{
1638 return "SwXDocumentSettings";
1639}
1640
1641sal_Bool SAL_CALL SwXDocumentSettings::supportsService( const OUString& ServiceName )
1642{
1643 return cppu::supportsService(this, ServiceName);
1644}
1645
1647{
1648 return { "com.sun.star.document.Settings", "com.sun.star.text.DocumentSettings", "com.sun.star.text.PrintSettings" };
1649}
1650
1651/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
@ On
RedlineFlags on.
@ CONSIDER_WRAP_ON_OBJECT_POSITION
@ CLIP_AS_CHARACTER_ANCHORED_WRITER_FLY_FRAME
@ TREAT_SINGLE_COLUMN_BREAK_AS_PAGE_BREAK
@ DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK
@ IGNORE_FIRST_LINE_INDENT_IN_NUMBERING
@ APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING
@ AUTO_FIRST_LINE_INDENT_DISREGARD_LINE_SPACE
@ TAB_AT_LEFT_INDENT_FOR_PARA_IN_LIST
@ MS_WORD_COMP_MIN_LINE_HEIGHT_BY_FLY
@ IGNORE_TABS_AND_BLANKS_FOR_LINE_CALCULATION
@ DO_NOT_CAPTURE_DRAW_OBJS_ON_PAGE
@ PROP_LINE_SPACING_SHRINKS_FIRST_LINE
@ DO_NOT_RESET_PARA_ATTRS_FOR_NUM_FONT
@ ADD_PARA_LINE_SPACING_TO_TABLE_CELLS
static rtl::Reference< MasterPropertySetInfo > lcl_createSettingsInfo()
CharCompressType
virtual SfxPrinter * getPrinter(bool bCreate) const =0
Return the printer set at the document.
virtual void setReferenceDeviceType(bool bNewVirtual, bool bNewHiRes)=0
Sets the type of the reference device used for formatting the document.
virtual void setPrinter(SfxPrinter *pP, bool bDeleteOld, bool bCallPrtDataChanged)=0
Set the printer at the document.
virtual const SwPrintData & getPrintData() const =0
Returns the PrintData.
virtual void SetRedlinePassword(const css::uno::Sequence< sal_Int8 > &rNewPassword)=0
virtual void SetRedlineFlags(RedlineFlags eMode)=0
Set a new redline mode.
virtual RedlineFlags GetRedlineFlags() const =0
Query the currently set redline mode.
virtual const css::uno::Sequence< sal_Int8 > & GetRedlinePassword() const =0
virtual sal_uInt16 getLinkUpdateMode(bool bGlobalSettings) const =0
Get the current link update mode.
virtual void setFieldUpdateFlags(SwFieldUpdateFlags nMode)=0
Set the current field update mode.
virtual void setImagePreferredDPI(sal_Int32 nValue)=0
virtual bool get(DocumentSettingId id) const =0
Return the specified document setting.
virtual void setLinkUpdateMode(sal_uInt16 nMode)=0
Set the current link update mode.
virtual void setCharacterCompressionType(CharCompressType nType)=0
Set the character compression type for Asian characters.
virtual void set(DocumentSettingId id, bool value)=0
Set the specified document setting.
virtual SwFieldUpdateFlags getFieldUpdateFlags(bool bGlobalSettings) const =0
Get the current field update mode.
virtual CharCompressType getCharacterCompressionType() const =0
Get the character compression type for Asian characters.
virtual sal_Int32 getImagePreferredDPI()=0
virtual std::unique_ptr< SfxItemSet > Clone(bool bItems=true, SfxItemPool *pToPool=nullptr) const
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
bool SetModifyPasswordInfo(const css::uno::Sequence< css::beans::PropertyValue > &aInfo)
bool IsLoadReadonly() const
bool IsUseUserData() const
void SetQueryLoadTemplate(bool b)
void SetSaveVersionOnClose(bool bSet)
void SetUseThumbnailSave(bool _bNew)
void SetUseUserData(bool bNew)
bool IsUseThumbnailSave() const
bool IsSaveVersionOnClose() const
void SetLoadReadonly(bool _bReadonly)
SfxObjectCreateMode GetCreateMode() const
bool Stamp_GetPrintCancelState() const
const css::uno::Sequence< css::beans::PropertyValue > & GetModifyPasswordInfo() const
bool IsQueryLoadTemplate() const
void Stamp_SetPrintCancelState(bool bState)
void Store(SvStream &rStream) const
static VclPtr< SfxPrinter > Create(SvStream &rStream, std::unique_ptr< SfxItemSet > &&pOptions)
const SfxItemSet & GetOptions() const
virtual sal_uInt64 TellEnd() override
sal_uInt64 Seek(sal_uInt64 nPos)
std::size_t ReadBytes(void *pData, std::size_t nSize)
const OUString & getEmbeddedName() const
Definition: dbmgr.cxx:3169
void setEmbeddedName(const OUString &rEmbeddedName, SwDocShell &rDocShell)
Definition: dbmgr.cxx:3148
SwDoc * GetDoc()
returns Doc. But be careful!
Definition: docsh.hxx:204
SwDBData const & GetDBData()
Definition: docfld.cxx:383
IDocumentDeviceAccess const & getIDocumentDeviceAccess() const
Definition: doc.cxx:244
SwDBManager * GetDBManager() const
Definition: doc.hxx:678
sal_uInt32 getRsid() const
Definition: doc.cxx:202
sal_uInt32 getRsidRoot() const
Definition: doc.cxx:222
IDocumentRedlineAccess const & getIDocumentRedlineAccess() const
Definition: doc.cxx:341
void setRsidRoot(sal_uInt32 nVal)
Definition: doc.cxx:227
SwEditShell const * GetEditShell() const
Definition: doccorr.cxx:329
IDocumentSettingAccess const & getIDocumentSettingAccess() const
Definition: doc.cxx:182
void setRsid(sal_uInt32 nVal)
Definition: doc.cxx:207
const SwAttrPool & GetAttrPool() const
Definition: doc.hxx:1326
void ChgDBData(const SwDBData &rNewData)
Definition: doc.cxx:459
void ChgHyphenation()
Definition: viewsh.hxx:216
virtual void _preGetValues() override
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() override
virtual ~SwXDocumentSettings() noexcept override
virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes() override
virtual void _setSingleValue(const comphelper::PropertyInfo &rInfo, const css::uno::Any &rValue) override
virtual css::uno::Any SAL_CALL queryInterface(const css::uno::Type &aType) override
virtual void SAL_CALL acquire() noexcept override
SwXTextDocument * mpModel
virtual void _postGetValues() override
virtual void _postSetValues() override
virtual void _getSingleValue(const comphelper::PropertyInfo &rInfo, css::uno::Any &rValue) override
VclPtr< SfxPrinter > mpPrinter
the printer should be set only once; since there are several printer-related properties,...
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
SwXDocumentSettings(SwXTextDocument *pModel)
virtual void _preSetValues() override
virtual OUString SAL_CALL getImplementationName() override
virtual sal_Bool SAL_CALL supportsService(const OUString &ServiceName) override
virtual void SAL_CALL release() noexcept override
SwXDocumentPropertyHelper * GetPropertyHelper()
Definition: unotxdoc.cxx:406
SwDocShell * GetDocShell()
Definition: unotxdoc.hxx:478
void disposeAndClear()
void registerSlave(ChainablePropertySet *pNewSet) noexcept
css::uno::Type const & get()
#define FN_PARAM_ADDPRINTER
Definition: cmdid.h:786
SwFieldUpdateFlags
Definition: fldupde.hxx:23
@ AUTOUPD_FIELD_ONLY
Definition: fldupde.hxx:25
@ AUTOUPD_OFF
Definition: fldupde.hxx:24
@ AUTOUPD_FIELD_AND_CHARTS
Definition: fldupde.hxx:26
sal_Int16 nValue
Mode eMode
@ NEVER
Definition: linkenum.hxx:24
@ MANUAL
Definition: linkenum.hxx:25
@ GLOBALSETTING
Definition: linkenum.hxx:27
#define SAL_WARN_IF(condition, area, stream)
constexpr OUStringLiteral aData
Definition: ww8scan.hxx:48
class SAL_NO_VTABLE XPropertySet
Type
bool CPPUHELPER_DLLPUBLIC supportsService(css::lang::XServiceInfo *implementation, rtl::OUString const &name)
AUTOMATIC
css::uno::Reference< css::linguistic2::XProofreadingIterator > get(css::uno::Reference< css::uno::XComponentContext > const &context)
#define STREAM_SEEK_TO_BEGIN
sal_Int32 nCommandType
Definition: swdbdata.hxx:32
OUString sDataSource
Definition: swdbdata.hxx:30
OUString sCommand
Definition: swdbdata.hxx:31
unsigned char sal_Bool
const SvXMLTokenMapEntry aTypes[]