LibreOffice Module sw (master) 1
vbaparagraphformat.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 */
20#include <utility>
22#include <basic/sberrors.hxx>
23#include <com/sun/star/style/LineSpacingMode.hpp>
24#include <ooo/vba/word/WdLineSpacing.hpp>
25#include <ooo/vba/word/WdParagraphAlignment.hpp>
26#include <ooo/vba/word/WdOutlineLevel.hpp>
27#include <com/sun/star/style/ParagraphAdjust.hpp>
28#include <com/sun/star/style/BreakType.hpp>
29#include <com/sun/star/beans/XPropertySet.hpp>
30#include "vbatabstops.hxx"
31#include <o3tl/string_view.hxx>
32
33using namespace ::ooo::vba;
34using namespace ::com::sun::star;
35
36const sal_Int16 CHARACTER_INDENT_FACTOR = 12;
37const sal_Int16 PERCENT100 = 100;
38const sal_Int16 PERCENT150 = 150;
39const sal_Int16 PERCENT200 = 200;
40
41SwVbaParagraphFormat::SwVbaParagraphFormat( const uno::Reference< ooo::vba::XHelperInterface >& rParent, const uno::Reference< uno::XComponentContext >& rContext, uno::Reference< beans::XPropertySet > xParaProps ) : SwVbaParagraphFormat_BASE( rParent, rContext ), mxParaProps(std::move( xParaProps ))
42{
43}
44
46{
47}
48
50{
51 style::ParagraphAdjust aParaAdjust = style::ParagraphAdjust_LEFT;
52 mxParaProps->getPropertyValue("ParaAdjust") >>= aParaAdjust;
53 return getMSWordAlignment( aParaAdjust );
54}
55
56void SAL_CALL SwVbaParagraphFormat::setAlignment( sal_Int32 _alignment )
57{
58 style::ParagraphAdjust aParaAdjust = getOOoAlignment( _alignment );
59 mxParaProps->setPropertyValue("ParaAdjust", uno::Any( aParaAdjust ) );
60}
61
63{
64 sal_Int32 indent = 0;
65 mxParaProps->getPropertyValue("ParaFirstLineIndent") >>= indent;
66 return static_cast<float>( Millimeter::getInPoints( indent ) );
67}
68
69void SAL_CALL SwVbaParagraphFormat::setFirstLineIndent( float _firstlineindent )
70{
71 sal_Int32 indent = Millimeter::getInHundredthsOfOneMillimeter( _firstlineindent );
72 mxParaProps->setPropertyValue("ParaFirstLineIndent", uno::Any( indent ) );
73}
74
76{
77 bool bKeep = false;
78 mxParaProps->getPropertyValue("ParaKeepTogether") >>= bKeep;
79 return uno::Any ( bKeep );
80}
81
82void SAL_CALL SwVbaParagraphFormat::setKeepTogether( const uno::Any& _keeptogether )
83{
84 bool bKeep = false;
85 if( _keeptogether >>= bKeep )
86 {
87 mxParaProps->setPropertyValue("ParaKeepTogether", uno::Any( bKeep ) );
88 }
89 else
90 {
91 DebugHelper::runtimeexception( ERRCODE_BASIC_BAD_PARAMETER );
92 }
93}
94
96{
97 bool bKeep = false;
98 mxParaProps->getPropertyValue("ParaSplit") >>= bKeep;
99 return uno::Any ( bKeep );
100}
101
102void SAL_CALL SwVbaParagraphFormat::setKeepWithNext( const uno::Any& _keepwithnext )
103{
104 bool bKeep = false;
105 if( _keepwithnext >>= bKeep )
106 {
107 mxParaProps->setPropertyValue("ParaSplit", uno::Any( bKeep ) );
108 }
109 else
110 {
111 DebugHelper::runtimeexception( ERRCODE_BASIC_BAD_PARAMETER );
112 }
113}
114
116{
117 bool bHypn = false;
118 mxParaProps->getPropertyValue("ParaIsHyphenation") >>= bHypn;
119 return uno::Any ( bHypn );
120}
121
122void SAL_CALL SwVbaParagraphFormat::setHyphenation( const uno::Any& _hyphenation )
123{
124 bool bHypn = false;
125 if( _hyphenation >>= bHypn )
126 {
127 mxParaProps->setPropertyValue("ParaIsHyphenation", uno::Any( bHypn ) );
128 }
129 else
130 {
131 DebugHelper::runtimeexception( ERRCODE_BASIC_BAD_PARAMETER );
132 }
133}
134
136{
137 style::LineSpacing aLineSpacing;
138 mxParaProps->getPropertyValue("ParaLineSpacing") >>= aLineSpacing;
139 return getMSWordLineSpacing( aLineSpacing );
140}
141
142void SAL_CALL SwVbaParagraphFormat::setLineSpacing( float _linespacing )
143{
144 style::LineSpacing aLineSpacing;
145 mxParaProps->getPropertyValue("ParaLineSpacing") >>= aLineSpacing;
146 aLineSpacing = getOOoLineSpacing( _linespacing, aLineSpacing.Mode );
147 mxParaProps->setPropertyValue("ParaLineSpacing", uno::Any( aLineSpacing ) );
148}
149
151{
152 style::LineSpacing aLineSpacing;
153 mxParaProps->getPropertyValue("ParaLineSpacing") >>= aLineSpacing;
154 return getMSWordLineSpacingRule( aLineSpacing );
155}
156
157void SAL_CALL SwVbaParagraphFormat::setLineSpacingRule( sal_Int32 _linespacingrule )
158{
159 style::LineSpacing aLineSpacing = getOOoLineSpacingFromRule( _linespacingrule );
160 mxParaProps->setPropertyValue("ParaLineSpacing", uno::Any( aLineSpacing ) );
161}
162
164{
165 bool noLineNum = false;
166 mxParaProps->getPropertyValue("ParaLineNumberCount") >>= noLineNum;
167 return uno::Any ( noLineNum );
168}
169
170void SAL_CALL SwVbaParagraphFormat::setNoLineNumber( const uno::Any& _nolinenumber )
171{
172 bool noLineNum = false;
173 if( _nolinenumber >>= noLineNum )
174 {
175 mxParaProps->setPropertyValue("ParaLineNumberCount", uno::Any( noLineNum ) );
176 }
177 else
178 {
179 DebugHelper::runtimeexception( ERRCODE_BASIC_BAD_PARAMETER );
180 }
181}
182
184{
185 sal_Int32 nLevel = word::WdOutlineLevel::wdOutlineLevelBodyText;
186 OUString aHeading;
187 static constexpr OUStringLiteral HEADING = u"Heading";
188 mxParaProps->getPropertyValue("ParaStyleName") >>= aHeading;
189 if( aHeading.startsWith( HEADING ) )
190 {
191 // get the sub string after "Heading"
192 nLevel = o3tl::toInt32(aHeading.subView( HEADING.getLength() ));
193 }
194 return nLevel;
195}
196
197void SAL_CALL SwVbaParagraphFormat::setOutlineLevel( sal_Int32 _outlinelevel )
198{
199 if( _outlinelevel != getOutlineLevel() )
200 {
201 // TODO: in my test in msword, there is no effect for this function.
202 }
203}
204
206{
207 style::BreakType aBreakType;
208 mxParaProps->getPropertyValue("BreakType") >>= aBreakType;
209 bool bBreakBefore = ( aBreakType == style::BreakType_PAGE_BEFORE || aBreakType == style::BreakType_PAGE_BOTH );
210 return uno::Any( bBreakBefore );
211}
212
213void SAL_CALL SwVbaParagraphFormat::setPageBreakBefore( const uno::Any& _breakbefore )
214{
215 bool bBreakBefore = false;
216 if( _breakbefore >>= bBreakBefore )
217 {
218 style::BreakType aBreakType;
219 mxParaProps->getPropertyValue("BreakType") >>= aBreakType;
220 if( bBreakBefore )
221 {
222 if( aBreakType == style::BreakType_NONE )
223 aBreakType = style::BreakType_PAGE_BEFORE;
224 else if ( aBreakType == style::BreakType_PAGE_AFTER )
225 aBreakType = style::BreakType_PAGE_BOTH;
226 }
227 else
228 {
229 if( aBreakType == style::BreakType_PAGE_BOTH )
230 aBreakType = style::BreakType_PAGE_AFTER;
231 else if ( aBreakType == style::BreakType_PAGE_BEFORE )
232 aBreakType = style::BreakType_PAGE_AFTER;
233 }
234 mxParaProps->setPropertyValue("BreakType", uno::Any( aBreakType ) );
235 }
236 else
237 {
238 DebugHelper::runtimeexception( ERRCODE_BASIC_BAD_PARAMETER );
239 }
240}
241
243{
244 sal_Int32 nSpace = 0;
245 mxParaProps->getPropertyValue("ParaTopMargin") >>= nSpace;
246 return static_cast<float>( Millimeter::getInPoints( nSpace ) );
247}
248
249void SAL_CALL SwVbaParagraphFormat::setSpaceBefore( float _space )
250{
251 sal_Int32 nSpace = Millimeter::getInHundredthsOfOneMillimeter( _space );
252 mxParaProps->setPropertyValue("ParaTopMargin", uno::Any( nSpace ) );
253}
254
256{
257 sal_Int32 nSpace = 0;
258 mxParaProps->getPropertyValue("ParaBottomMargin") >>= nSpace;
259 return static_cast<float>( Millimeter::getInPoints( nSpace ) );
260}
261
262void SAL_CALL SwVbaParagraphFormat::setSpaceAfter( float _space )
263{
264 sal_Int32 nSpace = Millimeter::getInHundredthsOfOneMillimeter( _space );
265 mxParaProps->setPropertyValue("ParaBottomMargin", uno::Any( nSpace ) );
266}
267
269{
270 sal_Int32 nIndent = 0;
271 mxParaProps->getPropertyValue("ParaLeftMargin") >>= nIndent;
272 return static_cast<float>( Millimeter::getInPoints( nIndent ) );
273}
274
275void SAL_CALL SwVbaParagraphFormat::setLeftIndent( float _leftindent )
276{
277 sal_Int32 nIndent = Millimeter::getInHundredthsOfOneMillimeter( _leftindent );
278 mxParaProps->setPropertyValue("ParaLeftMargin", uno::Any( nIndent ) );
279}
280
282{
283 sal_Int32 nIndent = 0;
284 mxParaProps->getPropertyValue("ParaRightMargin") >>= nIndent;
285 return static_cast<float>( Millimeter::getInPoints( nIndent ) );
286}
287
288void SAL_CALL SwVbaParagraphFormat::setRightIndent( float _rightindent )
289{
290 sal_Int32 nIndent = Millimeter::getInHundredthsOfOneMillimeter( _rightindent );
291 mxParaProps->setPropertyValue("ParaRightMargin", uno::Any( nIndent ) );
292}
293
295{
296 return uno::Any( uno::Reference< word::XTabStops >( new SwVbaTabStops( this, mxContext, mxParaProps ) ) );
297}
298
299void SAL_CALL SwVbaParagraphFormat::setTabStops( const uno::Any& /*_tabstops*/ )
300{
301 throw uno::RuntimeException("Not implemented" );
302}
303
305{
306 sal_Int8 nWidow = 0;
307 mxParaProps->getPropertyValue("ParaWidows") >>= nWidow;
308 sal_Int8 nOrphan = 0;
309 mxParaProps->getPropertyValue("ParaOrphans") >>= nOrphan;
310 // if the amount of single lines on one page > 1 and the same of start and end of the paragraph,
311 // true is returned.
312 bool bWidow = ( nWidow > 1 && nOrphan == nWidow );
313 return uno::Any( bWidow );
314}
315
316void SAL_CALL SwVbaParagraphFormat::setWidowControl( const uno::Any& _widowcontrol )
317{
318 // if we get true, the part of the paragraph on one page has to be
319 // at least two lines
320 bool bWidow = false;
321 if( _widowcontrol >>= bWidow )
322 {
323 sal_Int8 nControl = bWidow? 2:1;
324 mxParaProps->setPropertyValue("ParaWidows", uno::Any( nControl ) );
325 mxParaProps->setPropertyValue("ParaOrphans", uno::Any( nControl ) );
326 }
327 else
328 {
329 DebugHelper::runtimeexception( ERRCODE_BASIC_BAD_PARAMETER );
330 }
331}
332
333style::LineSpacing SwVbaParagraphFormat::getOOoLineSpacing( float _lineSpace, sal_Int16 mode )
334{
335 style::LineSpacing aLineSpacing;
336 if( mode != style::LineSpacingMode::MINIMUM && mode != style::LineSpacingMode::FIX )
337 {
338 // special behaviour of word: if the space is set to these values, the rule and
339 // the height are changed accordingly
340 if( _lineSpace == CHARACTER_INDENT_FACTOR )
341 {
342 aLineSpacing.Mode = style::LineSpacingMode::PROP;
343 aLineSpacing.Height = PERCENT100;
344 }
345 else if( _lineSpace == CHARACTER_INDENT_FACTOR * 1.5 ) // no rounding issues, == 18
346 {
347 aLineSpacing.Mode = style::LineSpacingMode::PROP;
348 aLineSpacing.Height = PERCENT150;
349 }
350 else if( _lineSpace == CHARACTER_INDENT_FACTOR * 2 )
351 {
352 aLineSpacing.Mode = style::LineSpacingMode::PROP;
353 aLineSpacing.Height = PERCENT200;
354 }
355 else
356 {
357 aLineSpacing.Mode = style::LineSpacingMode::FIX;
358 aLineSpacing.Height = static_cast<sal_Int16>( Millimeter::getInHundredthsOfOneMillimeter( _lineSpace ) );
359 }
360 }
361 else
362 {
363 aLineSpacing.Mode = mode;
364 aLineSpacing.Height = static_cast<sal_Int16>( Millimeter::getInHundredthsOfOneMillimeter( _lineSpace ) );
365 }
366 return aLineSpacing;
367}
368
369style::LineSpacing SwVbaParagraphFormat::getOOoLineSpacingFromRule( sal_Int32 _linespacingrule )
370{
371 style::LineSpacing aLineSpacing;
372 switch( _linespacingrule )
373 {
374 case word::WdLineSpacing::wdLineSpace1pt5:
375 {
376 aLineSpacing.Mode = style::LineSpacingMode::PROP;
377 aLineSpacing.Height = PERCENT150;
378 break;
379 }
380 case word::WdLineSpacing::wdLineSpaceAtLeast:
381 {
382 aLineSpacing.Mode = style::LineSpacingMode::MINIMUM;
383 aLineSpacing.Height = getCharHeight();
384 break;
385 }
386 case word::WdLineSpacing::wdLineSpaceDouble:
387 {
388 aLineSpacing.Mode = style::LineSpacingMode::PROP;
389 aLineSpacing.Height = getCharHeight();
390 break;
391 }
392 case word::WdLineSpacing::wdLineSpaceExactly:
393 case word::WdLineSpacing::wdLineSpaceMultiple:
394 {
395 aLineSpacing.Mode = style::LineSpacingMode::FIX;
396 aLineSpacing.Height = getCharHeight();
397 break;
398 }
399 case word::WdLineSpacing::wdLineSpaceSingle:
400 {
401 aLineSpacing.Mode = style::LineSpacingMode::PROP;
402 aLineSpacing.Height = PERCENT100;
403 break;
404 }
405 default:
406 {
407 DebugHelper::runtimeexception( ERRCODE_BASIC_BAD_PARAMETER );
408 break;
409 }
410 }
411 return aLineSpacing;
412}
413
414float SwVbaParagraphFormat::getMSWordLineSpacing( style::LineSpacing const & rLineSpacing )
415{
416 float wdLineSpacing = 0;
417 if( rLineSpacing.Mode != style::LineSpacingMode::PROP )
418 {
419 wdLineSpacing = static_cast<float>( Millimeter::getInPoints( rLineSpacing.Height ) );
420 }
421 else
422 {
423 wdLineSpacing = static_cast<float>( CHARACTER_INDENT_FACTOR * rLineSpacing.Height ) / PERCENT100;
424 }
425 return wdLineSpacing;
426}
427
428sal_Int32 SwVbaParagraphFormat::getMSWordLineSpacingRule( style::LineSpacing const & rLineSpacing )
429{
430 sal_Int32 wdLineSpacing = word::WdLineSpacing::wdLineSpaceSingle;
431 switch( rLineSpacing.Mode )
432 {
433 case style::LineSpacingMode::PROP:
434 {
435 switch( rLineSpacing.Height )
436 {
437 case PERCENT100:
438 {
439 wdLineSpacing = word::WdLineSpacing::wdLineSpaceSingle;
440 break;
441 }
442 case PERCENT150:
443 {
444 wdLineSpacing = word::WdLineSpacing::wdLineSpace1pt5;
445 break;
446 }
447 case PERCENT200:
448 {
449 wdLineSpacing = word::WdLineSpacing::wdLineSpaceDouble;
450 break;
451 }
452 default:
453 {
454 wdLineSpacing = word::WdLineSpacing::wdLineSpaceMultiple;
455 }
456 }
457 break;
458 }
459 case style::LineSpacingMode::MINIMUM:
460 {
461 wdLineSpacing = word::WdLineSpacing::wdLineSpaceAtLeast;
462 break;
463 }
464 case style::LineSpacingMode::FIX:
465 case style::LineSpacingMode::LEADING:
466 {
467 wdLineSpacing = word::WdLineSpacing::wdLineSpaceExactly;
468 break;
469 }
470 default:
471 {
472 DebugHelper::runtimeexception( ERRCODE_BASIC_BAD_PARAMETER );
473 }
474 }
475 return wdLineSpacing;
476}
477
479{
480 float fCharHeight = 0.0;
481 mxParaProps->getPropertyValue("CharHeight") >>= fCharHeight;
482 return static_cast<sal_Int16>( Millimeter::getInHundredthsOfOneMillimeter( fCharHeight ) );
483}
484
485style::ParagraphAdjust SwVbaParagraphFormat::getOOoAlignment( sal_Int32 _alignment )
486{
487 style::ParagraphAdjust nParaAjust = style::ParagraphAdjust_LEFT;
488 switch( _alignment )
489 {
490 case word::WdParagraphAlignment::wdAlignParagraphCenter:
491 {
492 nParaAjust = style::ParagraphAdjust_CENTER;
493 break;
494 }
495 case word::WdParagraphAlignment::wdAlignParagraphJustify:
496 {
497 nParaAjust = style::ParagraphAdjust_BLOCK;
498 break;
499 }
500 case word::WdParagraphAlignment::wdAlignParagraphLeft:
501 {
502 nParaAjust = style::ParagraphAdjust_LEFT;
503 break;
504 }
505 case word::WdParagraphAlignment::wdAlignParagraphRight:
506 {
507 nParaAjust = style::ParagraphAdjust_RIGHT;
508 break;
509 }
510 default:
511 {
512 DebugHelper::runtimeexception( ERRCODE_BASIC_BAD_PARAMETER );
513 }
514 }
515 return nParaAjust;
516}
517
518sal_Int32 SwVbaParagraphFormat::getMSWordAlignment( style::ParagraphAdjust _alignment )
519{
520 sal_Int32 wdAlignment = word::WdParagraphAlignment::wdAlignParagraphLeft;
521 switch( _alignment )
522 {
523 case style::ParagraphAdjust_CENTER:
524 {
525 wdAlignment = word::WdParagraphAlignment::wdAlignParagraphCenter;
526 break;
527 }
528 case style::ParagraphAdjust_LEFT:
529 {
530 wdAlignment = word::WdParagraphAlignment::wdAlignParagraphLeft;
531 break;
532 }
533 case style::ParagraphAdjust_BLOCK:
534 {
535 wdAlignment = word::WdParagraphAlignment::wdAlignParagraphJustify;
536 break;
537 }
538 case style::ParagraphAdjust_RIGHT:
539 {
540 wdAlignment = word::WdParagraphAlignment::wdAlignParagraphRight;
541 break;
542 }
543 default:
544 {
545 DebugHelper::basicexception( ERRCODE_BASIC_BAD_PARAMETER, {} );
546 }
547 }
548 return wdAlignment;
549}
550
551OUString
553{
554 return "SwVbaParagraphFormat";
555}
556
557uno::Sequence< OUString >
559{
560 static uno::Sequence< OUString > const aServiceNames
561 {
562 "ooo.vba.word.ParagraphFormat"
563 };
564 return aServiceNames;
565}
566
567/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
css::uno::Reference< css::uno::XComponentContext > mxContext
virtual void SAL_CALL setTabStops(const css::uno::Any &_tabstops) override
virtual css::uno::Any SAL_CALL getKeepWithNext() override
virtual void SAL_CALL setLineSpacingRule(::sal_Int32 _linespacingrule) override
css::uno::Reference< css::beans::XPropertySet > mxParaProps
static css::style::ParagraphAdjust getOOoAlignment(sal_Int32 _alignment)
virtual css::uno::Any SAL_CALL getHyphenation() override
virtual void SAL_CALL setLineSpacing(float _linespacing) override
virtual css::uno::Any SAL_CALL getNoLineNumber() override
virtual void SAL_CALL setSpaceAfter(float _spaceafter) override
virtual css::uno::Any SAL_CALL getKeepTogether() override
virtual void SAL_CALL setRightIndent(float _rightindent) override
virtual void SAL_CALL setPageBreakBefore(const css::uno::Any &_pagebreakbefore) override
virtual css::uno::Any SAL_CALL getTabStops() override
static sal_Int32 getMSWordLineSpacingRule(css::style::LineSpacing const &rLineSpacing)
virtual float SAL_CALL getLineSpacing() override
virtual void SAL_CALL setFirstLineIndent(float _firstlineindent) override
virtual ::sal_Int32 SAL_CALL getOutlineLevel() override
static float getMSWordLineSpacing(css::style::LineSpacing const &rLineSpacing)
virtual float SAL_CALL getRightIndent() override
virtual css::uno::Any SAL_CALL getPageBreakBefore() override
SwVbaParagraphFormat(const css::uno::Reference< ooo::vba::XHelperInterface > &rParent, const css::uno::Reference< css::uno::XComponentContext > &rContext, css::uno::Reference< css::beans::XPropertySet > xParaProps)
virtual float SAL_CALL getSpaceAfter() override
virtual float SAL_CALL getFirstLineIndent() override
static css::style::LineSpacing getOOoLineSpacing(float _lineSpace, sal_Int16 mode)
virtual void SAL_CALL setHyphenation(const css::uno::Any &_hyphenation) override
virtual css::uno::Sequence< OUString > getServiceNames() override
virtual ~SwVbaParagraphFormat() override
virtual css::uno::Any SAL_CALL getWidowControl() override
virtual void SAL_CALL setOutlineLevel(::sal_Int32 _outlinelevel) override
virtual void SAL_CALL setAlignment(::sal_Int32 _alignment) override
static sal_Int32 getMSWordAlignment(css::style::ParagraphAdjust _alignment)
virtual void SAL_CALL setNoLineNumber(const css::uno::Any &_nolinenumber) override
virtual float SAL_CALL getLeftIndent() override
virtual ::sal_Int32 SAL_CALL getLineSpacingRule() override
virtual void SAL_CALL setSpaceBefore(float _spacebefore) override
virtual void SAL_CALL setLeftIndent(float _leftindent) override
virtual void SAL_CALL setKeepWithNext(const css::uno::Any &_keepwithnext) override
virtual void SAL_CALL setKeepTogether(const css::uno::Any &_keeptogether) override
virtual OUString getServiceImplName() override
virtual ::sal_Int32 SAL_CALL getAlignment() override
virtual float SAL_CALL getSpaceBefore() override
css::style::LineSpacing getOOoLineSpacingFromRule(sal_Int32 _linespacingrule)
virtual void SAL_CALL setWidowControl(const css::uno::Any &_widowcontrol) override
float u
Sequence< OUString > aServiceNames
sal_Int32 toInt32(std::u16string_view str, sal_Int16 radix=10)
ConversionMode mode
#define ERRCODE_BASIC_BAD_PARAMETER
signed char sal_Int8
const sal_Int16 CHARACTER_INDENT_FACTOR
const sal_Int16 PERCENT100
const sal_Int16 PERCENT150
const sal_Int16 PERCENT200