diff options
Diffstat (limited to 'sw/source/ui/vba/vbaparagraphformat.cxx')
-rw-r--r-- | sw/source/ui/vba/vbaparagraphformat.cxx | 70 |
1 files changed, 35 insertions, 35 deletions
diff --git a/sw/source/ui/vba/vbaparagraphformat.cxx b/sw/source/ui/vba/vbaparagraphformat.cxx index 5f42c697c41c..196240e49ab9 100644 --- a/sw/source/ui/vba/vbaparagraphformat.cxx +++ b/sw/source/ui/vba/vbaparagraphformat.cxx @@ -48,33 +48,33 @@ SwVbaParagraphFormat::~SwVbaParagraphFormat() sal_Int32 SAL_CALL SwVbaParagraphFormat::getAlignment() throw (uno::RuntimeException) { style::ParagraphAdjust aParaAdjust = style::ParagraphAdjust_LEFT; - mxParaProps->getPropertyValue( OUString("ParaAdjust") ) >>= aParaAdjust; + mxParaProps->getPropertyValue("ParaAdjust") >>= aParaAdjust; return getMSWordAlignment( aParaAdjust ); } void SAL_CALL SwVbaParagraphFormat::setAlignment( sal_Int32 _alignment ) throw (uno::RuntimeException) { style::ParagraphAdjust aParaAdjust = ( style::ParagraphAdjust ) getOOoAlignment( _alignment ); - mxParaProps->setPropertyValue( OUString("ParaAdjust"), uno::makeAny( aParaAdjust ) ); + mxParaProps->setPropertyValue("ParaAdjust", uno::makeAny( aParaAdjust ) ); } float SAL_CALL SwVbaParagraphFormat::getFirstLineIndent() throw (uno::RuntimeException) { sal_Int32 indent = 0; - mxParaProps->getPropertyValue( OUString("ParaFirstLineIndent") ) >>= indent; + mxParaProps->getPropertyValue("ParaFirstLineIndent") >>= indent; return (float)( Millimeter::getInPoints( indent ) ); } void SAL_CALL SwVbaParagraphFormat::setFirstLineIndent( float _firstlineindent ) throw (uno::RuntimeException) { sal_Int32 indent = Millimeter::getInHundredthsOfOneMillimeter( _firstlineindent ); - mxParaProps->setPropertyValue( OUString("ParaFirstLineIndent"), uno::makeAny( indent ) ); + mxParaProps->setPropertyValue("ParaFirstLineIndent", uno::makeAny( indent ) ); } uno::Any SAL_CALL SwVbaParagraphFormat::getKeepTogether() throw (uno::RuntimeException) { sal_Bool bKeep = sal_False; - mxParaProps->getPropertyValue( OUString("ParaKeepTogether") ) >>= bKeep; + mxParaProps->getPropertyValue("ParaKeepTogether") >>= bKeep; return uno::makeAny ( bKeep ); } @@ -83,7 +83,7 @@ void SAL_CALL SwVbaParagraphFormat::setKeepTogether( const uno::Any& _keeptogeth sal_Bool bKeep = sal_False; if( _keeptogether >>= bKeep ) { - mxParaProps->setPropertyValue( OUString("ParaKeepTogether"), uno::makeAny( bKeep ) ); + mxParaProps->setPropertyValue("ParaKeepTogether", uno::makeAny( bKeep ) ); } else { @@ -94,7 +94,7 @@ void SAL_CALL SwVbaParagraphFormat::setKeepTogether( const uno::Any& _keeptogeth uno::Any SAL_CALL SwVbaParagraphFormat::getKeepWithNext() throw (uno::RuntimeException) { sal_Bool bKeep = sal_False; - mxParaProps->getPropertyValue( OUString("ParaSplit") ) >>= bKeep; + mxParaProps->getPropertyValue("ParaSplit") >>= bKeep; return uno::makeAny ( bKeep ); } @@ -103,7 +103,7 @@ void SAL_CALL SwVbaParagraphFormat::setKeepWithNext( const uno::Any& _keepwithne sal_Bool bKeep = sal_False; if( _keepwithnext >>= bKeep ) { - mxParaProps->setPropertyValue( OUString("ParaSplit"), uno::makeAny( bKeep ) ); + mxParaProps->setPropertyValue("ParaSplit", uno::makeAny( bKeep ) ); } else { @@ -114,7 +114,7 @@ void SAL_CALL SwVbaParagraphFormat::setKeepWithNext( const uno::Any& _keepwithne uno::Any SAL_CALL SwVbaParagraphFormat::getHyphenation() throw (uno::RuntimeException) { sal_Bool bHypn = sal_False; - mxParaProps->getPropertyValue( OUString("ParaIsHyphenation") ) >>= bHypn; + mxParaProps->getPropertyValue("ParaIsHyphenation") >>= bHypn; return uno::makeAny ( bHypn ); } @@ -123,7 +123,7 @@ void SAL_CALL SwVbaParagraphFormat::setHyphenation( const uno::Any& _hyphenation sal_Bool bHypn = sal_False; if( _hyphenation >>= bHypn ) { - mxParaProps->setPropertyValue( OUString("ParaIsHyphenation"), uno::makeAny( bHypn ) ); + mxParaProps->setPropertyValue("ParaIsHyphenation", uno::makeAny( bHypn ) ); } else { @@ -134,35 +134,35 @@ void SAL_CALL SwVbaParagraphFormat::setHyphenation( const uno::Any& _hyphenation float SAL_CALL SwVbaParagraphFormat::getLineSpacing() throw (uno::RuntimeException) { style::LineSpacing aLineSpacing; - mxParaProps->getPropertyValue( OUString("ParaLineSpacing") ) >>= aLineSpacing; + mxParaProps->getPropertyValue("ParaLineSpacing") >>= aLineSpacing; return getMSWordLineSpacing( aLineSpacing ); } void SAL_CALL SwVbaParagraphFormat::setLineSpacing( float _linespacing ) throw (uno::RuntimeException) { style::LineSpacing aLineSpacing; - mxParaProps->getPropertyValue( OUString("ParaLineSpacing") ) >>= aLineSpacing; + mxParaProps->getPropertyValue("ParaLineSpacing") >>= aLineSpacing; aLineSpacing = getOOoLineSpacing( _linespacing, aLineSpacing.Mode ); - mxParaProps->setPropertyValue( OUString("ParaLineSpacing"), uno::makeAny( aLineSpacing ) ); + mxParaProps->setPropertyValue("ParaLineSpacing", uno::makeAny( aLineSpacing ) ); } sal_Int32 SAL_CALL SwVbaParagraphFormat::getLineSpacingRule() throw (uno::RuntimeException) { style::LineSpacing aLineSpacing; - mxParaProps->getPropertyValue( OUString("ParaLineSpacing") ) >>= aLineSpacing; + mxParaProps->getPropertyValue("ParaLineSpacing") >>= aLineSpacing; return getMSWordLineSpacingRule( aLineSpacing ); } void SAL_CALL SwVbaParagraphFormat::setLineSpacingRule( sal_Int32 _linespacingrule ) throw (uno::RuntimeException) { style::LineSpacing aLineSpacing = getOOoLineSpacingFromRule( _linespacingrule ); - mxParaProps->setPropertyValue( OUString("ParaLineSpacing"), uno::makeAny( aLineSpacing ) ); + mxParaProps->setPropertyValue("ParaLineSpacing", uno::makeAny( aLineSpacing ) ); } uno::Any SAL_CALL SwVbaParagraphFormat::getNoLineNumber() throw (uno::RuntimeException) { sal_Bool noLineNum = sal_False; - mxParaProps->getPropertyValue( OUString("ParaLineNumberCount") ) >>= noLineNum; + mxParaProps->getPropertyValue("ParaLineNumberCount") >>= noLineNum; return uno::makeAny ( noLineNum ); } @@ -171,7 +171,7 @@ void SAL_CALL SwVbaParagraphFormat::setNoLineNumber( const uno::Any& _nolinenumb sal_Bool noLineNum = sal_False; if( _nolinenumber >>= noLineNum ) { - mxParaProps->setPropertyValue( OUString("ParaLineNumberCount"), uno::makeAny( noLineNum ) ); + mxParaProps->setPropertyValue("ParaLineNumberCount", uno::makeAny( noLineNum ) ); } else { @@ -184,7 +184,7 @@ sal_Int32 SAL_CALL SwVbaParagraphFormat::getOutlineLevel() throw (uno::RuntimeEx sal_Int32 nLevel = word::WdOutlineLevel::wdOutlineLevelBodyText; OUString aHeading; const OUString HEADING = OUString("Heading"); - mxParaProps->getPropertyValue( OUString("ParaStyleName") ) >>= aHeading; + mxParaProps->getPropertyValue("ParaStyleName") >>= aHeading; if( aHeading.indexOf( HEADING ) == 0 ) { // get the sub string after "Heading" @@ -204,7 +204,7 @@ void SAL_CALL SwVbaParagraphFormat::setOutlineLevel( sal_Int32 _outlinelevel ) t uno::Any SAL_CALL SwVbaParagraphFormat::getPageBreakBefore() throw (uno::RuntimeException) { style::BreakType aBreakType; - mxParaProps->getPropertyValue( OUString("BreakType") ) >>= aBreakType; + mxParaProps->getPropertyValue("BreakType") >>= aBreakType; sal_Bool bBreakBefore = ( aBreakType == style::BreakType_PAGE_BEFORE || aBreakType == style::BreakType_PAGE_BOTH ); return uno::makeAny( bBreakBefore ); } @@ -215,7 +215,7 @@ void SAL_CALL SwVbaParagraphFormat::setPageBreakBefore( const uno::Any& _breakbe if( _breakbefore >>= bBreakBefore ) { style::BreakType aBreakType; - mxParaProps->getPropertyValue( OUString("BreakType") ) >>= aBreakType; + mxParaProps->getPropertyValue("BreakType") >>= aBreakType; if( bBreakBefore ) { if( aBreakType == style::BreakType_NONE ) @@ -230,7 +230,7 @@ void SAL_CALL SwVbaParagraphFormat::setPageBreakBefore( const uno::Any& _breakbe else if ( aBreakType == style::BreakType_PAGE_BEFORE ) aBreakType = style::BreakType_PAGE_AFTER; } - mxParaProps->setPropertyValue( OUString("BreakType"), uno::makeAny( aBreakType ) ); + mxParaProps->setPropertyValue("BreakType", uno::makeAny( aBreakType ) ); } else { @@ -241,53 +241,53 @@ void SAL_CALL SwVbaParagraphFormat::setPageBreakBefore( const uno::Any& _breakbe float SAL_CALL SwVbaParagraphFormat::getSpaceBefore() throw (uno::RuntimeException) { sal_Int32 nSpace = 0; - mxParaProps->getPropertyValue( OUString("ParaTopMargin") ) >>= nSpace; + mxParaProps->getPropertyValue("ParaTopMargin") >>= nSpace; return (float)( Millimeter::getInPoints( nSpace ) ); } void SAL_CALL SwVbaParagraphFormat::setSpaceBefore( float _space ) throw (uno::RuntimeException) { sal_Int32 nSpace = Millimeter::getInHundredthsOfOneMillimeter( _space ); - mxParaProps->setPropertyValue( OUString("ParaTopMargin"), uno::makeAny( nSpace ) ); + mxParaProps->setPropertyValue("ParaTopMargin", uno::makeAny( nSpace ) ); } float SAL_CALL SwVbaParagraphFormat::getSpaceAfter() throw (uno::RuntimeException) { sal_Int32 nSpace = 0; - mxParaProps->getPropertyValue( OUString("ParaBottomMargin") ) >>= nSpace; + mxParaProps->getPropertyValue("ParaBottomMargin") >>= nSpace; return (float)( Millimeter::getInPoints( nSpace ) ); } void SAL_CALL SwVbaParagraphFormat::setSpaceAfter( float _space ) throw (uno::RuntimeException) { sal_Int32 nSpace = Millimeter::getInHundredthsOfOneMillimeter( _space ); - mxParaProps->setPropertyValue( OUString("ParaBottomMargin"), uno::makeAny( nSpace ) ); + mxParaProps->setPropertyValue("ParaBottomMargin", uno::makeAny( nSpace ) ); } float SAL_CALL SwVbaParagraphFormat::getLeftIndent() throw (uno::RuntimeException) { sal_Int32 nIndent = 0; - mxParaProps->getPropertyValue( OUString("ParaLeftMargin") ) >>= nIndent; + mxParaProps->getPropertyValue("ParaLeftMargin") >>= nIndent; return (float)( Millimeter::getInPoints( nIndent ) ); } void SAL_CALL SwVbaParagraphFormat::setLeftIndent( float _leftindent ) throw (uno::RuntimeException) { sal_Int32 nIndent = Millimeter::getInHundredthsOfOneMillimeter( _leftindent ); - mxParaProps->setPropertyValue( OUString("ParaLeftMargin"), uno::makeAny( nIndent ) ); + mxParaProps->setPropertyValue("ParaLeftMargin", uno::makeAny( nIndent ) ); } float SAL_CALL SwVbaParagraphFormat::getRightIndent() throw (uno::RuntimeException) { sal_Int32 nIndent = 0; - mxParaProps->getPropertyValue( OUString("ParaRightMargin") ) >>= nIndent; + mxParaProps->getPropertyValue("ParaRightMargin") >>= nIndent; return (float)( Millimeter::getInPoints( nIndent ) ); } void SAL_CALL SwVbaParagraphFormat::setRightIndent( float _rightindent ) throw (uno::RuntimeException) { sal_Int32 nIndent = Millimeter::getInHundredthsOfOneMillimeter( _rightindent ); - mxParaProps->setPropertyValue( OUString("ParaRightMargin"), uno::makeAny( nIndent ) ); + mxParaProps->setPropertyValue("ParaRightMargin", uno::makeAny( nIndent ) ); } uno::Any SAL_CALL SwVbaParagraphFormat::getTabStops() throw (uno::RuntimeException) @@ -297,15 +297,15 @@ uno::Any SAL_CALL SwVbaParagraphFormat::getTabStops() throw (uno::RuntimeExcepti void SAL_CALL SwVbaParagraphFormat::setTabStops( const uno::Any& /*_tabstops*/ ) throw (uno::RuntimeException) { - throw uno::RuntimeException( OUString("Not implemented"), uno::Reference< uno::XInterface >() ); + throw uno::RuntimeException("Not implemented", uno::Reference< uno::XInterface >() ); } uno::Any SAL_CALL SwVbaParagraphFormat::getWidowControl() throw (uno::RuntimeException) { sal_Int8 nWidow = 0; - mxParaProps->getPropertyValue( OUString("ParaWidows") ) >>= nWidow; + mxParaProps->getPropertyValue("ParaWidows") >>= nWidow; sal_Int8 nOrphan = 0; - mxParaProps->getPropertyValue( OUString("ParaOrphans") ) >>= nOrphan; + mxParaProps->getPropertyValue("ParaOrphans") >>= nOrphan; // if the amount of single lines on one page > 1 and the same of start and end of the paragraph, // true is retured. sal_Bool bWidow = ( nWidow > 1 && nOrphan == nWidow ); @@ -320,8 +320,8 @@ void SAL_CALL SwVbaParagraphFormat::setWidowControl( const uno::Any& _widowcontr if( _widowcontrol >>= bWidow ) { sal_Int8 nControl = bWidow? 2:1; - mxParaProps->setPropertyValue( OUString("ParaWidows"), uno::makeAny( nControl ) ); - mxParaProps->setPropertyValue( OUString("ParaOrphans"), uno::makeAny( nControl ) ); + mxParaProps->setPropertyValue("ParaWidows", uno::makeAny( nControl ) ); + mxParaProps->setPropertyValue("ParaOrphans", uno::makeAny( nControl ) ); } else { @@ -477,7 +477,7 @@ sal_Int32 SwVbaParagraphFormat::getMSWordLineSpacingRule( style::LineSpacing& rL sal_Int16 SwVbaParagraphFormat::getCharHeight() throw (uno::RuntimeException) { float fCharHeight = 0.0; - mxParaProps->getPropertyValue( OUString("CharHeight") ) >>= fCharHeight; + mxParaProps->getPropertyValue("CharHeight") >>= fCharHeight; return (sal_Int16)( Millimeter::getInHundredthsOfOneMillimeter( fCharHeight ) ); } |