diff options
Diffstat (limited to 'svx/source')
-rw-r--r-- | svx/source/customshapes/EnhancedCustomShape2d.cxx | 231 | ||||
-rw-r--r-- | svx/source/customshapes/EnhancedCustomShape3d.cxx | 42 | ||||
-rw-r--r-- | svx/source/customshapes/EnhancedCustomShapeEngine.cxx | 6 | ||||
-rw-r--r-- | svx/source/customshapes/EnhancedCustomShapeEngine.hxx | 1 | ||||
-rw-r--r-- | svx/source/customshapes/tbxcustomshapes.cxx | 26 | ||||
-rw-r--r-- | svx/source/dialog/_bmpmask.cxx | 8 | ||||
-rw-r--r-- | svx/source/dialog/pfiledlg.cxx | 4 | ||||
-rw-r--r-- | svx/source/dialog/sendreportunx.cxx | 10 | ||||
-rw-r--r-- | svx/source/dialog/srchdlg.cxx | 2 | ||||
-rw-r--r-- | svx/source/dialog/svxbmpnumvalueset.cxx | 6 |
10 files changed, 165 insertions, 171 deletions
diff --git a/svx/source/customshapes/EnhancedCustomShape2d.cxx b/svx/source/customshapes/EnhancedCustomShape2d.cxx index 96fc82c0a552..8c199a08a9fd 100644 --- a/svx/source/customshapes/EnhancedCustomShape2d.cxx +++ b/svx/source/customshapes/EnhancedCustomShape2d.cxx @@ -78,9 +78,9 @@ void EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( EnhancedCustomShape rParameter.Value <<= nNewValue; } -rtl::OUString EnhancedCustomShape2d::GetEquation( const sal_uInt16 nFlags, sal_Int16 nP1, sal_Int16 nP2, sal_Int16 nP3 ) +OUString EnhancedCustomShape2d::GetEquation( const sal_uInt16 nFlags, sal_Int16 nP1, sal_Int16 nP2, sal_Int16 nP3 ) { - rtl::OUString aEquation; + OUString aEquation; sal_Bool b1Special = ( nFlags & 0x2000 ) != 0; sal_Bool b2Special = ( nFlags & 0x4000 ) != 0; sal_Bool b3Special = ( nFlags & 0x8000 ) != 0; @@ -144,41 +144,41 @@ rtl::OUString EnhancedCustomShape2d::GetEquation( const sal_uInt16 nFlags, sal_I break; case 2 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "(" ) ); + aEquation += "("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "+" ) ); + aEquation += "+"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( ")/2" ) ); + aEquation += ")/2"; } break; case 3 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "abs(" ) ); + aEquation += "abs("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( ")" ) ); + aEquation += ")"; } break; case 4 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "min(" ) ); + aEquation += "min("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "," ) ); + aEquation += ","; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( ")" ) ); + aEquation += ")"; } break; case 5 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "max(" ) ); + aEquation += "max("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "," ) ); + aEquation += ","; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( ")" ) ); + aEquation += ")"; } break; case 6 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "if(" ) ); + aEquation += "if("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); aEquation += rtl::OUString( (sal_Unicode)',' ); EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); @@ -189,135 +189,133 @@ rtl::OUString EnhancedCustomShape2d::GetEquation( const sal_uInt16 nFlags, sal_I break; case 7 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "sqrt(" ) ); + aEquation += "sqrt("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*" ) ); + aEquation += "*"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "+" ) ); + aEquation += "+"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*" ) ); + aEquation += "*"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "+" ) ); + aEquation += "+"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*" ) ); + aEquation += "*"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); aEquation += rtl::OUString( (sal_Unicode)')' ); } break; case 8 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "atan2(" ) ); + aEquation += "atan2("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "," ) ); + aEquation += ","; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( ")/(pi/180)" ) ); + aEquation += ")/(pi/180)"; } break; case 9 : { EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*sin(" ) ); + aEquation += "*sin("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*(pi/180))" ) ); + aEquation += "*(pi/180))"; } break; case 10 : { EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*cos(" ) ); + aEquation += "*cos("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*(pi/180))" ) ); + aEquation += "*(pi/180))"; } break; case 11 : { EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*" ) ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "cos(atan2(" ) ); + aEquation += "*cos(atan2("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "," ) ); + aEquation += ","; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "))" ) ); + aEquation += "))"; } break; case 12 : { EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*" ) ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "sin(atan2(" ) ); + aEquation += "*sin(atan2("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "," ) ); + aEquation += ","; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "))" ) ); + aEquation += "))"; } break; case 13 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "sqrt(" ) ); + aEquation += "sqrt("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( ")" ) ); + aEquation += ")"; } break; case 15 : { EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*sqrt(1-(" ) ); + aEquation += "*sqrt(1-("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "/" ) ); + aEquation += "/"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( ")" ) ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*(" ) ); + aEquation += ")"; + aEquation += "*("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "/" ) ); + aEquation += "/"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "))" ) ); + aEquation += "))"; } break; case 16 : { EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*tan(" ) ); + aEquation += "*tan("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( ")" ) ); + aEquation += ")"; } break; case 0x80 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "sqrt(" ) ); + aEquation += "sqrt("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*" ) ); + aEquation += "*"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "-" ) ); + aEquation += "-"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*" ) ); + aEquation += "*"; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); aEquation += rtl::OUString( (sal_Unicode)')' ); } break; case 0x81 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "(cos(" ) ); + aEquation += "(cos("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*(pi/180))*(" ) ); + aEquation += "*(pi/180))*("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "-10800)+sin(" ) ); + aEquation += "-10800)+sin("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*(pi/180))*(" ) ); + aEquation += "*(pi/180))*("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "-10800))+10800" ) ); + aEquation += "-10800))+10800"; } break; case 0x82 : { - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "-(sin(" ) ); + aEquation += "-(sin("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*(pi/180))*(" ) ); + aEquation += "*(pi/180))*("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP1, b1Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "-10800)-cos(" ) ); + aEquation += "-10800)-cos("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP3, b3Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "*(pi/180))*(" ) ); + aEquation += "*(pi/180))*("; EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( aEquation, nP2, b2Special ); - aEquation += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "-10800))+10800" ) ); + aEquation += "-10800))+10800"; } break; } @@ -330,9 +328,9 @@ void EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( rtl::OUS { if ( nPara & 0x400 ) { - rParameter += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "?" ) ); + rParameter += "?"; rParameter += rtl::OUString::valueOf( (sal_Int32)( nPara & 0xff ) ); - rParameter += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( " " ) ); + rParameter += " "; } else { @@ -349,29 +347,29 @@ void EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter( rtl::OUS case DFF_Prop_adjust9Value : case DFF_Prop_adjust10Value : { - rParameter += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "$" ) ); + rParameter += "$"; rParameter += rtl::OUString::valueOf( (sal_Int32)( nPara - DFF_Prop_adjustValue ) ); - rParameter += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( " " ) ); + rParameter += " "; } break; case DFF_Prop_geoLeft : { - rParameter += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "left" ) ); + rParameter += "left"; } break; case DFF_Prop_geoTop : { - rParameter += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "top" ) ); + rParameter += "top"; } break; case DFF_Prop_geoRight : { - rParameter += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "right" ) ); + rParameter += "right"; } break; case DFF_Prop_geoBottom : { - rParameter += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "bottom" ) ); + rParameter += "bottom"; } break; } @@ -446,28 +444,28 @@ sal_Bool EnhancedCustomShape2d::ConvertSequenceToEnhancedCustomShape2dHandle( { const com::sun::star::beans::PropertyValue& rPropVal = rHandleProperties[ i ]; - const rtl::OUString sPosition ( RTL_CONSTASCII_USTRINGPARAM( "Position" ) ); - const rtl::OUString sMirroredX ( RTL_CONSTASCII_USTRINGPARAM( "MirroredX" ) ); - const rtl::OUString sMirroredY ( RTL_CONSTASCII_USTRINGPARAM( "MirroredY" ) ); - const rtl::OUString sSwitched ( RTL_CONSTASCII_USTRINGPARAM( "Switched" ) ); - const rtl::OUString sPolar ( RTL_CONSTASCII_USTRINGPARAM( "Polar" ) ); - const rtl::OUString sRefX ( RTL_CONSTASCII_USTRINGPARAM( "RefX" ) ); - const rtl::OUString sRefY ( RTL_CONSTASCII_USTRINGPARAM( "RefY" ) ); - const rtl::OUString sRefAngle ( RTL_CONSTASCII_USTRINGPARAM( "RefAngle" ) ); - const rtl::OUString sRefR ( RTL_CONSTASCII_USTRINGPARAM( "RefR" ) ); - const rtl::OUString sRadiusRangeMinimum ( RTL_CONSTASCII_USTRINGPARAM( "RadiusRangeMinimum" ) ); - const rtl::OUString sRadiusRangeMaximum ( RTL_CONSTASCII_USTRINGPARAM( "RadiusRangeMaximum" ) ); - const rtl::OUString sRangeXMinimum ( RTL_CONSTASCII_USTRINGPARAM( "RangeXMinimum" ) ); - const rtl::OUString sRangeXMaximum ( RTL_CONSTASCII_USTRINGPARAM( "RangeXMaximum" ) ); - const rtl::OUString sRangeYMinimum ( RTL_CONSTASCII_USTRINGPARAM( "RangeYMinimum" ) ); - const rtl::OUString sRangeYMaximum ( RTL_CONSTASCII_USTRINGPARAM( "RangeYMaximum" ) ); - - if ( rPropVal.Name.equals( sPosition ) ) + const rtl::OUString sPosition ( "Position" ); + const rtl::OUString sMirroredX ( "MirroredX" ); + const rtl::OUString sMirroredY ( "MirroredY" ); + const rtl::OUString sSwitched ( "Switched" ); + const rtl::OUString sPolar ( "Polar" ); + const rtl::OUString sRefX ( "RefX" ); + const rtl::OUString sRefY ( "RefY" ); + const rtl::OUString sRefAngle ( "RefAngle" ); + const rtl::OUString sRefR ( "RefR" ); + const rtl::OUString sRadiusRangeMinimum ( "RadiusRangeMinimum" ); + const rtl::OUString sRadiusRangeMaximum ( "RadiusRangeMaximum" ); + const rtl::OUString sRangeXMinimum ( "RangeXMinimum" ); + const rtl::OUString sRangeXMaximum ( "RangeXMaximum" ); + const rtl::OUString sRangeYMinimum ( "RangeYMinimum" ); + const rtl::OUString sRangeYMaximum ( "RangeYMaximum" ); + + if ( rPropVal.Name == sPosition ) { if ( rPropVal.Value >>= rDestinationHandle.aPosition ) bRetValue = sal_True; } - else if ( rPropVal.Name.equals( sMirroredX ) ) + else if ( rPropVal.Name == sMirroredX ) { sal_Bool bMirroredX = sal_Bool(); if ( rPropVal.Value >>= bMirroredX ) @@ -476,7 +474,7 @@ sal_Bool EnhancedCustomShape2d::ConvertSequenceToEnhancedCustomShape2dHandle( rDestinationHandle.nFlags |= HANDLE_FLAGS_MIRRORED_X; } } - else if ( rPropVal.Name.equals( sMirroredY ) ) + else if ( rPropVal.Name == sMirroredY ) { sal_Bool bMirroredY = sal_Bool(); if ( rPropVal.Value >>= bMirroredY ) @@ -485,7 +483,7 @@ sal_Bool EnhancedCustomShape2d::ConvertSequenceToEnhancedCustomShape2dHandle( rDestinationHandle.nFlags |= HANDLE_FLAGS_MIRRORED_Y; } } - else if ( rPropVal.Name.equals( sSwitched ) ) + else if ( rPropVal.Name == sSwitched ) { sal_Bool bSwitched = sal_Bool(); if ( rPropVal.Value >>= bSwitched ) @@ -494,57 +492,57 @@ sal_Bool EnhancedCustomShape2d::ConvertSequenceToEnhancedCustomShape2dHandle( rDestinationHandle.nFlags |= HANDLE_FLAGS_SWITCHED; } } - else if ( rPropVal.Name.equals( sPolar ) ) + else if ( rPropVal.Name == sPolar ) { if ( rPropVal.Value >>= rDestinationHandle.aPolar ) rDestinationHandle.nFlags |= HANDLE_FLAGS_POLAR; } - else if ( rPropVal.Name.equals( sRefX ) ) + else if ( rPropVal.Name == sRefX ) { if ( rPropVal.Value >>= rDestinationHandle.nRefX ) rDestinationHandle.nFlags |= HANDLE_FLAGS_REFX; } - else if ( rPropVal.Name.equals( sRefY ) ) + else if ( rPropVal.Name == sRefY ) { if ( rPropVal.Value >>= rDestinationHandle.nRefY ) rDestinationHandle.nFlags |= HANDLE_FLAGS_REFY; } - else if ( rPropVal.Name.equals( sRefAngle ) ) + else if ( rPropVal.Name == sRefAngle ) { if ( rPropVal.Value >>= rDestinationHandle.nRefAngle ) rDestinationHandle.nFlags |= HANDLE_FLAGS_REFANGLE; } - else if ( rPropVal.Name.equals( sRefR ) ) + else if ( rPropVal.Name == sRefR ) { if ( rPropVal.Value >>= rDestinationHandle.nRefR ) rDestinationHandle.nFlags |= HANDLE_FLAGS_REFR; } - else if ( rPropVal.Name.equals( sRadiusRangeMinimum ) ) + else if ( rPropVal.Name == sRadiusRangeMinimum ) { if ( rPropVal.Value >>= rDestinationHandle.aRadiusRangeMinimum ) rDestinationHandle.nFlags |= HANDLE_FLAGS_RADIUS_RANGE_MINIMUM; } - else if ( rPropVal.Name.equals( sRadiusRangeMaximum ) ) + else if ( rPropVal.Name == sRadiusRangeMaximum ) { if ( rPropVal.Value >>= rDestinationHandle.aRadiusRangeMaximum ) rDestinationHandle.nFlags |= HANDLE_FLAGS_RADIUS_RANGE_MAXIMUM; } - else if ( rPropVal.Name.equals( sRangeXMinimum ) ) + else if ( rPropVal.Name == sRangeXMinimum ) { if ( rPropVal.Value >>= rDestinationHandle.aXRangeMinimum ) rDestinationHandle.nFlags |= HANDLE_FLAGS_RANGE_X_MINIMUM; } - else if ( rPropVal.Name.equals( sRangeXMaximum ) ) + else if ( rPropVal.Name == sRangeXMaximum ) { if ( rPropVal.Value >>= rDestinationHandle.aXRangeMaximum ) rDestinationHandle.nFlags |= HANDLE_FLAGS_RANGE_X_MAXIMUM; } - else if ( rPropVal.Name.equals( sRangeYMinimum ) ) + else if ( rPropVal.Name == sRangeYMinimum ) { if ( rPropVal.Value >>= rDestinationHandle.aYRangeMinimum ) rDestinationHandle.nFlags |= HANDLE_FLAGS_RANGE_Y_MINIMUM; } - else if ( rPropVal.Name.equals( sRangeYMaximum ) ) + else if ( rPropVal.Name == sRangeYMaximum ) { if ( rPropVal.Value >>= rDestinationHandle.aYRangeMaximum ) rDestinationHandle.nFlags |= HANDLE_FLAGS_RANGE_Y_MAXIMUM; @@ -564,7 +562,7 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha ////////////////////// // AdjustmentValues // ////////////////////// - const rtl::OUString sAdjustmentValues( RTL_CONSTASCII_USTRINGPARAM ( "AdjustmentValues" ) ); + const rtl::OUString sAdjustmentValues( "AdjustmentValues" ); const Any* pAny = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sAdjustmentValues ); if ( pAny ) *pAny >>= seqAdjustmentValues; @@ -572,7 +570,7 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha /////////////// // Coordsize // /////////////// - const rtl::OUString sViewBox( RTL_CONSTASCII_USTRINGPARAM ( "ViewBox" ) ); + const rtl::OUString sViewBox( "ViewBox" ); const Any* pViewBox = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sViewBox ); com::sun::star::awt::Rectangle aViewBox; if ( pViewBox && (*pViewBox >>= aViewBox ) ) @@ -582,12 +580,12 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha nCoordWidthG = labs( aViewBox.Width ); nCoordHeightG = labs( aViewBox.Height); } - const rtl::OUString sPath( RTL_CONSTASCII_USTRINGPARAM ( "Path" ) ); + const rtl::OUString sPath( "Path" ); ////////////////////// // Path/Coordinates // ////////////////////// - const rtl::OUString sCoordinates( RTL_CONSTASCII_USTRINGPARAM ( "Coordinates" ) ); + const rtl::OUString sCoordinates( "Coordinates" ); pAny = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sPath, sCoordinates ); if ( pAny ) *pAny >>= seqCoordinates; @@ -595,7 +593,7 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha ///////////////////// // Path/GluePoints // ///////////////////// - const rtl::OUString sGluePoints( RTL_CONSTASCII_USTRINGPARAM ( "GluePoints" ) ); + const rtl::OUString sGluePoints( "GluePoints" ); pAny = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sPath, sGluePoints ); if ( pAny ) *pAny >>= seqGluePoints; @@ -603,7 +601,7 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha /////////////////// // Path/Segments // /////////////////// - const rtl::OUString sSegments( RTL_CONSTASCII_USTRINGPARAM ( "Segments" ) ); + const rtl::OUString sSegments( "Segments" ); pAny = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sPath, sSegments ); if ( pAny ) *pAny >>= seqSegments; @@ -611,7 +609,7 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha ////////////////////// // Path/SubViewSize // ////////////////////// - const rtl::OUString sSubViewSize( RTL_CONSTASCII_USTRINGPARAM ( "SubViewSize" ) ); + const rtl::OUString sSubViewSize( "SubViewSize" ); pAny = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sPath, sSubViewSize ); if ( pAny ) *pAny >>= seqSubViewSize; @@ -619,7 +617,7 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha /////////////////// // Path/StretchX // /////////////////// - const rtl::OUString sStretchX( RTL_CONSTASCII_USTRINGPARAM ( "StretchX" ) ); + const rtl::OUString sStretchX( "StretchX" ); pAny = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sPath, sStretchX ); if ( pAny ) { @@ -631,7 +629,7 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha /////////////////// // Path/StretchY // /////////////////// - const rtl::OUString sStretchY( RTL_CONSTASCII_USTRINGPARAM ( "StretchY" ) ); + const rtl::OUString sStretchY( "StretchY" ); pAny = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sPath, sStretchY ); if ( pAny ) { @@ -643,7 +641,7 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha ///////////////////// // Path/TextFrames // ///////////////////// - const rtl::OUString sTextFrames( RTL_CONSTASCII_USTRINGPARAM ( "TextFrames" ) ); + const rtl::OUString sTextFrames( "TextFrames" ); pAny = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sPath, sTextFrames ); if ( pAny ) *pAny >>= seqTextFrames; @@ -651,7 +649,7 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha /////////////// // Equations // /////////////// - const rtl::OUString sEquations( RTL_CONSTASCII_USTRINGPARAM( "Equations" ) ); + const rtl::OUString sEquations( "Equations" ); pAny = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sEquations ); if ( pAny ) *pAny >>= seqEquations; @@ -659,7 +657,7 @@ const sal_Int32* EnhancedCustomShape2d::ApplyShapeAttributes( const SdrCustomSha ///////////// // Handles // ///////////// - const rtl::OUString sHandles( RTL_CONSTASCII_USTRINGPARAM( "Handles" ) ); + const rtl::OUString sHandles( "Handles" ); pAny = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( sHandles ); if ( pAny ) *pAny >>= seqHandles; @@ -763,9 +761,9 @@ EnhancedCustomShape2d::EnhancedCustomShape2d( SdrObject* pAObj ) : aP.Y() -= aS.Height() / 2; aLogicRect = Rectangle( aP, aS ); - const rtl::OUString sType( RTL_CONSTASCII_USTRINGPARAM ( "Type" ) ); - const rtl::OUString sMirroredX( RTL_CONSTASCII_USTRINGPARAM ( "MirroredX" ) ); - const rtl::OUString sMirroredY( RTL_CONSTASCII_USTRINGPARAM ( "MirroredY" ) ); + const rtl::OUString sType( "Type" ); + const rtl::OUString sMirroredX( "MirroredX" ); + const rtl::OUString sMirroredY( "MirroredY" ); rtl::OUString sShapeType; SdrCustomShapeGeometryItem& rGeometryItem = (SdrCustomShapeGeometryItem&)(const SdrCustomShapeGeometryItem&)pCustomShapeObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ); @@ -814,7 +812,7 @@ EnhancedCustomShape2d::EnhancedCustomShape2d( SdrObject* pAObj ) : case mso_sptNil : { if( sShapeType.getLength() > 4 && - sShapeType.matchAsciiL( RTL_CONSTASCII_STRINGPARAM( "col-" ))) + sShapeType.match( "col-" )) { nColorData = sShapeType.copy( 4 ).toInt32( 16 ); } @@ -1383,7 +1381,7 @@ sal_Bool EnhancedCustomShape2d::SetHandleControllerPosition( const sal_uInt32 nI // and writing them back into the GeometryItem SdrCustomShapeGeometryItem aGeometryItem((SdrCustomShapeGeometryItem&) (const SdrCustomShapeGeometryItem&)pCustomShapeObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )); - const rtl::OUString sAdjustmentValues( RTL_CONSTASCII_USTRINGPARAM ( "AdjustmentValues" ) ); + const rtl::OUString sAdjustmentValues( "AdjustmentValues" ); com::sun::star::beans::PropertyValue aPropVal; aPropVal.Name = sAdjustmentValues; aPropVal.Value <<= seqAdjustmentValues; @@ -1848,8 +1846,7 @@ void EnhancedCustomShape2d::CreateSubPath( sal_uInt16& rSrcPt, sal_uInt16& rSegm case UNKNOWN : default : { - rtl::OStringBuffer aString(RTL_CONSTASCII_STRINGPARAM( - "CustomShapes::unknown PolyFlagValue :")); + rtl::OStringBuffer aString("CustomShapes::unknown PolyFlagValue :"); aString.append(static_cast<sal_Int32>(nCommand)); OSL_FAIL(aString.getStr()); } diff --git a/svx/source/customshapes/EnhancedCustomShape3d.cxx b/svx/source/customshapes/EnhancedCustomShape3d.cxx index 664d1d96ac6f..aaff743b5220 100644 --- a/svx/source/customshapes/EnhancedCustomShape3d.cxx +++ b/svx/source/customshapes/EnhancedCustomShape3d.cxx @@ -60,7 +60,7 @@ const char aExtrusion[] = "Extrusion"; void GetOrigin( SdrCustomShapeGeometryItem& rItem, double& rOriginX, double& rOriginY ) { ::com::sun::star::drawing::EnhancedCustomShapeParameterPair aOriginParaPair; - const rtl::OUString sOrigin( RTL_CONSTASCII_USTRINGPARAM ( "Origin" ) ); + const rtl::OUString sOrigin( "Origin" ); Any* pAny = rItem.GetPropertyValueByName( rtl::OUString(aExtrusion), sOrigin ); if ( ! ( pAny && ( *pAny >>= aOriginParaPair ) && ( aOriginParaPair.First.Value >>= rOriginX ) && ( aOriginParaPair.Second.Value >>= rOriginY ) ) ) { @@ -72,7 +72,7 @@ void GetOrigin( SdrCustomShapeGeometryItem& rItem, double& rOriginX, double& rOr void GetRotateAngle( SdrCustomShapeGeometryItem& rItem, double& rAngleX, double& rAngleY ) { ::com::sun::star::drawing::EnhancedCustomShapeParameterPair aRotateAngleParaPair; - const rtl::OUString sRotateAngle( RTL_CONSTASCII_USTRINGPARAM ( "RotateAngle" ) ); + const rtl::OUString sRotateAngle( "RotateAngle" ); Any* pAny = rItem.GetPropertyValueByName( rtl::OUString(aExtrusion), sRotateAngle ); if ( ! ( pAny && ( *pAny >>= aRotateAngleParaPair ) && ( aRotateAngleParaPair.First.Value >>= rAngleX ) && ( aRotateAngleParaPair.Second.Value >>= rAngleY ) ) ) { @@ -86,7 +86,7 @@ void GetRotateAngle( SdrCustomShapeGeometryItem& rItem, double& rAngleX, double& void GetSkew( SdrCustomShapeGeometryItem& rItem, double& rSkewAmount, double& rSkewAngle ) { ::com::sun::star::drawing::EnhancedCustomShapeParameterPair aSkewParaPair; - const rtl::OUString sSkew( RTL_CONSTASCII_USTRINGPARAM ( "Skew" ) ); + const rtl::OUString sSkew( "Skew" ); Any* pAny = rItem.GetPropertyValueByName( rtl::OUString(aExtrusion), sSkew ); if ( ! ( pAny && ( *pAny >>= aSkewParaPair ) && ( aSkewParaPair.First.Value >>= rSkewAmount ) && ( aSkewParaPair.Second.Value >>= rSkewAngle ) ) ) { @@ -100,7 +100,7 @@ void GetExtrusionDepth( SdrCustomShapeGeometryItem& rItem, const double* pMap, d { ::com::sun::star::drawing::EnhancedCustomShapeParameterPair aDepthParaPair; double fDepth = 0, fFraction = 0; - const rtl::OUString sDepth( RTL_CONSTASCII_USTRINGPARAM ( "Depth" ) ); + const rtl::OUString sDepth( "Depth" ); Any* pAny = rItem.GetPropertyValueByName( rtl::OUString(aExtrusion), sDepth ); if ( pAny && ( *pAny >>= aDepthParaPair ) && ( aDepthParaPair.First.Value >>= fDepth ) && ( aDepthParaPair.Second.Value >>= fFraction ) ) { @@ -134,7 +134,7 @@ double GetDouble( SdrCustomShapeGeometryItem& rItem, const rtl::OUString& rPrope drawing::ShadeMode GetShadeMode( SdrCustomShapeGeometryItem& rItem, const drawing::ShadeMode eDefault ) { drawing::ShadeMode eRet( eDefault ); - const rtl::OUString sShadeMode( RTL_CONSTASCII_USTRINGPARAM ( "ShadeMode" ) ); + const rtl::OUString sShadeMode( "ShadeMode" ); Any* pAny = rItem.GetPropertyValueByName( rtl::OUString(aExtrusion), sShadeMode ); if ( pAny ) *pAny >>= eRet; @@ -199,7 +199,7 @@ EnhancedCustomShape3d::Transformation2D::Transformation2D( const SdrObject* pCus , pMap( pM ) { SdrCustomShapeGeometryItem& rGeometryItem = (SdrCustomShapeGeometryItem&)pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ); - const rtl::OUString sProjectionMode( RTL_CONSTASCII_USTRINGPARAM ( "ProjectionMode" ) ); + const rtl::OUString sProjectionMode( "ProjectionMode" ); Any* pAny = rGeometryItem.GetPropertyValueByName( rtl::OUString(aExtrusion), sProjectionMode ); if ( pAny ) *pAny >>= eProjectionMode; @@ -213,7 +213,7 @@ EnhancedCustomShape3d::Transformation2D::Transformation2D( const SdrObject* pCus fOriginX = fOriginX * pCustomShape->GetLogicRect().GetWidth(); fOriginY = fOriginY * pCustomShape->GetLogicRect().GetHeight(); - const rtl::OUString sViewPoint( RTL_CONSTASCII_USTRINGPARAM ( "ViewPoint" ) ); + const rtl::OUString sViewPoint( "ViewPoint" ); drawing::Position3D aViewPointDefault( 3472, -3472, 25000 ); drawing::Position3D aViewPoint( GetPosition3D( rGeometryItem, sViewPoint, aViewPointDefault, pMap ) ); fViewPoint.setX(aViewPoint.PositionX); @@ -330,7 +330,7 @@ SdrObject* EnhancedCustomShape3d::Create3DObject( const SdrObject* pShape2d, con fDepth = 1.0; drawing::ProjectionMode eProjectionMode( drawing::ProjectionMode_PARALLEL ); - const rtl::OUString sProjectionMode( RTL_CONSTASCII_USTRINGPARAM ( "ProjectionMode" ) ); + const rtl::OUString sProjectionMode( "ProjectionMode" ); Any* pAny = rGeometryItem.GetPropertyValueByName( aExtrusion, sProjectionMode ); if ( pAny ) *pAny >>= eProjectionMode; @@ -346,7 +346,7 @@ SdrObject* EnhancedCustomShape3d::Create3DObject( const SdrObject* pShape2d, con sal_Bool bUseTwoFillStyles( sal_False ); drawing::ShadeMode eShadeMode( GetShadeMode( rGeometryItem, drawing::ShadeMode_FLAT ) ); - const rtl::OUString aExtrusionColor( RTL_CONSTASCII_USTRINGPARAM ( "Color" ) ); + const rtl::OUString aExtrusionColor( "Color" ); sal_Bool bUseExtrusionColor = GetBool( rGeometryItem, aExtrusionColor, sal_False ); XFillStyle eFillStyle( ITEMVALUE( aSet, XATTR_FILLSTYLE, XFillStyleItem ) ); @@ -560,7 +560,7 @@ SdrObject* EnhancedCustomShape3d::Create3DObject( const SdrObject* pShape2d, con { aNewTransform.translate( -fOriginX, fOriginY, 0.0 ); // now set correct camera position - const rtl::OUString sViewPoint( RTL_CONSTASCII_USTRINGPARAM ( "ViewPoint" ) ); + const rtl::OUString sViewPoint( "ViewPoint" ); drawing::Position3D aViewPointDefault( 3472, -3472, 25000 ); drawing::Position3D aViewPoint( GetPosition3D( rGeometryItem, sViewPoint, aViewPointDefault, pMap ) ); double fViewPointX = aViewPoint.PositionX; @@ -578,33 +578,33 @@ SdrObject* EnhancedCustomShape3d::Create3DObject( const SdrObject* pShape2d, con // light // /////////// - const rtl::OUString sBrightness( RTL_CONSTASCII_USTRINGPARAM ( "Brightness" ) ); + const rtl::OUString sBrightness( "Brightness" ); double fAmbientIntensity = GetDouble( rGeometryItem, sBrightness, 22178.0 / 655.36, NULL ) / 100.0; - const rtl::OUString sFirstLightDirection( RTL_CONSTASCII_USTRINGPARAM ( "FirstLightDirection" ) ); + const rtl::OUString sFirstLightDirection( "FirstLightDirection" ); drawing::Direction3D aFirstLightDirectionDefault( 50000, 0, 10000 ); drawing::Direction3D aFirstLightDirection( GetDirection3D( rGeometryItem, sFirstLightDirection, aFirstLightDirectionDefault ) ); if ( aFirstLightDirection.DirectionZ == 0.0 ) aFirstLightDirection.DirectionZ = 1.0; - const rtl::OUString sFirstLightLevel( RTL_CONSTASCII_USTRINGPARAM ( "FirstLightLevel" ) ); + const rtl::OUString sFirstLightLevel( "FirstLightLevel" ); double fLightIntensity = GetDouble( rGeometryItem, sFirstLightLevel, 43712.0 / 655.36, NULL ) / 100.0; - const rtl::OUString sFirstLightHarsh( RTL_CONSTASCII_USTRINGPARAM ( "FirstLightHarsh" ) ); + const rtl::OUString sFirstLightHarsh( "FirstLightHarsh" ); /* sal_Bool bFirstLightHarsh = */ GetBool( rGeometryItem, sFirstLightHarsh, sal_False ); - const rtl::OUString sSecondLightDirection( RTL_CONSTASCII_USTRINGPARAM ( "SecondLightDirection" ) ); + const rtl::OUString sSecondLightDirection( "SecondLightDirection" ); drawing::Direction3D aSecondLightDirectionDefault( -50000, 0, 10000 ); drawing::Direction3D aSecondLightDirection( GetDirection3D( rGeometryItem, sSecondLightDirection, aSecondLightDirectionDefault ) ); if ( aSecondLightDirection.DirectionZ == 0.0 ) aSecondLightDirection.DirectionZ = -1; - const rtl::OUString sSecondLightLevel( RTL_CONSTASCII_USTRINGPARAM ( "SecondLightLevel" ) ); + const rtl::OUString sSecondLightLevel( "SecondLightLevel" ); double fLight2Intensity = GetDouble( rGeometryItem, sSecondLightLevel, 43712.0 / 655.36, NULL ) / 100.0; - const rtl::OUString sSecondLightHarsh( RTL_CONSTASCII_USTRINGPARAM ( "SecondLightHarsh" ) ); - const rtl::OUString sLightFace( RTL_CONSTASCII_USTRINGPARAM ( "LightFace" ) ); + const rtl::OUString sSecondLightHarsh( "SecondLightHarsh" ); + const rtl::OUString sLightFace( "LightFace" ); /* sal_Bool bLight2Harsh = */ GetBool( rGeometryItem, sSecondLightHarsh, sal_False ); /* sal_Bool bLightFace = */ GetBool( rGeometryItem, sLightFace, sal_False ); @@ -637,8 +637,8 @@ SdrObject* EnhancedCustomShape3d::Create3DObject( const SdrObject* pShape2d, con pScene->GetProperties().SetObjectItem( Svx3DLightcolor3Item( aAmbientSpot3Color ) ); pScene->GetProperties().SetObjectItem( Svx3DLightDirection3Item( aSpotLight3 ) ); - const rtl::OUString sSpecularity( RTL_CONSTASCII_USTRINGPARAM ( "Specularity" ) ); - const rtl::OUString sMetal( RTL_CONSTASCII_USTRINGPARAM ( "Metal" ) ); + const rtl::OUString sSpecularity( "Specularity" ); + const rtl::OUString sMetal( "Metal" ); double fSpecular = GetDouble( rGeometryItem, sSpecularity, 0, NULL ) / 100; sal_Bool bMetal = GetBool( rGeometryItem, sMetal, sal_False ); @@ -695,7 +695,7 @@ Rectangle EnhancedCustomShape3d::CalculateNewSnapRect( const SdrObject* pCustomS aBoundVolume.append(basegfx::B3DPoint(aPolygon[ (sal_uInt16)i ].X() - aCenter.X(), aPolygon[ (sal_uInt16)i ].Y() - aCenter.Y(), fExtrusionBackward)); } - const rtl::OUString sRotationCenter( RTL_CONSTASCII_USTRINGPARAM ( "RotationCenter" ) ); + const rtl::OUString sRotationCenter( "RotationCenter" ); drawing::Direction3D aRotationCenterDefault( 0, 0, 0 ); // default seems to be wrong, a fractional size of shape has to be used!! drawing::Direction3D aRotationCenter( GetDirection3D( rGeometryItem, sRotationCenter, aRotationCenterDefault ) ); diff --git a/svx/source/customshapes/EnhancedCustomShapeEngine.cxx b/svx/source/customshapes/EnhancedCustomShapeEngine.cxx index 7e599f241138..81c12a9851b7 100644 --- a/svx/source/customshapes/EnhancedCustomShapeEngine.cxx +++ b/svx/source/customshapes/EnhancedCustomShapeEngine.cxx @@ -50,7 +50,7 @@ rtl::OUString EnhancedCustomShapeEngine_getImplementationName() throw( NMSP_UNO::RuntimeException ) { - return B2UCONST( "com.sun.star.drawing.EnhancedCustomShapeEngine" ); + return OUString( "com.sun.star.drawing.EnhancedCustomShapeEngine" ); } sal_Bool SAL_CALL EnhancedCustomShapeEngine_supportsService( const rtl::OUString& ServiceName ) throw( NMSP_UNO::RuntimeException ) @@ -62,7 +62,7 @@ SEQ( rtl::OUString ) SAL_CALL EnhancedCustomShapeEngine_getSupportedServiceNames { SEQ( rtl::OUString ) aRet(1); rtl::OUString* pArray = aRet.getArray(); - pArray[0] = B2UCONST( "com.sun.star.drawing.CustomShapeEngine" ); + pArray[0] = "com.sun.star.drawing.CustomShapeEngine"; return aRet; } @@ -245,7 +245,7 @@ REF( com::sun::star::drawing::XShape ) SAL_CALL EnhancedCustomShapeEngine::rende SdrCustomShapeGeometryItem& rGeometryItem = (SdrCustomShapeGeometryItem&) pSdrObjCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ); sal_Bool bTextPathOn = sal_False; - const rtl::OUString sTextPath( RTL_CONSTASCII_USTRINGPARAM ( "TextPath" ) ); + const rtl::OUString sTextPath( "TextPath" ); com::sun::star::uno::Any* pAny = rGeometryItem.GetPropertyValueByName( sTextPath, sTextPath ); if ( pAny ) *pAny >>= bTextPathOn; diff --git a/svx/source/customshapes/EnhancedCustomShapeEngine.hxx b/svx/source/customshapes/EnhancedCustomShapeEngine.hxx index 44e67b7edf17..14a372108ae3 100644 --- a/svx/source/customshapes/EnhancedCustomShapeEngine.hxx +++ b/svx/source/customshapes/EnhancedCustomShapeEngine.hxx @@ -44,7 +44,6 @@ #define REF( _def_Obj ) NMSP_UNO::Reference< _def_Obj > #define SEQ( _def_Obj ) NMSP_UNO::Sequence< _def_Obj > -#define B2UCONST( _def_pChar ) (rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(_def_pChar ))) // --------------------------- // - EnhancedCustomShapeEngine - diff --git a/svx/source/customshapes/tbxcustomshapes.cxx b/svx/source/customshapes/tbxcustomshapes.cxx index 0f8a40946627..7a29065718da 100644 --- a/svx/source/customshapes/tbxcustomshapes.cxx +++ b/svx/source/customshapes/tbxcustomshapes.cxx @@ -37,7 +37,7 @@ SFX_IMPL_TOOLBOX_CONTROL(SvxTbxCtlCustomShapes, SfxBoolItem); SvxTbxCtlCustomShapes::SvxTbxCtlCustomShapes( sal_uInt16 nSlotId, sal_uInt16 nId, ToolBox& rTbx ) : SfxToolBoxControl( nSlotId, nId, rTbx ), - m_aSubTbxResName( RTL_CONSTASCII_USTRINGPARAM( "private:resource/toolbar/" ) ) + m_aSubTbxResName( "private:resource/toolbar/" ) { switch( nSlotId ) { @@ -47,40 +47,40 @@ SvxTbxCtlCustomShapes::SvxTbxCtlCustomShapes( sal_uInt16 nSlotId, sal_uInt16 nId } case SID_DRAWTBX_CS_BASIC : { - m_aCommand = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:BasicShapes.diamond" ) ); - m_aSubTbName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "basicshapes" ) ); + m_aCommand = ".uno:BasicShapes.diamond"; + m_aSubTbName = "basicshapes"; } break; case SID_DRAWTBX_CS_SYMBOL : { - m_aCommand = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:SymbolShapes.smiley" ) ); - m_aSubTbName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "symbolshapes" ) ); + m_aCommand = ".uno:SymbolShapes.smiley"; + m_aSubTbName = "symbolshapes"; } break; case SID_DRAWTBX_CS_ARROW : { - m_aCommand = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:ArrowShapes.left-right-arrow" ) ); - m_aSubTbName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "arrowshapes" ) ); + m_aCommand = ".uno:ArrowShapes.left-right-arrow"; + m_aSubTbName = "arrowshapes"; } break; case SID_DRAWTBX_CS_FLOWCHART : { - m_aCommand = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:FlowChartShapes.flowchart-internal-storage" ) ); - m_aSubTbName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "flowchartshapes" ) ); + m_aCommand = ".uno:FlowChartShapes.flowchart-internal-storage"; + m_aSubTbName = "flowchartshapes"; } break; case SID_DRAWTBX_CS_CALLOUT : { - m_aCommand = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:CalloutShapes.round-rectangular-callout" ) ); - m_aSubTbName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "calloutshapes" ) ); + m_aCommand = ".uno:CalloutShapes.round-rectangular-callout"; + m_aSubTbName = "calloutshapes"; } break; case SID_DRAWTBX_CS_STAR : { - m_aCommand = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:StarShapes.star5" ) ); - m_aSubTbName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "starshapes" ) ); + m_aCommand = ".uno:StarShapes.star5"; + m_aSubTbName = "starshapes"; } break; } diff --git a/svx/source/dialog/_bmpmask.cxx b/svx/source/dialog/_bmpmask.cxx index 34e9a951dffd..ac134b8282fd 100644 --- a/svx/source/dialog/_bmpmask.cxx +++ b/svx/source/dialog/_bmpmask.cxx @@ -1214,19 +1214,19 @@ void SvxBmpMask::SetAccessibleNames (void) String sSourceColorN; sSourceColorN = sSourceColor; - sSourceColorN.AppendAscii (RTL_CONSTASCII_STRINGPARAM (" 1")); + sSourceColorN.AppendAscii (" 1"); aCbx1.SetAccessibleName (sSourceColorN); sSourceColorN = sSourceColor; - sSourceColorN.AppendAscii (RTL_CONSTASCII_STRINGPARAM (" 2")); + sSourceColorN.AppendAscii (" 2"); aCbx2.SetAccessibleName (sSourceColorN); sSourceColorN = sSourceColor; - sSourceColorN.AppendAscii (RTL_CONSTASCII_STRINGPARAM (" 3")); + sSourceColorN.AppendAscii (" 3"); aCbx3.SetAccessibleName (sSourceColorN); sSourceColorN = sSourceColor; - sSourceColorN.AppendAscii (RTL_CONSTASCII_STRINGPARAM (" 4")); + sSourceColorN.AppendAscii (" 4"); aCbx4.SetAccessibleName (sSourceColorN); } diff --git a/svx/source/dialog/pfiledlg.cxx b/svx/source/dialog/pfiledlg.cxx index 4b1cd74261db..6c112e044728 100644 --- a/svx/source/dialog/pfiledlg.cxx +++ b/svx/source/dialog/pfiledlg.cxx @@ -130,9 +130,9 @@ SvxPluginFileDlg::SvxPluginFileDlg (Window *, sal_uInt16 nKind ) } // build filterdescription - aStrPlugName.AppendAscii( RTL_CONSTASCII_STRINGPARAM( " (" ) ); + aStrPlugName.AppendAscii( " (" ); aStrPlugName.Append( aStrPlugExtension ); - aStrPlugName.AppendAscii( RTL_CONSTASCII_STRINGPARAM( ")" ) ); + aStrPlugName.AppendAscii( ")" ); // use a own description for the video-formate avi, mov and mpeg // the descriptions of these MIME-types are not very meaningful diff --git a/svx/source/dialog/sendreportunx.cxx b/svx/source/dialog/sendreportunx.cxx index 0063cc1ef650..e0c581a0159f 100644 --- a/svx/source/dialog/sendreportunx.cxx +++ b/svx/source/dialog/sendreportunx.cxx @@ -201,7 +201,7 @@ namespace svx{ bool ErrorRepSendDialog::SendReport() { - rtl::OUString sSubEnvVar(RTL_CONSTASCII_USTRINGPARAM("ERRORREPORT_SUBJECT")); + rtl::OUString sSubEnvVar("ERRORREPORT_SUBJECT"); rtl::OUString strSubject(GetDocType()); osl_setEnvironment(sSubEnvVar.pData, strSubject.pData); @@ -216,16 +216,14 @@ namespace svx{ OSL_VERIFY(nWritten == static_cast<size_t>(strUTF8.getLength())); fclose( fp ); - rtl::OUString sBodyEnvVar(RTL_CONSTASCII_USTRINGPARAM("ERRORREPORT_BODYFILE")); + rtl::OUString sBodyEnvVar("ERRORREPORT_BODYFILE"); rtl::OUString strBodyFile(rtl::OStringToOUString(rtl::OString(szBodyFile), osl_getThreadTextEncoding())); osl_setEnvironment(sBodyEnvVar.pData, strBodyFile.pData); } int ret = -1; - rtl::OUString path1( - RTL_CONSTASCII_USTRINGPARAM( - "$BRAND_BASE_DIR/program/crashrep")); + rtl::OUString path1("$BRAND_BASE_DIR/program/crashrep"); rtl::Bootstrap::expandMacros(path1); rtl::OString path2; if ((osl::FileBase::getSystemPathFromFileURL(path1, path1) == @@ -237,7 +235,7 @@ namespace svx{ { rtl::OStringBuffer cmd; tools::appendUnixShellWord(&cmd, path2); - cmd.append(RTL_CONSTASCII_STRINGPARAM(" -debug -load -send -noui")); + cmd.append(" -debug -load -send -noui"); ret = system(cmd.getStr()); } diff --git a/svx/source/dialog/srchdlg.cxx b/svx/source/dialog/srchdlg.cxx index 0371a66bd1f3..6b29f4d76dc4 100644 --- a/svx/source/dialog/srchdlg.cxx +++ b/svx/source/dialog/srchdlg.cxx @@ -2248,7 +2248,7 @@ String& SvxSearchDialog::BuildAttrText_Impl( String& rStr, const SearchAttrItem& rItem = pList->GetObject(i); if ( rStr.Len() ) - rStr.AppendAscii( RTL_CONSTASCII_STRINGPARAM( ", " ) ); + rStr.AppendAscii( ", " ); if ( !IsInvalidItem( rItem.pItem ) ) { diff --git a/svx/source/dialog/svxbmpnumvalueset.cxx b/svx/source/dialog/svxbmpnumvalueset.cxx index 42179ab528e9..38cdd3a7e5c2 100644 --- a/svx/source/dialog/svxbmpnumvalueset.cxx +++ b/svx/source/dialog/svxbmpnumvalueset.cxx @@ -304,9 +304,9 @@ void SvxNumValueSet::UserDraw( const UserDrawEvent& rUDEvt ) } Sequence< PropertyValue > aProperties(2); PropertyValue* pProperties = aProperties.getArray(); - pProperties[0].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("NumberingType")); + pProperties[0].Name = rtl::OUString("NumberingType"); pProperties[0].Value <<= aNumberingTypes[i]; - pProperties[1].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Value")); + pProperties[1].Name = rtl::OUString("Value"); pProperties[1].Value <<= (sal_Int32)1; try { @@ -319,7 +319,7 @@ void SvxNumValueSet::UserDraw( const UserDrawEvent& rUDEvt ) aLeft.Y() -= (pDev->GetTextHeight()/2); if(!sPrefixes[i].isEmpty() && - !sPrefixes[i].equalsAsciiL(" ", 1) && + sPrefixes[i] != " " && sPrefixes[i].getStr()[0] != 0) { pVDev->SetFont(aFont); |