diff options
author | Noel Grandin <noel@peralex.com> | 2013-11-20 10:05:20 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2013-11-20 10:07:32 +0200 |
commit | 1730df0127ff230cf6c89f4815f5b59c8603fa2b (patch) | |
tree | 4d5b32ea155c173fe3cfd905bb148e0998286d9a | |
parent | 52bbd9cc00b5a1e15e4f96b5c5fa5e75855692c1 (diff) |
remove unnecessary RTL_CONSTASCII_STRINGPARAM in OString::append
Convert code like:
aOStringBuf.append( RTL_CONSTASCII_STRINGPARAM( " is missing )") );
to:
aOStringBuf.append( " is missing )" );
which compiles down to the same code.
Change-Id: I3d8ed0cbf96a881686524a167412d5f303c06b71
35 files changed, 268 insertions, 310 deletions
diff --git a/connectivity/source/drivers/postgresql/pq_statement.cxx b/connectivity/source/drivers/postgresql/pq_statement.cxx index 47697d1990f5..91272046b727 100644 --- a/connectivity/source/drivers/postgresql/pq_statement.cxx +++ b/connectivity/source/drivers/postgresql/pq_statement.cxx @@ -564,50 +564,42 @@ bool executePostgresCommand( const OString & cmd, struct CommandData *data ) else if( ! table.getLength() ) { OStringBuffer buf( 128 ); - buf.append( - RTL_CONSTASCII_STRINGPARAM( - "can't support updateable resultset, because a single table in the " - "WHERE part of the statement could not be identified (" ) ); + buf.append( "can't support updateable resultset, because a single table in the " + "WHERE part of the statement could not be identified (" ); buf.append( cmd ); - buf.append( RTL_CONSTASCII_STRINGPARAM( "." ) ); + buf.append( "." ); aReason = buf.makeStringAndClear(); } else if( sourceTableKeys.getLength() ) { OStringBuffer buf( 128 ); - buf.append( - RTL_CONSTASCII_STRINGPARAM( - "can't support updateable resultset for table " ) ); + buf.append( "can't support updateable resultset for table " ); buf.append( OUStringToOString( schema, pSettings->encoding ) ); - buf.append( RTL_CONSTASCII_STRINGPARAM( "." ) ); + buf.append( "." ); buf.append( OUStringToOString( table, pSettings->encoding ) ); - buf.append( RTL_CONSTASCII_STRINGPARAM( ", because resultset does not contain a part of the primary key ( column " ) ); + buf.append( ", because resultset does not contain a part of the primary key ( column " ); buf.append( OUStringToOString( sourceTableKeys[i], pSettings->encoding ) ); - buf.append( RTL_CONSTASCII_STRINGPARAM( " is missing )") ); + buf.append( " is missing )" ); aReason = buf.makeStringAndClear(); } else { OStringBuffer buf( 128 ); - buf.append( - RTL_CONSTASCII_STRINGPARAM( - "can't support updateable resultset for table " ) ); + buf.append( "can't support updateable resultset for table " ); buf.append( OUStringToOString( schema, pSettings->encoding ) ); - buf.append( RTL_CONSTASCII_STRINGPARAM( "." ) ); + buf.append( "." ); buf.append( OUStringToOString( table, pSettings->encoding ) ); - buf.append( RTL_CONSTASCII_STRINGPARAM( ", because resultset table does not have a primary key " ) ); + buf.append( ", because resultset table does not have a primary key " ); aReason = buf.makeStringAndClear(); } } else { OStringBuffer buf( 128 ); - buf.append( - RTL_CONSTASCII_STRINGPARAM( - "can't support updateable result for selects with multiple tables (" ) ); + buf.append( "can't support updateable result for selects with multiple tables (" ); buf.append( cmd ); - buf.append( RTL_CONSTASCII_STRINGPARAM( ")" ) ); + buf.append( ")" ); log( pSettings, LogLevel::SQL, buf.makeStringAndClear().getStr() ); } if( ! (*(data->pLastResultset)).is() ) @@ -644,14 +636,14 @@ bool executePostgresCommand( const OString & cmd, struct CommandData *data ) if( isLog( pSettings, LogLevel::SQL ) ) { OStringBuffer buf( 128 ); - buf.append( RTL_CONSTASCII_STRINGPARAM("executed query '") ); + buf.append( "executed query '" ); buf.append( cmd ); - buf.append( RTL_CONSTASCII_STRINGPARAM("' successfully") ); - buf.append( RTL_CONSTASCII_STRINGPARAM(", duration=") ); + buf.append( "' successfully" ); + buf.append( ", duration=" ); buf.append( duration ); - buf.append( RTL_CONSTASCII_STRINGPARAM("ms, returnedRows=") ); + buf.append( "ms, returnedRows=" ); buf.append( returnedRows ); - buf.append( RTL_CONSTASCII_STRINGPARAM("." ) ); + buf.append( "." ); log( pSettings, LogLevel::SQL, buf.makeStringAndClear().getStr() ); } break; diff --git a/cui/source/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx index 4f1cca75502c..5f5c69ec1306 100644 --- a/cui/source/tabpages/autocdlg.cxx +++ b/cui/source/tabpages/autocdlg.cxx @@ -2279,7 +2279,7 @@ void OfaAutoCompleteTabPage::CopyToClipboard() const { sData.append(OUStringToOString(aLBEntries.GetSelectEntry(n), nEncode)); - sData.append(RTL_CONSTASCII_STRINGPARAM(aLineEnd)); + sData.append(aLineEnd); } pCntnr->CopyByteString( SOT_FORMAT_STRING, sData.makeStringAndClear() ); pCntnr->CopyToClipboard( (Window*)this ); diff --git a/editeng/source/editeng/editdbg.cxx b/editeng/source/editeng/editdbg.cxx index d2506990dadf..ed1ca6e4c31c 100644 --- a/editeng/source/editeng/editdbg.cxx +++ b/editeng/source/editeng/editdbg.cxx @@ -64,23 +64,23 @@ OString DbgOutItem(const SfxItemPool& rPool, const SfxPoolItem& rItem) switch ( rItem.Which() ) { case EE_PARA_WRITINGDIR: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("WritingDir=")); + aDebStr.append("WritingDir="); aDebStr.append(static_cast<sal_Int32>(((SvxFrameDirectionItem&)rItem).GetValue())); break; case EE_PARA_OUTLLRSPACE: case EE_PARA_LRSPACE: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("FI=")); + aDebStr.append("FI="); aDebStr.append(static_cast<sal_Int32>(((SvxLRSpaceItem&)rItem).GetTxtFirstLineOfst())); - aDebStr.append(RTL_CONSTASCII_STRINGPARAM(", LI=")); + aDebStr.append(", LI="); aDebStr.append(static_cast<sal_Int32>(((SvxLRSpaceItem&)rItem).GetTxtLeft())); - aDebStr.append(RTL_CONSTASCII_STRINGPARAM(", RI=")); + aDebStr.append(", RI="); aDebStr.append(static_cast<sal_Int32>(((SvxLRSpaceItem&)rItem).GetRight())); break; case EE_PARA_NUMBULLET: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("NumItem ")); + aDebStr.append("NumItem "); for ( sal_uInt16 nLevel = 0; nLevel < 3; nLevel++ ) { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Level")); + aDebStr.append("Level"); aDebStr.append(static_cast<sal_Int32>(nLevel)); aDebStr.append('='); const SvxNumberFormat* pFmt = ((const SvxNumBulletItem&)rItem).GetNumRule()->Get( nLevel ); @@ -92,64 +92,64 @@ OString DbgOutItem(const SfxItemPool& rPool, const SfxPoolItem& rItem) aDebStr.append(static_cast<sal_Int32>(pFmt->GetAbsLSpace())); aDebStr.append(','); if ( pFmt->GetNumberingType() == SVX_NUM_BITMAP ) - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Bitmap")); + aDebStr.append("Bitmap"); else if( pFmt->GetNumberingType() != SVX_NUM_CHAR_SPECIAL ) - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Number")); + aDebStr.append("Number"); else { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Char=[")); + aDebStr.append("Char=["); aDebStr.append(static_cast<sal_Int32>(pFmt->GetBulletChar())); aDebStr.append(']'); } - aDebStr.append(RTL_CONSTASCII_STRINGPARAM(") ")); + aDebStr.append(") "); } } break; case EE_PARA_BULLETSTATE: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("ShowBullet=")); + aDebStr.append("ShowBullet="); aDebStr.append(static_cast<sal_Int32>(((SfxBoolItem&)rItem).GetValue())); break; case EE_PARA_HYPHENATE: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Hyphenate=")); + aDebStr.append("Hyphenate="); aDebStr.append(static_cast<sal_Int32>(((SfxBoolItem&)rItem).GetValue())); break; case EE_PARA_OUTLLEVEL: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Level=")); + aDebStr.append("Level="); aDebStr.append(static_cast<sal_Int32>(((SfxInt16Item&)rItem).GetValue())); break; case EE_PARA_ULSPACE: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("SB=")); + aDebStr.append("SB="); aDebStr.append(static_cast<sal_Int32>(((SvxULSpaceItem&)rItem).GetUpper())); - aDebStr.append(RTL_CONSTASCII_STRINGPARAM(", SA=")); + aDebStr.append(", SA="); aDebStr.append(static_cast<sal_Int32>(((SvxULSpaceItem&)rItem).GetLower())); break; case EE_PARA_SBL: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("SBL=")); + aDebStr.append("SBL="); if ( ((SvxLineSpacingItem&)rItem).GetLineSpaceRule() == SVX_LINE_SPACE_MIN ) { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Min: ")); + aDebStr.append("Min: "); aDebStr.append(static_cast<sal_Int32>(((SvxLineSpacingItem&)rItem).GetInterLineSpace())); } else if ( ((SvxLineSpacingItem&)rItem).GetInterLineSpaceRule() == SVX_INTER_LINE_SPACE_PROP ) { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Prop: ")); + aDebStr.append("Prop: "); aDebStr.append(static_cast<sal_Int32>(((SvxLineSpacingItem&)rItem).GetPropLineSpace())); } else - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Unsupported Type!")); + aDebStr.append("Unsupported Type!"); break; case EE_PARA_JUST: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("SvxAdust=")); + aDebStr.append("SvxAdust="); aDebStr.append(static_cast<sal_Int32>(((SvxAdjustItem&)rItem).GetAdjust())); break; case EE_PARA_TABS: { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Tabs: ")); + aDebStr.append("Tabs: "); const SvxTabStopItem& rTabs = (const SvxTabStopItem&) rItem; aDebStr.append(static_cast<sal_Int32>(rTabs.Count())); if ( rTabs.Count() ) { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("( ")); + aDebStr.append("( "); for (sal_uInt16 i = 0; i < rTabs.Count(); ++i) { const SvxTabStop& rTab = rTabs[i]; @@ -163,17 +163,17 @@ OString DbgOutItem(const SfxItemPool& rPool, const SfxPoolItem& rItem) case EE_CHAR_LANGUAGE: case EE_CHAR_LANGUAGE_CJK: case EE_CHAR_LANGUAGE_CTL: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Language=")); + aDebStr.append("Language="); aDebStr.append(static_cast<sal_Int32>(((SvxLanguageItem&)rItem).GetLanguage())); break; case EE_CHAR_COLOR: { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Color= ")); + aDebStr.append("Color= "); Color aColor( ((SvxColorItem&)rItem).GetValue() ); aDebStr.append(static_cast<sal_Int32>(aColor.GetRed())); - aDebStr.append(RTL_CONSTASCII_STRINGPARAM(", ")); + aDebStr.append(", "); aDebStr.append(static_cast<sal_Int32>(aColor.GetGreen())); - aDebStr.append(RTL_CONSTASCII_STRINGPARAM(", ")); + aDebStr.append(", "); aDebStr.append(static_cast<sal_Int32>(aColor.GetBlue())); } break; @@ -181,9 +181,9 @@ OString DbgOutItem(const SfxItemPool& rPool, const SfxPoolItem& rItem) case EE_CHAR_FONTINFO_CJK: case EE_CHAR_FONTINFO_CTL: { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Font=")); + aDebStr.append("Font="); aDebStr.append(OUStringToOString(((SvxFontItem&)rItem).GetFamilyName(), RTL_TEXTENCODING_ASCII_US)); - aDebStr.append(RTL_CONSTASCII_STRINGPARAM(" (CharSet: ")); + aDebStr.append(" (CharSet: "); aDebStr.append(static_cast<sal_Int32>(((SvxFontItem&)rItem).GetCharSet())); aDebStr.append(')'); } @@ -192,20 +192,20 @@ OString DbgOutItem(const SfxItemPool& rPool, const SfxPoolItem& rItem) case EE_CHAR_FONTHEIGHT_CJK: case EE_CHAR_FONTHEIGHT_CTL: { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Groesse=")); + aDebStr.append("Groesse="); aDebStr.append(static_cast<sal_Int32>(((SvxFontHeightItem&)rItem).GetHeight())); Size aSz( 0, ((SvxFontHeightItem&)rItem).GetHeight() ); SfxMapUnit eUnit = rPool.GetMetric( rItem.Which() ); MapMode aItemMapMode( (MapUnit) eUnit ); MapMode aPntMap( MAP_POINT ); aSz = OutputDevice::LogicToLogic( aSz, aItemMapMode, aPntMap ); - aDebStr.append(RTL_CONSTASCII_STRINGPARAM(" Points=")); + aDebStr.append(" Points="); aDebStr.append(static_cast<sal_Int32>(aSz.Height())); } break; case EE_CHAR_FONTWIDTH: { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Breite=")); + aDebStr.append("Breite="); aDebStr.append(static_cast<sal_Int32>(((SvxCharScaleWidthItem&)rItem).GetValue())); aDebStr.append('%'); } @@ -213,72 +213,72 @@ OString DbgOutItem(const SfxItemPool& rPool, const SfxPoolItem& rItem) case EE_CHAR_WEIGHT: case EE_CHAR_WEIGHT_CJK: case EE_CHAR_WEIGHT_CTL: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("FontWeight=")); + aDebStr.append("FontWeight="); aDebStr.append(static_cast<sal_Int32>(((SvxWeightItem&)rItem).GetWeight())); break; case EE_CHAR_UNDERLINE: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("FontUnderline=")); + aDebStr.append("FontUnderline="); aDebStr.append(static_cast<sal_Int32>(((SvxUnderlineItem&)rItem).GetLineStyle())); break; case EE_CHAR_OVERLINE: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("FontOverline=")); + aDebStr.append("FontOverline="); aDebStr.append(static_cast<sal_Int32>(((SvxOverlineItem&)rItem).GetLineStyle())); break; case EE_CHAR_EMPHASISMARK: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("FontUnderline=")); + aDebStr.append("FontUnderline="); aDebStr.append(static_cast<sal_Int32>(((SvxEmphasisMarkItem&)rItem).GetEmphasisMark())); break; case EE_CHAR_RELIEF: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("FontRelief=")); + aDebStr.append("FontRelief="); aDebStr.append(static_cast<sal_Int32>(((SvxCharReliefItem&)rItem).GetValue())); break; case EE_CHAR_STRIKEOUT: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("FontStrikeout=")); + aDebStr.append("FontStrikeout="); aDebStr.append(static_cast<sal_Int32>(((SvxCrossedOutItem&)rItem).GetStrikeout())); break; case EE_CHAR_ITALIC: case EE_CHAR_ITALIC_CJK: case EE_CHAR_ITALIC_CTL: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("FontPosture=")); + aDebStr.append("FontPosture="); aDebStr.append(static_cast<sal_Int32>(((SvxPostureItem&)rItem).GetPosture())); break; case EE_CHAR_OUTLINE: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("FontOutline=")); + aDebStr.append("FontOutline="); aDebStr.append(static_cast<sal_Int32>(((SvxContourItem&)rItem).GetValue())); break; case EE_CHAR_SHADOW: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("FontShadowed=")); + aDebStr.append("FontShadowed="); aDebStr.append(static_cast<sal_Int32>(((SvxShadowedItem&)rItem).GetValue())); break; case EE_CHAR_ESCAPEMENT: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Escape=")); + aDebStr.append("Escape="); aDebStr.append(static_cast<sal_Int32>(((SvxEscapementItem&)rItem).GetEsc())); - aDebStr.append(RTL_CONSTASCII_STRINGPARAM(", ")); + aDebStr.append(", "); aDebStr.append(static_cast<sal_Int32>(((SvxEscapementItem&)rItem).GetProp())); break; case EE_CHAR_PAIRKERNING: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("PairKerning=")); + aDebStr.append("PairKerning="); aDebStr.append(static_cast<sal_Int32>(((SvxAutoKernItem&)rItem).GetValue())); break; case EE_CHAR_KERNING: { - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("Kerning=")); + aDebStr.append("Kerning="); aDebStr.append(static_cast<sal_Int32>(((SvxKerningItem&)rItem).GetValue())); Size aSz( 0, (short)((SvxKerningItem&)rItem).GetValue() ); SfxMapUnit eUnit = rPool.GetMetric( rItem.Which() ); MapMode aItemMapMode( (MapUnit) eUnit ); MapMode aPntMap( MAP_POINT ); aSz = OutputDevice::LogicToLogic( aSz, aItemMapMode, aPntMap ); - aDebStr.append(RTL_CONSTASCII_STRINGPARAM(" Points=")); + aDebStr.append(" Points="); aDebStr.append(static_cast<sal_Int32>(aSz.Height())); } break; case EE_CHAR_WLM: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("WordLineMode=")); + aDebStr.append("WordLineMode="); aDebStr.append(static_cast<sal_Int32>(((SvxWordLineModeItem&)rItem).GetValue())); break; case EE_CHAR_XMLATTRIBS: - aDebStr.append(RTL_CONSTASCII_STRINGPARAM("XMLAttribs=...")); + aDebStr.append("XMLAttribs=..."); break; } return aDebStr.makeStringAndClear(); @@ -343,9 +343,9 @@ void EditDbg::ShowEditEngineData( EditEngine* pEE, sal_Bool bInfoBox ) { const EditCharAttrib& rAttr = pPPortion->GetNode()->GetCharAttribs().GetAttribs()[z]; OStringBuffer aCharAttribs; - aCharAttribs.append(RTL_CONSTASCII_STRINGPARAM("\nA")); + aCharAttribs.append("\nA"); aCharAttribs.append(static_cast<sal_Int32>(nPortion)); - aCharAttribs.append(RTL_CONSTASCII_STRINGPARAM(": ")); + aCharAttribs.append(": "); aCharAttribs.append(static_cast<sal_Int32>(rAttr.GetItem()->Which())); aCharAttribs.append('\t'); aCharAttribs.append(static_cast<sal_Int32>(rAttr.GetStart())); @@ -362,17 +362,15 @@ void EditDbg::ShowEditEngineData( EditEngine* pEE, sal_Bool bInfoBox ) fprintf( fp, "\nNULL-Attribute!" ); sal_uInt16 nTextPortions = pPPortion->GetTextPortions().Count(); - OStringBuffer aPortionStr( - RTL_CONSTASCII_STRINGPARAM("\nText portions: #")); + OStringBuffer aPortionStr("\nText portions: #"); aPortionStr.append(static_cast<sal_Int32>(nTextPortions)); - aPortionStr.append(RTL_CONSTASCII_STRINGPARAM(" \nA")); + aPortionStr.append(" \nA"); aPortionStr.append(static_cast<sal_Int32>(nPortion)); - aPortionStr.append( - RTL_CONSTASCII_STRINGPARAM(": Paragraph Length = ")); + aPortionStr.append(": Paragraph Length = "); aPortionStr.append(static_cast<sal_Int32>(pPPortion->GetNode()->Len())); - aPortionStr.append(RTL_CONSTASCII_STRINGPARAM("\nA")); + aPortionStr.append("\nA"); aPortionStr.append(static_cast<sal_Int32>(nPortion)); - aPortionStr.append(RTL_CONSTASCII_STRINGPARAM(": ")); + aPortionStr.append(": "); sal_uLong n = 0; for ( z = 0; z < nTextPortions; z++ ) { @@ -388,12 +386,12 @@ void EditDbg::ShowEditEngineData( EditEngine* pEE, sal_Bool bInfoBox ) aPortionStr.append(';'); n += pPortion->GetLen(); } - aPortionStr.append(RTL_CONSTASCII_STRINGPARAM("\nA")); + aPortionStr.append("\nA"); aPortionStr.append(static_cast<sal_Int32>(nPortion)); - aPortionStr.append(RTL_CONSTASCII_STRINGPARAM(": Total length: ")); + aPortionStr.append(": Total length: "); aPortionStr.append(static_cast<sal_Int32>(n)); if ( pPPortion->GetNode()->Len() != n ) - aPortionStr.append(RTL_CONSTASCII_STRINGPARAM(" => Error !!!")); + aPortionStr.append(" => Error !!!"); fprintf(fp, "%s", aPortionStr.getStr()); fprintf( fp, "\n\nLines:" ); diff --git a/framework/source/layoutmanager/layoutmanager.cxx b/framework/source/layoutmanager/layoutmanager.cxx index e52f4ed4c4b3..309ab5bee73e 100644 --- a/framework/source/layoutmanager/layoutmanager.cxx +++ b/framework/source/layoutmanager/layoutmanager.cxx @@ -2250,9 +2250,9 @@ throw (RuntimeException) SAL_INFO( "fwk", "framework (cd100003) ::LayoutManager::lock lockCount=" << nLockCount ); #ifdef DBG_UTIL - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM("LayoutManager::lock ")); + OStringBuffer aStr("LayoutManager::lock "); aStr.append(reinterpret_cast<sal_Int64>(this)); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" - ")); + aStr.append(" - "); aStr.append(nLockCount); SAL_INFO( "fwk", "" << aStr.getStr()); #endif @@ -2272,9 +2272,9 @@ throw (RuntimeException) SAL_INFO( "fwk", "framework (cd100003) ::LayoutManager::unlock lockCount=" << nLockCount ); #ifdef DBG_UTIL - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM("LayoutManager::unlock ")); + OStringBuffer aStr("LayoutManager::unlock "); aStr.append(reinterpret_cast<sal_Int64>(this)); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" - ")); + aStr.append(" - "); aStr.append(nLockCount); SAL_INFO( "fwk", "" << aStr.getStr()); #endif diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx b/i18npool/qa/cppunit/test_breakiterator.cxx index 7e99614d2f49..6777731270df 100644 --- a/i18npool/qa/cppunit/test_breakiterator.cxx +++ b/i18npool/qa/cppunit/test_breakiterator.cxx @@ -740,9 +740,9 @@ void TestBreakIterator::testWeak() { sal_Int16 nScript = m_xBreak->getScriptType(aWeaks, i); OStringBuffer aMsg; - aMsg.append(RTL_CONSTASCII_STRINGPARAM("Char 0x")); + aMsg.append("Char 0x"); aMsg.append(static_cast<sal_Int32>(aWeaks[i]), 16); - aMsg.append(RTL_CONSTASCII_STRINGPARAM(" should have been weak")); + aMsg.append(" should have been weak"); CPPUNIT_ASSERT_MESSAGE(aMsg.getStr(), nScript == i18n::ScriptType::WEAK); } @@ -779,9 +779,9 @@ void TestBreakIterator::testAsian() { sal_Int16 nScript = m_xBreak->getScriptType(aAsians, i); OStringBuffer aMsg; - aMsg.append(RTL_CONSTASCII_STRINGPARAM("Char 0x")); + aMsg.append("Char 0x"); aMsg.append(static_cast<sal_Int32>(aAsians[i]), 16); - aMsg.append(RTL_CONSTASCII_STRINGPARAM(" should have been asian")); + aMsg.append(" should have been asian"); CPPUNIT_ASSERT_MESSAGE(aMsg.getStr(), nScript == i18n::ScriptType::ASIAN); } diff --git a/idl/source/objects/bastype.cxx b/idl/source/objects/bastype.cxx index 5678a6500643..171c32cc78ce 100644 --- a/idl/source/objects/bastype.cxx +++ b/idl/source/objects/bastype.cxx @@ -172,7 +172,7 @@ OString SvBOOL::GetSvIdlString( SvStringHashEntry * pName ) return pName->GetName(); return OStringBuffer(pName->GetName()). - append(RTL_CONSTASCII_STRINGPARAM("(FALSE)")). + append("(FALSE)"). makeStringAndClear(); } @@ -239,9 +239,8 @@ sal_Bool SvNumberIdentifier::ReadSvIdl( SvIdlDataBase & rBase, } else { - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "no value for identifier <")); - aStr.append(getString()).append(RTL_CONSTASCII_STRINGPARAM("> ")); + OStringBuffer aStr("no value for identifier <"); + aStr.append(getString()).append("> "); rBase.SetError( aStr.makeStringAndClear(), rInStm.GetToken() ); rBase.WriteError( rInStm ); } @@ -266,9 +265,8 @@ sal_Bool SvNumberIdentifier::ReadSvIdl( SvIdlDataBase & rBase, } else { - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "no value for identifier <")); - aStr.append(getString()).append(RTL_CONSTASCII_STRINGPARAM("> ")); + OStringBuffer aStr("no value for identifier <"); + aStr.append(getString()).append("> "); rBase.SetError( aStr.makeStringAndClear(), rInStm.GetToken() ); rBase.WriteError( rInStm ); } diff --git a/idl/source/objects/object.cxx b/idl/source/objects/object.cxx index e265af7255db..d826561fd838 100644 --- a/idl/source/objects/object.cxx +++ b/idl/source/objects/object.cxx @@ -329,9 +329,9 @@ sal_Bool SvMetaClass::TestAttribute( SvIdlDataBase & rBase, SvTokenStream & rInS OSL_FAIL( pS->GetSlotId().getString().getStr() ); OSL_FAIL( rAttr.GetSlotId().getString().getStr() ); - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM("Attribute's ")); + OStringBuffer aStr("Attribute's "); aStr.append(pS->GetName().getString()); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" with different id's")); + aStr.append(" with different id's"); rBase.SetError(aStr.makeStringAndClear(), rInStm.GetToken()); rBase.WriteError( rInStm ); return sal_False; @@ -348,11 +348,11 @@ sal_Bool SvMetaClass::TestAttribute( SvIdlDataBase & rBase, SvTokenStream & rInS OSL_FAIL( pS->GetSlotId().getString().getStr() ); OSL_FAIL( rAttr.GetSlotId().getString().getStr() ); - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM("Attribute ")); + OStringBuffer aStr("Attribute "); aStr.append(pS->GetName().getString()); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" and Attribute ")); + aStr.append(" and Attribute "); aStr.append(rAttr.GetName().getString()); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" with equal id's")); + aStr.append(" with equal id's"); rBase.SetError(aStr.makeStringAndClear(), rInStm.GetToken()); rBase.WriteError( rInStm ); return sal_False; diff --git a/idl/source/objects/types.cxx b/idl/source/objects/types.cxx index 5bdd292e9178..15b835f9f67e 100644 --- a/idl/source/objects/types.cxx +++ b/idl/source/objects/types.cxx @@ -871,7 +871,7 @@ void SvMetaType::SetType( int nT ) else if( nType == TYPE_CLASS ) { OStringBuffer aTmp(C_PREF); - aTmp.append(RTL_CONSTASCII_STRINGPARAM("Object *")); + aTmp.append("Object *"); aCName.setString(aTmp.makeStringAndClear()); } } @@ -901,7 +901,7 @@ const OString& SvMetaType::GetBasicName() const OString SvMetaType::GetBasicPostfix() const { // MBN and Co always want "As xxx" - return OStringBuffer(RTL_CONSTASCII_STRINGPARAM(" As ")). + return OStringBuffer(" As "). append(GetBasicName()). makeStringAndClear(); } @@ -1401,10 +1401,10 @@ void SvMetaType::WriteSfxItem( const OString& rItemName, SvIdlDataBase &, SvStream & rOutStm ) { WriteStars( rOutStm ); - OStringBuffer aVarName(RTL_CONSTASCII_STRINGPARAM(" a")); - aVarName.append(rItemName).append(RTL_CONSTASCII_STRINGPARAM("_Impl")); + OStringBuffer aVarName(" a"); + aVarName.append(rItemName).append("_Impl"); - OStringBuffer aTypeName(RTL_CONSTASCII_STRINGPARAM("SfxType")); + OStringBuffer aTypeName("SfxType"); OStringBuffer aAttrArray; sal_uLong nAttrCount = MakeSfx( aAttrArray ); OString aAttrCount( diff --git a/idl/source/prj/database.cxx b/idl/source/prj/database.cxx index 474b70a70c49..b42c5728930c 100644 --- a/idl/source/prj/database.cxx +++ b/idl/source/prj/database.cxx @@ -231,8 +231,7 @@ sal_Bool SvIdlDataBase::ReadIdFile( const OUString & rFileName ) aDefName = pTok->GetString(); else { - OString aStr(RTL_CONSTASCII_STRINGPARAM( - "unexpected token after define")); + OString aStr("unexpected token after define"); // set error SetError( aStr, pTok ); WriteError( aTokStm ); @@ -288,7 +287,7 @@ sal_Bool SvIdlDataBase::ReadIdFile( const OUString & rFileName ) { if( !InsertId( aDefName, nVal ) ) { - OString aStr(RTL_CONSTASCII_STRINGPARAM("hash table overflow: ")); + OString aStr("hash table overflow: "); SetError( aStr, pTok ); WriteError( aTokStm ); return sal_False; @@ -312,8 +311,7 @@ sal_Bool SvIdlDataBase::ReadIdFile( const OUString & rFileName ) } if( pTok->IsEof() ) { - OString aStr(RTL_CONSTASCII_STRINGPARAM( - "unexpected eof in #include")); + OString aStr("unexpected eof in #include"); // set error SetError(aStr, pTok); WriteError( aTokStm ); @@ -323,8 +321,7 @@ sal_Bool SvIdlDataBase::ReadIdFile( const OUString & rFileName ) if (!ReadIdFile(OStringToOUString(aName.toString(), RTL_TEXTENCODING_ASCII_US))) { - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "cannot read file: ")); + OStringBuffer aStr("cannot read file: "); aStr.append(aName.makeStringAndClear()); SetError(aStr.makeStringAndClear(), pTok); WriteError( aTokStm ); @@ -569,7 +566,7 @@ void SvIdlDataBase::WriteError( SvTokenStream & rInStm ) // error text if( !aError.GetText().isEmpty() ) { - aErrorText.append(RTL_CONSTASCII_STRINGPARAM("may be <")); + aErrorText.append("may be <"); aErrorText.append(aError.GetText()); } SvToken * pPrevTok = NULL; @@ -583,11 +580,11 @@ void SvIdlDataBase::WriteError( SvTokenStream & rInStm ) } // error position - aErrorText.append(RTL_CONSTASCII_STRINGPARAM("> at ( ")); + aErrorText.append("> at ( "); aErrorText.append(static_cast<sal_Int64>(aError.nLine)); - aErrorText.append(RTL_CONSTASCII_STRINGPARAM(", ")); + aErrorText.append(", "); aErrorText.append(static_cast<sal_Int64>(aError.nColumn)); - aErrorText.append(RTL_CONSTASCII_STRINGPARAM(" )")); + aErrorText.append(" )"); // reset error aError = SvIdlError(); diff --git a/l10ntools/source/export.cxx b/l10ntools/source/export.cxx index 1be5fa2eeee9..405716719b44 100644 --- a/l10ntools/source/export.cxx +++ b/l10ntools/source/export.cxx @@ -133,7 +133,7 @@ sal_Bool ResData::SetId( const OString& rId, sal_uInt16 nLevel ) if ( bChild && bChildWithText ) { - OString sError(RTL_CONSTASCII_STRINGPARAM("ResId after child definition")); + OString sError("ResId after child definition"); yyerror(sError.getStr()); SetError(); } @@ -664,9 +664,9 @@ int Export::Execute( int nToken, const char * pToken ) { if (!pResData->sText[ sLangIndex ].isEmpty()) { - OStringBuffer sError(RTL_CONSTASCII_STRINGPARAM("Language ")); + OStringBuffer sError("Language "); sError.append(sLangIndex); - sError.append(RTL_CONSTASCII_STRINGPARAM("defined twice")); + sError.append("defined twice"); yyerror(sError.getStr()); } pResData->sText[ sLangIndex ] = sText; @@ -679,7 +679,7 @@ int Export::Execute( int nToken, const char * pToken ) { if (!pResData->sHelpText[ sLangIndex ].isEmpty()) { - OStringBuffer sError(RTL_CONSTASCII_STRINGPARAM("Language ")); + OStringBuffer sError("Language "); sError.append(sLangIndex); sError.append(" defined twice"); YYWarning(sError.getStr()); @@ -694,9 +694,9 @@ int Export::Execute( int nToken, const char * pToken ) { if (!pResData->sQuickHelpText[ sLangIndex ].isEmpty()) { - OStringBuffer sError(RTL_CONSTASCII_STRINGPARAM("Language ")); + OStringBuffer sError("Language "); sError.append(sLangIndex); - sError.append(RTL_CONSTASCII_STRINGPARAM(" defined twice")); + sError.append(" defined twice"); YYWarning(sError.getStr()); } pResData->sQuickHelpText[ sLangIndex ] = sText; @@ -709,9 +709,9 @@ int Export::Execute( int nToken, const char * pToken ) { if ( !pResData->sTitle[ sLangIndex ].isEmpty()) { - OStringBuffer sError(RTL_CONSTASCII_STRINGPARAM("Language ")); + OStringBuffer sError("Language "); sError.append(sLangIndex); - sError.append(RTL_CONSTASCII_STRINGPARAM(" defined twice")); + sError.append(" defined twice"); YYWarning(sError.getStr()); } pResData->sTitle[ sLangIndex ] = sText; @@ -987,7 +987,7 @@ OString Export::FullId() } if (sFull.getLength() > 255) { - OString sError(RTL_CONSTASCII_STRINGPARAM("GroupId > 255 chars")); + OString sError("GroupId > 255 chars"); printf("GroupID = %s\n", sFull.getStr()); yyerror(sError.getStr()); } diff --git a/linguistic/source/dicimp.cxx b/linguistic/source/dicimp.cxx index 82d4e7e2f66a..7000cd0715d5 100644 --- a/linguistic/source/dicimp.cxx +++ b/linguistic/source/dicimp.cxx @@ -377,7 +377,7 @@ static OString formatForSave(const uno::Reference< XDictionaryEntry > &xEntry, if (xEntry->isNegative()) { - aStr.append(RTL_CONSTASCII_STRINGPARAM("==")); + aStr.append("=="); aStr.append(OUStringToOString(xEntry->getReplacementText(), eEnc)); } return aStr.makeStringAndClear(); @@ -467,22 +467,22 @@ sal_uLong DictionaryNeo::saveEntries(const OUString &rURL) * undetermined or multiple? Earlier versions did not know about 'und' and * 'mul' and 'zxx' codes. Sync with ReadDicVersion() */ if (LinguIsUnspecified(nLanguage)) - pStream->WriteLine(OString(RTL_CONSTASCII_STRINGPARAM("lang: <none>"))); + pStream->WriteLine(OString("lang: <none>")); else { - OStringBuffer aLine(RTL_CONSTASCII_STRINGPARAM("lang: ")); + OStringBuffer aLine("lang: "); aLine.append(OUStringToOString(LanguageTag::convertToBcp47(nLanguage), eEnc)); pStream->WriteLine(aLine.makeStringAndClear()); } if (0 != (nErr = pStream->GetError())) return nErr; if (eDicType == DictionaryType_POSITIVE) - pStream->WriteLine(OString(RTL_CONSTASCII_STRINGPARAM("type: positive"))); + pStream->WriteLine(OString("type: positive")); else - pStream->WriteLine(OString(RTL_CONSTASCII_STRINGPARAM("type: negative"))); + pStream->WriteLine(OString("type: negative")); if (0 != (nErr = pStream->GetError())) return nErr; - pStream->WriteLine(OString(RTL_CONSTASCII_STRINGPARAM("---"))); + pStream->WriteLine(OString("---")); if (0 != (nErr = pStream->GetError())) return nErr; const uno::Reference< XDictionaryEntry > *pEntry = aEntries.getConstArray(); diff --git a/rsc/source/rsc/rsc.cxx b/rsc/source/rsc/rsc.cxx index 1b94cf11fb91..4ad9b4487abc 100644 --- a/rsc/source/rsc/rsc.cxx +++ b/rsc/source/rsc/rsc.cxx @@ -848,8 +848,8 @@ void RscCompiler::PreprocessSrsFile( const RscCmdLine::OutputFile& rOutputFile, if( GetImageFilePath( rOutputFile, rContext, aBaseFileName, aFilePath, pSysListFile ) ) { - aLine = OStringBuffer(RTL_CONSTASCII_STRINGPARAM("File = \"")). - append(aFilePath).append(RTL_CONSTASCII_STRINGPARAM("\";")). + aLine = OStringBuffer("File = \""). + append(aFilePath).append("\";"). makeStringAndClear(); } else @@ -926,22 +926,21 @@ void RscCompiler::PreprocessSrsFile( const RscCmdLine::OutputFile& rOutputFile, aOStm.WriteLine(aLine); } - aOStm.WriteLine(OString(RTL_CONSTASCII_STRINGPARAM("FileList = {"))); + aOStm.WriteLine(OString("FileList = {")); for( sal_uInt32 i = 0; i < aEntryVector.size(); ++i ) { - OStringBuffer aEntryString( - RTL_CONSTASCII_STRINGPARAM("< \"")); + OStringBuffer aEntryString("< \""); aEntryString.append(aEntryVector[i].first); - aEntryString.append(RTL_CONSTASCII_STRINGPARAM("\"; ")); + aEntryString.append("\"; "); aEntryString.append(static_cast<sal_Int32>(aEntryVector[ i ].second)); - aEntryString.append(RTL_CONSTASCII_STRINGPARAM("; >;")); + aEntryString.append("; >;"); aOStm.WriteLine(aEntryString.makeStringAndClear()); } - aOStm.WriteLine(OString(RTL_CONSTASCII_STRINGPARAM("};"))); + aOStm.WriteLine(OString("};")); } else aOStm.WriteLine(aLine); diff --git a/sal/osl/all/debugbase.cxx b/sal/osl/all/debugbase.cxx index d92d92dd9b09..8bc0c4619d3e 100644 --- a/sal/osl/all/debugbase.cxx +++ b/sal/osl/all/debugbase.cxx @@ -120,9 +120,9 @@ bool SAL_CALL osl_detail_ObjectRegistry_checkObjectCount( bool const bRet = (nSize == nExpected); if (! bRet) { rtl::OStringBuffer buf; - buf.append( RTL_CONSTASCII_STRINGPARAM("unexpected number of ") ); + buf.append( "unexpected number of " ); buf.append( rData.m_pName ); - buf.append( RTL_CONSTASCII_STRINGPARAM(": ") ); + buf.append( ": " ); buf.append( static_cast<sal_Int64>(nSize) ); buf.append("; Expected: "); buf.append( static_cast<sal_Int64>(nExpected) ); diff --git a/sc/source/core/data/attarray.cxx b/sc/source/core/data/attarray.cxx index e9bfa5969a41..cee38bb8823d 100644 --- a/sc/source/core/data/attarray.cxx +++ b/sc/source/core/data/attarray.cxx @@ -100,8 +100,7 @@ void ScAttrArray::TestData() const { OStringBuffer aMsg; aMsg.append(static_cast<sal_Int32>(nErr)); - aMsg.append(RTL_CONSTASCII_STRINGPARAM( - " errors in attribute array, column ")); + aMsg.append(" errors in attribute array, column "); aMsg.append(static_cast<sal_Int32>(nCol)); OSL_FAIL(aMsg.getStr()); } diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx index c067976a7418..ab6dda9799ff 100644 --- a/sc/source/core/data/formulacell.cxx +++ b/sc/source/core/data/formulacell.cxx @@ -2063,11 +2063,10 @@ sal_uInt16 ScFormulaCell::GetMatrixEdge( ScAddress& rOrgPos ) const else { #if OSL_DEBUG_LEVEL > 0 - OStringBuffer aMsg(RTL_CONSTASCII_STRINGPARAM( - "broken Matrix, no MatFormula at origin, Pos: ")); + OStringBuffer aMsg("broken Matrix, no MatFormula at origin, Pos: "); OUString aTmp(aPos.Format(SCA_VALID_COL | SCA_VALID_ROW, pDocument)); aMsg.append(OUStringToOString(aTmp, RTL_TEXTENCODING_ASCII_US)); - aMsg.append(RTL_CONSTASCII_STRINGPARAM(", MatOrg: ")); + aMsg.append(", MatOrg: "); aTmp = aOrg.Format(SCA_VALID_COL | SCA_VALID_ROW, pDocument); aMsg.append(OUStringToOString(aTmp, RTL_TEXTENCODING_ASCII_US)); OSL_FAIL(aMsg.getStr()); @@ -2098,16 +2097,16 @@ sal_uInt16 ScFormulaCell::GetMatrixEdge( ScAddress& rOrgPos ) const OStringBuffer aMsg( "broken Matrix, Pos: " ); OUString aTmp(aPos.Format(SCA_VALID_COL | SCA_VALID_ROW, pDocument)); aMsg.append(OUStringToOString(aTmp, RTL_TEXTENCODING_UTF8 )); - aMsg.append(RTL_CONSTASCII_STRINGPARAM(", MatOrg: ")); + aMsg.append(", MatOrg: "); aTmp = aOrg.Format(SCA_VALID_COL | SCA_VALID_ROW, pDocument); aMsg.append(OUStringToOString(aTmp, RTL_TEXTENCODING_UTF8 )); - aMsg.append(RTL_CONSTASCII_STRINGPARAM(", MatCols: ")); + aMsg.append(", MatCols: "); aMsg.append(static_cast<sal_Int32>( nC )); - aMsg.append(RTL_CONSTASCII_STRINGPARAM(", MatRows: ")); + aMsg.append(", MatRows: "); aMsg.append(static_cast<sal_Int32>( nR )); - aMsg.append(RTL_CONSTASCII_STRINGPARAM(", DiffCols: ")); + aMsg.append(", DiffCols: "); aMsg.append(static_cast<sal_Int32>( dC )); - aMsg.append(RTL_CONSTASCII_STRINGPARAM(", DiffRows: ")); + aMsg.append(", DiffRows: "); aMsg.append(static_cast<sal_Int32>( dR )); OSL_FAIL( aMsg.makeStringAndClear().getStr()); } diff --git a/sc/source/core/tool/interpr2.cxx b/sc/source/core/tool/interpr2.cxx index e7198c4e09b2..27b0af9fc370 100644 --- a/sc/source/core/tool/interpr2.cxx +++ b/sc/source/core/tool/interpr2.cxx @@ -2667,16 +2667,16 @@ void lclAppendDigit( OStringBuffer& rText, sal_Int32 nDigit ) { switch( nDigit ) { - case 0: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_0) ); break; - case 1: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_1) ); break; - case 2: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_2) ); break; - case 3: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_3) ); break; - case 4: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_4) ); break; - case 5: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_5) ); break; - case 6: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_6) ); break; - case 7: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_7) ); break; - case 8: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_8) ); break; - case 9: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_9) ); break; + case 0: rText.append( UTF8_TH_0 ); break; + case 1: rText.append( UTF8_TH_1 ); break; + case 2: rText.append( UTF8_TH_2 ); break; + case 3: rText.append( UTF8_TH_3 ); break; + case 4: rText.append( UTF8_TH_4 ); break; + case 5: rText.append( UTF8_TH_5 ); break; + case 6: rText.append( UTF8_TH_6 ); break; + case 7: rText.append( UTF8_TH_7 ); break; + case 8: rText.append( UTF8_TH_8 ); break; + case 9: rText.append( UTF8_TH_9 ); break; default: OSL_FAIL( "lclAppendDigit - illegal digit" ); } } @@ -2691,10 +2691,10 @@ void lclAppendPow10( OStringBuffer& rText, sal_Int32 nDigit, sal_Int32 nPow10 ) lclAppendDigit( rText, nDigit ); switch( nPow10 ) { - case 2: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_1E2) ); break; - case 3: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_1E3) ); break; - case 4: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_1E4) ); break; - case 5: rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_1E5) ); break; + case 2: rText.append( UTF8_TH_1E2 ); break; + case 3: rText.append( UTF8_TH_1E3 ); break; + case 4: rText.append( UTF8_TH_1E4 ); break; + case 5: rText.append( UTF8_TH_1E5 ); break; default: OSL_FAIL( "lclAppendPow10 - illegal power" ); } } @@ -2732,11 +2732,11 @@ void lclAppendBlock( OStringBuffer& rText, sal_Int32 nValue ) if( nTen >= 3 ) lclAppendDigit( rText, nTen ); else if( nTen == 2 ) - rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_20) ); - rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_10) ); + rText.append( UTF8_TH_20 ); + rText.append( UTF8_TH_10 ); } if( (nTen > 0) && (nOne == 1) ) - rText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_11) ); + rText.append( UTF8_TH_11 ); else if( nOne > 0 ) lclAppendDigit( rText, nOne ); } @@ -2774,7 +2774,7 @@ void ScInterpreter::ScBahtText() if( fBaht == 0.0 ) { if( nSatang == 0 ) - aText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_0) ); + aText.append( UTF8_TH_0 ); } else while( fBaht > 0.0 ) { @@ -2785,29 +2785,27 @@ void ScInterpreter::ScBahtText() lclAppendBlock( aBlock, nBlock ); // add leading "million", if there will come more blocks if( fBaht > 0.0 ) - aBlock.insert( - 0, OString(RTL_CONSTASCII_STRINGPARAM(UTF8_TH_1E6))); + aBlock.insert( 0, OString(UTF8_TH_1E6 ) ); aText.insert(0, aBlock.makeStringAndClear()); } if (!aText.isEmpty()) - aText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_BAHT) ); + aText.append( UTF8_TH_BAHT ); // generate text for Satang value if( nSatang == 0 ) { - aText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_DOT0) ); + aText.append( UTF8_TH_DOT0 ); } else { lclAppendBlock( aText, nSatang ); - aText.append( RTL_CONSTASCII_STRINGPARAM(UTF8_TH_SATANG) ); + aText.append( UTF8_TH_SATANG ); } // add the minus sign if( bMinus ) - aText.insert( - 0, OString(RTL_CONSTASCII_STRINGPARAM(UTF8_TH_MINUS))); + aText.insert( 0, OString( UTF8_TH_MINUS ) ); PushString( OStringToOUString(aText.makeStringAndClear(), RTL_TEXTENCODING_UTF8) ); } diff --git a/sc/source/filter/html/htmlexp.cxx b/sc/source/filter/html/htmlexp.cxx index 19910d8c5b2a..a6450cdabec2 100644 --- a/sc/source/filter/html/htmlexp.cxx +++ b/sc/source/filter/html/htmlexp.cxx @@ -150,12 +150,12 @@ static OString lcl_getColGroupString(sal_Int32 nSpan, sal_Int32 nWidth) if( nSpan > 1 ) { aByteStr.append(OOO_STRING_SVTOOLS_HTML_O_span); - aByteStr.append(RTL_CONSTASCII_STRINGPARAM("=\"")); + aByteStr.append("=\""); aByteStr.append(nSpan); - aByteStr.append(RTL_CONSTASCII_STRINGPARAM("\" ")); + aByteStr.append("\" "); } aByteStr.append(OOO_STRING_SVTOOLS_HTML_O_width); - aByteStr.append(RTL_CONSTASCII_STRINGPARAM("=\"")); + aByteStr.append("=\""); aByteStr.append(nWidth); aByteStr.append('"'); return aByteStr.makeStringAndClear(); @@ -492,28 +492,27 @@ OString ScHTMLExport::BorderToStyle(const char* pBorderName, if ( pLine ) { if ( bInsertSemicolon ) - aOut.append(RTL_CONSTASCII_STRINGPARAM("; ")); + aOut.append("; "); // which border - aOut.append(RTL_CONSTASCII_STRINGPARAM("border-")). - append(pBorderName).append(RTL_CONSTASCII_STRINGPARAM(": ")); + aOut.append("border-").append(pBorderName).append(": "); // thickness int nWidth = pLine->GetWidth(); int nPxWidth = (nWidth > 0) ? std::max(int(nWidth / TWIPS_PER_PIXEL), 1) : 0; aOut.append(static_cast<sal_Int32>(nPxWidth)). - append(RTL_CONSTASCII_STRINGPARAM("px ")); + append("px "); switch (pLine->GetBorderLineStyle()) { case table::BorderLineStyle::SOLID: - aOut.append(RTL_CONSTASCII_STRINGPARAM("solid")); + aOut.append("solid"); break; case table::BorderLineStyle::DOTTED: - aOut.append(RTL_CONSTASCII_STRINGPARAM("dotted")); + aOut.append("dotted"); break; case table::BorderLineStyle::DASHED: - aOut.append(RTL_CONSTASCII_STRINGPARAM("dashed")); + aOut.append("dashed"); break; case table::BorderLineStyle::DOUBLE: case table::BorderLineStyle::THINTHICK_SMALLGAP: @@ -522,24 +521,24 @@ OString ScHTMLExport::BorderToStyle(const char* pBorderName, case table::BorderLineStyle::THICKTHIN_SMALLGAP: case table::BorderLineStyle::THICKTHIN_MEDIUMGAP: case table::BorderLineStyle::THICKTHIN_LARGEGAP: - aOut.append(RTL_CONSTASCII_STRINGPARAM("double")); + aOut.append("double"); break; case table::BorderLineStyle::EMBOSSED: - aOut.append(RTL_CONSTASCII_STRINGPARAM("ridge")); + aOut.append("ridge"); break; case table::BorderLineStyle::ENGRAVED: - aOut.append(RTL_CONSTASCII_STRINGPARAM("groove")); + aOut.append("groove"); break; case table::BorderLineStyle::OUTSET: - aOut.append(RTL_CONSTASCII_STRINGPARAM("outset")); + aOut.append("outset"); break; case table::BorderLineStyle::INSET: - aOut.append(RTL_CONSTASCII_STRINGPARAM("inset")); + aOut.append("inset"); break; default: - aOut.append(RTL_CONSTASCII_STRINGPARAM("hidden")); + aOut.append("hidden"); } - aOut.append(RTL_CONSTASCII_STRINGPARAM(" #")); + aOut.append(" #"); // color char hex[7]; @@ -717,18 +716,18 @@ void ScHTMLExport::WriteTables() if ( bTabAlignedLeft ) { aByteStrOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_align). - append(RTL_CONSTASCII_STRINGPARAM("=\"")). + append("=\""). append(OOO_STRING_SVTOOLS_HTML_AL_left).append('"'); } // ALIGN=LEFT allow text and graphics to flow around // CELLSPACING aByteStrOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_cellspacing). - append(RTL_CONSTASCII_STRINGPARAM("=\"")). + append("=\""). append(static_cast<sal_Int32>(nCellSpacing)).append('"'); // BORDER=0, we do the styling of the cells in <TD> aByteStrOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_border). - append(RTL_CONSTASCII_STRINGPARAM("=\"0\"")); + append("=\"0\""); IncIndent(1); TAG_ON_LF( aByteStrOut.makeStringAndClear().getStr() ); // --- <COLGROUP> ---- @@ -882,7 +881,7 @@ void ScHTMLExport::WriteCell( SCCOL nCol, SCROW nRow, SCTAB nTab ) if ( pBorder && (pBorder->GetTop() || pBorder->GetBottom() || pBorder->GetLeft() || pBorder->GetRight()) ) { aStrTD.append(' ').append(OOO_STRING_SVTOOLS_HTML_style). - append(RTL_CONSTASCII_STRINGPARAM("=\"")); + append("=\""); bool bInsertSemicolon = false; aStrTD.append(BorderToStyle("top", pBorder->GetTop(), @@ -942,7 +941,7 @@ void ScHTMLExport::WriteCell( SCCOL nCol, SCROW nRow, SCTAB nTab ) if ( bTableDataHeight ) { aStrTD.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_height). - append(RTL_CONSTASCII_STRINGPARAM("=\"")). + append("=\""). append(static_cast<sal_Int32>(nHeightPixel)).append('"'); } @@ -1017,7 +1016,7 @@ void ScHTMLExport::WriteCell( SCCOL nCol, SCROW nRow, SCTAB nTab ) } aStrTD.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_align). - append(RTL_CONSTASCII_STRINGPARAM("=\"")).append(pChar).append('"'); + append("=\"").append(pChar).append('"'); switch( rVerJustifyItem.GetValue() ) { @@ -1074,7 +1073,7 @@ void ScHTMLExport::WriteCell( SCCOL nCol, SCROW nRow, SCTAB nTab ) if ( bSetFontName ) { aStr.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_face). - append(RTL_CONSTASCII_STRINGPARAM("=\"")); + append("=\""); sal_Int32 nFonts = comphelper::string::getTokenCount(rFontItem.GetFamilyName(), ';'); if ( nFonts == 1 ) { diff --git a/sc/source/ui/docshell/docsh3.cxx b/sc/source/ui/docshell/docsh3.cxx index 3d785c612a22..1251a2b89a86 100644 --- a/sc/source/ui/docshell/docsh3.cxx +++ b/sc/source/ui/docshell/docsh3.cxx @@ -943,7 +943,7 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc, bool bShared, bool bCheck ((const ScChangeActionContent*)pSourceAction)->GetNewString( aValue, &aDocument ); OStringBuffer aError(OUStringToOString(aValue, osl_getThreadTextEncoding())); - aError.append(RTL_CONSTASCII_STRINGPARAM(" weggelassen")); + aError.append(" weggelassen"); OSL_FAIL( aError.getStr() ); #endif } diff --git a/sfx2/source/appl/impldde.cxx b/sfx2/source/appl/impldde.cxx index 63630485d190..cc6431d0bd3a 100644 --- a/sfx2/source/appl/impldde.cxx +++ b/sfx2/source/appl/impldde.cxx @@ -248,7 +248,7 @@ sal_Bool SvDDEObject::Connect( SvBaseLink * pSvLink ) if( !bInWinExec ) { OStringBuffer aCmdLine(OUStringToOString(sServer, RTL_TEXTENCODING_ASCII_US)); - aCmdLine.append(RTL_CONSTASCII_STRINGPARAM(".exe ")); + aCmdLine.append(".exe "); aCmdLine.append(OUStringToOString(sTopic, RTL_TEXTENCODING_ASCII_US)); if( WinExec( aCmdLine.getStr(), SW_SHOWMINIMIZED ) < 32 ) diff --git a/sfx2/source/bastyp/frmhtmlw.cxx b/sfx2/source/bastyp/frmhtmlw.cxx index d3877b9abc3c..787e8175cca8 100644 --- a/sfx2/source/bastyp/frmhtmlw.cxx +++ b/sfx2/source/bastyp/frmhtmlw.cxx @@ -255,7 +255,7 @@ void SfxFrameHTMLWriter::Out_FrameDescriptor( aURL = URIHelper::simpleNormalizedMakeRelative( rBaseURL, aURL ); sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_src) - .append(RTL_CONSTASCII_STRINGPARAM("=\"")); + .append("=\""); rOut << sOut.makeStringAndClear().getStr(); HTMLOutFuncs::Out_String( rOut, aURL, eDestEnc, pNonConvertableChars ); sOut.append('\"'); @@ -266,7 +266,7 @@ void SfxFrameHTMLWriter::Out_FrameDescriptor( if ( (aAny >>= aStr) && !aStr.isEmpty() ) { sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_name) - .append(RTL_CONSTASCII_STRINGPARAM("=\"")); + .append("=\""); rOut << sOut.makeStringAndClear().getStr(); HTMLOutFuncs::Out_String( rOut, aStr, eDestEnc, pNonConvertableChars ); sOut.append('\"'); diff --git a/sfx2/source/control/dispatch.cxx b/sfx2/source/control/dispatch.cxx index 08e958e293ef..923a6152859a 100644 --- a/sfx2/source/control/dispatch.cxx +++ b/sfx2/source/control/dispatch.cxx @@ -369,7 +369,7 @@ SfxDispatcher::~SfxDispatcher() { #ifdef DBG_UTIL - OStringBuffer sTemp(RTL_CONSTASCII_STRINGPARAM("Delete Dispatcher ")); + OStringBuffer sTemp("Delete Dispatcher "); sTemp.append(reinterpret_cast<sal_Int64>(this)); OSL_TRACE("%s", sTemp.getStr()); DBG_ASSERT( !pImp->bActive, "deleting active Dispatcher" ); @@ -680,8 +680,7 @@ void SfxDispatcher::DoActivate_Impl( sal_Bool bMDI, SfxViewFrame* /* pOld */ ) if ( bMDI ) { #ifdef DBG_UTIL - OStringBuffer sTemp( - RTL_CONSTASCII_STRINGPARAM("Activate Dispatcher ")); + OStringBuffer sTemp("Activate Dispatcher "); sTemp.append(reinterpret_cast<sal_Int64>(this)); OSL_TRACE("%s", sTemp.getStr()); DBG_ASSERT( !pImp->bActive, "Activation error" ); @@ -698,8 +697,7 @@ void SfxDispatcher::DoActivate_Impl( sal_Bool bMDI, SfxViewFrame* /* pOld */ ) else { #ifdef DBG_UTIL - OStringBuffer sTemp( - RTL_CONSTASCII_STRINGPARAM("Non-MDI-Activate Dispatcher")); + OStringBuffer sTemp("Non-MDI-Activate Dispatcher"); sTemp.append(reinterpret_cast<sal_Int64>(this)); OSL_TRACE("%s", sTemp.getStr()); #endif @@ -762,7 +760,7 @@ void SfxDispatcher::DoDeactivate_Impl( sal_Bool bMDI, SfxViewFrame* pNew ) if ( bMDI ) { - OSL_TRACE(OStringBuffer(RTL_CONSTASCII_STRINGPARAM("Deactivate Dispatcher")).append(reinterpret_cast<sal_Int64>(this)).getStr()); + OSL_TRACE(OStringBuffer("Deactivate Dispatcher").append(reinterpret_cast<sal_Int64>(this)).getStr()); DBG_ASSERT( pImp->bActive, "Deactivate error" ); pImp->bActive = sal_False; @@ -783,7 +781,7 @@ void SfxDispatcher::DoDeactivate_Impl( sal_Bool bMDI, SfxViewFrame* pNew ) } } else { - OSL_TRACE(OStringBuffer(RTL_CONSTASCII_STRINGPARAM("Non-MDI-DeActivate Dispatcher")).append(reinterpret_cast<sal_Int64>(this)).getStr()); + OSL_TRACE(OStringBuffer("Non-MDI-DeActivate Dispatcher").append(reinterpret_cast<sal_Int64>(this)).getStr()); } if ( IsAppDispatcher() && !pSfxApp->IsDowning() ) @@ -2035,11 +2033,10 @@ sal_Bool SfxDispatcher::_FillState sal_uInt16 nSlotId = rState.GetPool()->GetSlotId(pItem->Which()); if ( !pItem->IsA(pIF->GetSlot(nSlotId)->GetType()->Type()) ) { - OStringBuffer aMsg(RTL_CONSTASCII_STRINGPARAM( - "item-type unequal to IDL (=> no BASIC)")); - aMsg.append(RTL_CONSTASCII_STRINGPARAM("\nwith SID: ")); + OStringBuffer aMsg("item-type unequal to IDL (=> no BASIC)"); + aMsg.append("\nwith SID: "); aMsg.append(static_cast<sal_Int32>(nSlotId)); - aMsg.append(RTL_CONSTASCII_STRINGPARAM("\nin ")); + aMsg.append("\nin "); aMsg.append(pIF->GetClassName()); DbgOut(aMsg.getStr(), DBG_OUT_ERROR, __FILE__, __LINE__); } diff --git a/sfx2/source/control/objface.cxx b/sfx2/source/control/objface.cxx index 345ab28d14f5..2778b393a6a0 100644 --- a/sfx2/source/control/objface.cxx +++ b/sfx2/source/control/objface.cxx @@ -221,11 +221,10 @@ void SfxInterface::SetSlotMap( SfxSlot& rSlotMap, sal_uInt16 nSlotCount ) { if ( pSlave->pLinkedSlot != pMasterSlot ) { - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "Wrong Master/Slave- link: ")); + OStringBuffer aStr("Wrong Master/Slave- link: "); aStr.append(static_cast<sal_Int32>( pMasterSlot->GetSlotId())); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" , ")); + aStr.append(" , "); aStr.append(static_cast<sal_Int32>( pSlave->GetSlotId())); OSL_FAIL(aStr.getStr()); @@ -233,11 +232,10 @@ void SfxInterface::SetSlotMap( SfxSlot& rSlotMap, sal_uInt16 nSlotCount ) if ( pSlave->nMasterSlotId != pMasterSlot->GetSlotId() ) { - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "Wrong Master/Slave-Ids: ")); + OStringBuffer aStr("Wrong Master/Slave-Ids: "); aStr.append(static_cast<sal_Int32>( pMasterSlot->GetSlotId())); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" , ")); + aStr.append(" , "); aStr.append(static_cast<sal_Int32>( pSlave->GetSlotId())); OSL_FAIL(aStr.getStr()); @@ -253,10 +251,9 @@ void SfxInterface::SetSlotMap( SfxSlot& rSlotMap, sal_uInt16 nSlotCount ) { if ( pIter->pLinkedSlot->GetKind() != SFX_KIND_ENUM ) { - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "Slave is no enum: ")); + OStringBuffer aStr("Slave is no enum: "); aStr.append(static_cast<sal_Int32>(pIter->GetSlotId())); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" , ")); + aStr.append(" , "); aStr.append(static_cast<sal_Int32>( pIter->pLinkedSlot->GetSlotId())); OSL_FAIL(aStr.getStr()); @@ -269,11 +266,10 @@ void SfxInterface::SetSlotMap( SfxSlot& rSlotMap, sal_uInt16 nSlotCount ) pCurSlot = pCurSlot->pNextSlot; if ( pCurSlot->GetStateFnc() != pIter->GetStateFnc() ) { - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "Linked Slots with different State Methods : ")); + OStringBuffer aStr("Linked Slots with different State Methods : "); aStr.append(static_cast<sal_Int32>( pCurSlot->GetSlotId())); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" , ")); + aStr.append(" , "); aStr.append(static_cast<sal_Int32>(pIter->GetSlotId())); OSL_FAIL(aStr.getStr()); } diff --git a/sfx2/source/doc/docfac.cxx b/sfx2/source/doc/docfac.cxx index 67de74486ea9..fcbabc4fcf01 100644 --- a/sfx2/source/doc/docfac.cxx +++ b/sfx2/source/doc/docfac.cxx @@ -151,10 +151,9 @@ void SfxObjectFactory::RegisterViewFactory { if ( (*it)->GetAPIViewName() != sViewName ) continue; - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "SfxObjectFactory::RegisterViewFactory: duplicate view name '")); + OStringBuffer aStr("SfxObjectFactory::RegisterViewFactory: duplicate view name '"); aStr.append(OUStringToOString(sViewName, RTL_TEXTENCODING_ASCII_US)); - aStr.append(RTL_CONSTASCII_STRINGPARAM("'!")); + aStr.append("'!"); OSL_FAIL(aStr.getStr()); break; } diff --git a/svtools/source/misc/imap2.cxx b/svtools/source/misc/imap2.cxx index 747ef4c4cf52..3f72ec305d6e 100644 --- a/svtools/source/misc/imap2.cxx +++ b/svtools/source/misc/imap2.cxx @@ -47,7 +47,7 @@ void IMapObject::AppendCERNCoords(OStringBuffer& rBuf, const Point& rPoint100) c rBuf.append(static_cast<sal_Int32>(aPixPt.X())); rBuf.append(','); rBuf.append(static_cast<sal_Int32>(aPixPt.Y())); - rBuf.append(RTL_CONSTASCII_STRINGPARAM(") ")); + rBuf.append(") "); } void IMapObject::AppendNCSACoords(OStringBuffer& rBuf, const Point& rPoint100) const @@ -73,7 +73,7 @@ void IMapObject::AppendNCSAURL(OStringBuffer& rBuf, const OUString& rBaseURL) co void IMapRectangleObject::WriteCERN( SvStream& rOStm, const OUString& rBaseURL ) const { - OStringBuffer aStrBuf(RTL_CONSTASCII_STRINGPARAM("rectangle ")); + OStringBuffer aStrBuf("rectangle "); AppendCERNCoords(aStrBuf, aRect.TopLeft()); AppendCERNCoords(aStrBuf, aRect.BottomRight()); @@ -84,7 +84,7 @@ void IMapRectangleObject::WriteCERN( SvStream& rOStm, const OUString& rBaseURL ) void IMapRectangleObject::WriteNCSA( SvStream& rOStm, const OUString& rBaseURL ) const { - OStringBuffer aStrBuf(RTL_CONSTASCII_STRINGPARAM("rect ")); + OStringBuffer aStrBuf("rect "); AppendNCSAURL(aStrBuf, rBaseURL); AppendNCSACoords(aStrBuf, aRect.TopLeft()); @@ -95,7 +95,7 @@ void IMapRectangleObject::WriteNCSA( SvStream& rOStm, const OUString& rBaseURL ) void IMapCircleObject::WriteCERN( SvStream& rOStm, const OUString& rBaseURL ) const { - OStringBuffer aStrBuf(RTL_CONSTASCII_STRINGPARAM("circle ")); + OStringBuffer aStrBuf("circle "); AppendCERNCoords(aStrBuf, aCenter); aStrBuf.append(nRadius); @@ -107,7 +107,7 @@ void IMapCircleObject::WriteCERN( SvStream& rOStm, const OUString& rBaseURL ) co void IMapCircleObject::WriteNCSA( SvStream& rOStm, const OUString& rBaseURL ) const { - OStringBuffer aStrBuf(RTL_CONSTASCII_STRINGPARAM("circle ")); + OStringBuffer aStrBuf("circle "); AppendNCSAURL(aStrBuf, rBaseURL); AppendNCSACoords(aStrBuf, aCenter); @@ -118,7 +118,7 @@ void IMapCircleObject::WriteNCSA( SvStream& rOStm, const OUString& rBaseURL ) co void IMapPolygonObject::WriteCERN( SvStream& rOStm, const OUString& rBaseURL ) const { - OStringBuffer aStrBuf(RTL_CONSTASCII_STRINGPARAM("polygon ")); + OStringBuffer aStrBuf("polygon "); const sal_uInt16 nCount = aPoly.GetSize(); for (sal_uInt16 i = 0; i < nCount; ++i) @@ -131,7 +131,7 @@ void IMapPolygonObject::WriteCERN( SvStream& rOStm, const OUString& rBaseURL ) void IMapPolygonObject::WriteNCSA( SvStream& rOStm, const OUString& rBaseURL ) const { - OStringBuffer aStrBuf(RTL_CONSTASCII_STRINGPARAM("poly ")); + OStringBuffer aStrBuf("poly "); const sal_uInt16 nCount = std::min( aPoly.GetSize(), (sal_uInt16) 100 ); AppendNCSAURL(aStrBuf, rBaseURL); diff --git a/svtools/source/misc/transfer.cxx b/svtools/source/misc/transfer.cxx index f90404df77c0..32430046f26e 100644 --- a/svtools/source/misc/transfer.cxx +++ b/svtools/source/misc/transfer.cxx @@ -933,8 +933,8 @@ sal_Bool TransferableHelper::SetINetBookmark( const INetBookmark& rBmk, if( strchr( "\\/:*?\"<>|", aStr[nChar] ) ) aStr.remove(nChar--, 1); - aStr.insert(0, RTL_CONSTASCII_STRINGPARAM("Shortcut to ")); - aStr.append(RTL_CONSTASCII_STRINGPARAM(".URL")); + aStr.insert(0, "Shortcut to "); + aStr.append(".URL"); strcpy( rFDesc1.cFileName, aStr.getStr() ); maAny <<= aSeq; diff --git a/svtools/source/svhtml/htmlout.cxx b/svtools/source/svhtml/htmlout.cxx index 4ad0a8542711..913e4efa0655 100644 --- a/svtools/source/svhtml/htmlout.cxx +++ b/svtools/source/svhtml/htmlout.cxx @@ -613,10 +613,10 @@ SvStream& HTMLOutFuncs::Out_ImageMap( SvStream& rStream, OStringBuffer sOut; sOut.append('<') - .append(RTL_CONSTASCII_STRINGPARAM(OOO_STRING_SVTOOLS_HTML_map)) + .append(OOO_STRING_SVTOOLS_HTML_map) .append(' ') - .append(RTL_CONSTASCII_STRINGPARAM(OOO_STRING_SVTOOLS_HTML_O_name)) - .append(RTL_CONSTASCII_STRINGPARAM("=\"")); + .append(OOO_STRING_SVTOOLS_HTML_O_name) + .append("=\""); rStream << sOut.makeStringAndClear().getStr(); Out_String( rStream, rOutName, eDestEnc, pNonConvertableChars ); rStream << "\">"; @@ -791,13 +791,13 @@ SvStream& HTMLOutFuncs::OutScript( SvStream& rStrm, // Script wird komplett nicht eingerueckt! OStringBuffer sOut; sOut.append('<') - .append(RTL_CONSTASCII_STRINGPARAM(OOO_STRING_SVTOOLS_HTML_script)); + .append(OOO_STRING_SVTOOLS_HTML_script); if( !rLanguage.isEmpty() ) { sOut.append(' ') - .append(RTL_CONSTASCII_STRINGPARAM(OOO_STRING_SVTOOLS_HTML_O_language)) - .append(RTL_CONSTASCII_STRINGPARAM("=\"")); + .append(OOO_STRING_SVTOOLS_HTML_O_language) + .append("=\""); rStrm << sOut.makeStringAndClear().getStr(); Out_String( rStrm, rLanguage, eDestEnc, pNonConvertableChars ); sOut.append('\"'); @@ -847,8 +847,8 @@ SvStream& HTMLOutFuncs::OutScript( SvStream& rStrm, { if( pSBLibrary ) { - sOut.append(RTL_CONSTASCII_STRINGPARAM("' ")) - .append(RTL_CONSTASCII_STRINGPARAM(OOO_STRING_SVTOOLS_HTML_SB_library)) + sOut.append("' ") + .append(OOO_STRING_SVTOOLS_HTML_SB_library) .append(' ') .append(OUStringToOString(*pSBLibrary, eDestEnc)); rStrm << sOut.makeStringAndClear().getStr() << SAL_NEWLINE_STRING; @@ -856,8 +856,8 @@ SvStream& HTMLOutFuncs::OutScript( SvStream& rStrm, if( pSBModule ) { - sOut.append(RTL_CONSTASCII_STRINGPARAM("' ")) - .append(RTL_CONSTASCII_STRINGPARAM(OOO_STRING_SVTOOLS_HTML_SB_module)) + sOut.append("' ") + .append(OOO_STRING_SVTOOLS_HTML_SB_module) .append(' ') .append(OUStringToOString(*pSBModule, eDestEnc)); rStrm << sOut.makeStringAndClear().getStr() << SAL_NEWLINE_STRING; @@ -939,14 +939,14 @@ OString HTMLOutFuncs::CreateTableDataOptionsValNum( OString sTmp(OUStringToOString(aValStr, eDestEnc)); aStrTD.append(' '). append(OOO_STRING_SVTOOLS_HTML_O_SDval). - append(RTL_CONSTASCII_STRINGPARAM("=\"")). + append("=\""). append(sTmp).append('\"'); } if ( bValue || nFormat ) { aStrTD.append(' '). append(OOO_STRING_SVTOOLS_HTML_O_SDnum). - append(RTL_CONSTASCII_STRINGPARAM("=\"")). + append("=\""). append(static_cast<sal_Int32>( Application::GetSettings().GetLanguageTag().getLanguageType())). append(';'); // Language fuer Format 0 diff --git a/svx/source/form/fmsrcimp.cxx b/svx/source/form/fmsrcimp.cxx index 747eea486e6d..3d6a54cffab4 100644 --- a/svx/source/form/fmsrcimp.cxx +++ b/svx/source/form/fmsrcimp.cxx @@ -239,10 +239,9 @@ sal_Bool FmSearchEngine::MoveCursor() catch(::com::sun::star::sdbc::SQLException const& e) { #if OSL_DEBUG_LEVEL > 0 - OStringBuffer sDebugMessage(RTL_CONSTASCII_STRINGPARAM( - "FmSearchEngine::MoveCursor : catched a DatabaseException (")); + OStringBuffer sDebugMessage("FmSearchEngine::MoveCursor : catched a DatabaseException ("); sDebugMessage.append(OUStringToOString(e.SQLState, RTL_TEXTENCODING_ASCII_US)); - sDebugMessage.append(RTL_CONSTASCII_STRINGPARAM(") !")); + sDebugMessage.append(") !"); OSL_FAIL(sDebugMessage.getStr()); #else (void)e; @@ -252,10 +251,9 @@ sal_Bool FmSearchEngine::MoveCursor() catch(Exception const& e) { #if OSL_DEBUG_LEVEL > 0 - OStringBuffer sDebugMessage(RTL_CONSTASCII_STRINGPARAM( - "FmSearchEngine::MoveCursor : catched an Exception (")); + OStringBuffer sDebugMessage("FmSearchEngine::MoveCursor : catched an Exception ("); sDebugMessage.append(OUStringToOString(e.Message, RTL_TEXTENCODING_ASCII_US)); - sDebugMessage.append(RTL_CONSTASCII_STRINGPARAM(") !")); + sDebugMessage.append(") !"); OSL_FAIL(sDebugMessage.getStr()); #else (void)e; diff --git a/svx/source/svdraw/svdedtv.cxx b/svx/source/svdraw/svdedtv.cxx index 99db00d20a6d..a872d426bd8c 100644 --- a/svx/source/svdraw/svdedtv.cxx +++ b/svx/source/svdraw/svdedtv.cxx @@ -931,21 +931,19 @@ void SdrEditView::CopyMarkedObj() if(0L != nCloneErrCnt) { #ifdef DBG_UTIL - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "SdrEditView::CopyMarkedObj(): Error when cloning ")); + OStringBuffer aStr("SdrEditView::CopyMarkedObj(): Error when cloning "); if(nCloneErrCnt == 1) { - aStr.append(RTL_CONSTASCII_STRINGPARAM("a drawing object.")); + aStr.append("a drawing object."); } else { aStr.append(static_cast<sal_Int32>(nCloneErrCnt)); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" drawing objects.")); + aStr.append(" drawing objects."); } - aStr.append(RTL_CONSTASCII_STRINGPARAM( - " This object's/These objects's connections will not be copied.")); + aStr.append(" This object's/These objects's connections will not be copied."); OSL_FAIL(aStr.getStr()); #endif } diff --git a/svx/source/svdraw/svdpage.cxx b/svx/source/svdraw/svdpage.cxx index addf15824787..d1deac329cbc 100644 --- a/svx/source/svdraw/svdpage.cxx +++ b/svx/source/svdraw/svdpage.cxx @@ -195,21 +195,19 @@ void SdrObjList::CopyObjects(const SdrObjList& rSrcList) } } else { #ifdef DBG_UTIL - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "SdrObjList::operator=(): Error when cloning ")); + OStringBuffer aStr("SdrObjList::operator=(): Error when cloning "); if(nCloneErrCnt == 1) { - aStr.append(RTL_CONSTASCII_STRINGPARAM("a drawing object.")); + aStr.append("a drawing object."); } else { aStr.append(static_cast<sal_Int32>(nCloneErrCnt)); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" drawing objects.")); + aStr.append(" drawing objects."); } - aStr.append(RTL_CONSTASCII_STRINGPARAM( - " Not copying connectors.")); + aStr.append(" Not copying connectors."); OSL_FAIL(aStr.getStr()); #endif diff --git a/svx/source/svdraw/svdxcgv.cxx b/svx/source/svdraw/svdxcgv.cxx index 147637da393d..374f9a9f4e26 100644 --- a/svx/source/svdraw/svdxcgv.cxx +++ b/svx/source/svdraw/svdxcgv.cxx @@ -369,22 +369,19 @@ sal_Bool SdrExchangeView::Paste(const SdrModel& rMod, const Point& rPos, SdrObjL if(0L != nCloneErrCnt) { #ifdef DBG_UTIL - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "SdrExchangeView::Paste(): Error when cloning ")); + OStringBuffer aStr("SdrExchangeView::Paste(): Error when cloning "); if(nCloneErrCnt == 1) { - aStr.append(RTL_CONSTASCII_STRINGPARAM( - "a drawing object.")); + aStr.append("a drawing object."); } else { aStr.append(static_cast<sal_Int32>(nCloneErrCnt)); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" drawing objects.")); + aStr.append(" drawing objects."); } - aStr.append(RTL_CONSTASCII_STRINGPARAM( - " Not copying object connectors.")); + aStr.append(" Not copying object connectors."); OSL_FAIL(aStr.getStr()); #endif @@ -787,22 +784,19 @@ SdrModel* SdrExchangeView::GetMarkedObjModel() const if(0L != nCloneErrCnt) { #ifdef DBG_UTIL - OStringBuffer aStr(RTL_CONSTASCII_STRINGPARAM( - "SdrExchangeView::GetMarkedObjModel(): Error when cloning ")); + OStringBuffer aStr("SdrExchangeView::GetMarkedObjModel(): Error when cloning "); if(nCloneErrCnt == 1) { - aStr.append(RTL_CONSTASCII_STRINGPARAM( - "a drawing object.")); + aStr.append("a drawing object."); } else { aStr.append(static_cast<sal_Int32>(nCloneErrCnt)); - aStr.append(RTL_CONSTASCII_STRINGPARAM(" drawing objects.")); + aStr.append(" drawing objects."); } - aStr.append(RTL_CONSTASCII_STRINGPARAM( - " Not copying object connectors.")); + aStr.append(" Not copying object connectors."); OSL_FAIL(aStr.getStr()); #endif diff --git a/svx/source/xml/xmlgrhlp.cxx b/svx/source/xml/xmlgrhlp.cxx index b325dc016d31..95f5639157dd 100644 --- a/svx/source/xml/xmlgrhlp.cxx +++ b/svx/source/xml/xmlgrhlp.cxx @@ -719,10 +719,9 @@ void SvXMLGraphicHelper::ImplInsertGraphicURL( const OUString& rURLStr, sal_uInt #if OSL_DEBUG_LEVEL > 0 else { - OStringBuffer sMessage( - RTL_CONSTASCII_STRINGPARAM("graphic object with ID '")); + OStringBuffer sMessage("graphic object with ID '"); sMessage.append(aAsciiObjectID). - append(RTL_CONSTASCII_STRINGPARAM("' has an unknown type")); + append("' has an unknown type"); OSL_ENSURE( false, sMessage.getStr() ); } #endif diff --git a/sw/source/filter/html/htmlfldw.cxx b/sw/source/filter/html/htmlfldw.cxx index 4009363370d1..29c9c7646bd5 100644 --- a/sw/source/filter/html/htmlfldw.cxx +++ b/sw/source/filter/html/htmlfldw.cxx @@ -275,7 +275,7 @@ static Writer& OutHTML_SwField( Writer& rWrt, const SwField* pFld, if( !aName.isEmpty() ) { sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_name). - append(RTL_CONSTASCII_STRINGPARAM("=\"")); + append("=\""); rWrt.Strm() << sOut.makeStringAndClear().getStr(); HTMLOutFuncs::Out_String( rWrt.Strm(), aName, rHTMLWrt.eDestEnc, &rHTMLWrt.aNonConvertableCharacters ); sOut.append('\"'); @@ -283,7 +283,7 @@ static Writer& OutHTML_SwField( Writer& rWrt, const SwField* pFld, if( !aValue.isEmpty() ) { sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_value). - append(RTL_CONSTASCII_STRINGPARAM("=\"")); + append("=\""); rWrt.Strm() << sOut.makeStringAndClear().getStr(); HTMLOutFuncs::Out_String( rWrt.Strm(), aValue, rHTMLWrt.eDestEnc, &rHTMLWrt.aNonConvertableCharacters ); sOut.append('\"'); diff --git a/sw/source/filter/html/htmlforw.cxx b/sw/source/filter/html/htmlforw.cxx index d90d97cd3599..82e739820d70 100644 --- a/sw/source/filter/html/htmlforw.cxx +++ b/sw/source/filter/html/htmlforw.cxx @@ -979,7 +979,7 @@ Writer& OutHTML_DrawFrmFmtAsControl( Writer& rWrt, !((OUString*)aTmp.getValue())->isEmpty() ) { sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_name). - append(RTL_CONSTASCII_STRINGPARAM("=\"")); + append("=\""); rWrt.Strm() << sOut.makeStringAndClear().getStr(); HTMLOutFuncs::Out_String( rWrt.Strm(), *(OUString*)aTmp.getValue(), rHTMLWrt.eDestEnc, &rHTMLWrt.aNonConvertableCharacters ); @@ -996,7 +996,7 @@ Writer& OutHTML_DrawFrmFmtAsControl( Writer& rWrt, if( !sValue.isEmpty() || bEmptyValue ) { sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_value).append( - RTL_CONSTASCII_STRINGPARAM("=\"")); + "=\""); rWrt.Strm() << sOut.makeStringAndClear().getStr(); HTMLOutFuncs::Out_String( rWrt.Strm(), sValue, rHTMLWrt.eDestEnc, &rHTMLWrt.aNonConvertableCharacters ); sOut.append('\"'); @@ -1012,7 +1012,7 @@ Writer& OutHTML_DrawFrmFmtAsControl( Writer& rWrt, !((OUString*)aTmp.getValue())->isEmpty() ) { sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_src). - append(RTL_CONSTASCII_STRINGPARAM("=\"")); + append("=\""); rWrt.Strm() << sOut.makeStringAndClear().getStr(); HTMLOutFuncs::Out_String( rWrt.Strm(), @@ -1263,7 +1263,7 @@ Writer& OutHTML_DrawFrmFmtAsControl( Writer& rWrt, if( !sVal.isEmpty() || bEmptyVal ) { sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_value). - append(RTL_CONSTASCII_STRINGPARAM("=\"")); + append("=\""); rWrt.Strm() << sOut.makeStringAndClear().getStr(); HTMLOutFuncs::Out_String( rWrt.Strm(), sVal, rHTMLWrt.eDestEnc, &rHTMLWrt.aNonConvertableCharacters ); diff --git a/sw/source/filter/html/wrthtml.cxx b/sw/source/filter/html/wrthtml.cxx index f903c331dc5a..45fe084b1a3d 100644 --- a/sw/source/filter/html/wrthtml.cxx +++ b/sw/source/filter/html/wrthtml.cxx @@ -525,7 +525,7 @@ static void lcl_html_OutSectionStartTag( SwHTMLWriter& rHTMLWrt, if( !rName.isEmpty() && !bContinued ) { sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_id). - append(RTL_CONSTASCII_STRINGPARAM("=\"")); + append("=\""); rHTMLWrt.Strm() << sOut.makeStringAndClear().getStr(); HTMLOutFuncs::Out_String( rHTMLWrt.Strm(), rName, rHTMLWrt.eDestEnc, &rHTMLWrt.aNonConvertableCharacters ); sOut.append('\"'); @@ -538,7 +538,7 @@ static void lcl_html_OutSectionStartTag( SwHTMLWriter& rHTMLWrt, if( FILE_LINK_SECTION == rSection.GetType() ) { sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_href). - append(RTL_CONSTASCII_STRINGPARAM("=\"")); + append("=\""); rHTMLWrt.Strm() << sOut.makeStringAndClear().getStr(); const OUString& aFName = rSection.GetLinkFileName(); diff --git a/vcl/unx/generic/printer/jobdata.cxx b/vcl/unx/generic/printer/jobdata.cxx index 47bb0f4d4b57..3526138002db 100644 --- a/vcl/unx/generic/printer/jobdata.cxx +++ b/vcl/unx/generic/printer/jobdata.cxx @@ -114,26 +114,26 @@ bool JobData::getStreamBuffer( void*& pData, int& bytes ) SvMemoryStream aStream; // write header job data - aStream.WriteLine(OString(RTL_CONSTASCII_STRINGPARAM("JobData 1"))); + aStream.WriteLine(OString("JobData 1")); OStringBuffer aLine; - aLine.append(RTL_CONSTASCII_STRINGPARAM("printer=")); + aLine.append("printer="); aLine.append(OUStringToOString(m_aPrinterName, RTL_TEXTENCODING_UTF8)); aStream.WriteLine(aLine.makeStringAndClear()); - aLine.append(RTL_CONSTASCII_STRINGPARAM("orientation=")); + aLine.append("orientation="); if (m_eOrientation == orientation::Landscape) - aLine.append(RTL_CONSTASCII_STRINGPARAM("Landscape")); + aLine.append("Landscape"); else - aLine.append(RTL_CONSTASCII_STRINGPARAM("Portrait")); + aLine.append("Portrait"); aStream.WriteLine(aLine.makeStringAndClear()); - aLine.append(RTL_CONSTASCII_STRINGPARAM("copies=")); + aLine.append("copies="); aLine.append(static_cast<sal_Int32>(m_nCopies)); aStream.WriteLine(aLine.makeStringAndClear()); - aLine.append(RTL_CONSTASCII_STRINGPARAM("margindajustment=")); + aLine.append("margindajustment="); aLine.append(static_cast<sal_Int32>(m_nLeftMarginAdjust)); aLine.append(','); aLine.append(static_cast<sal_Int32>(m_nRightMarginAdjust)); @@ -143,19 +143,19 @@ bool JobData::getStreamBuffer( void*& pData, int& bytes ) aLine.append(static_cast<sal_Int32>(m_nBottomMarginAdjust)); aStream.WriteLine(aLine.makeStringAndClear()); - aLine.append(RTL_CONSTASCII_STRINGPARAM("colordepth=")); + aLine.append("colordepth="); aLine.append(static_cast<sal_Int32>(m_nColorDepth)); aStream.WriteLine(aLine.makeStringAndClear()); - aLine.append(RTL_CONSTASCII_STRINGPARAM("pslevel=")); + aLine.append("pslevel="); aLine.append(static_cast<sal_Int32>(m_nPSLevel)); aStream.WriteLine(aLine.makeStringAndClear()); - aLine.append(RTL_CONSTASCII_STRINGPARAM("pdfdevice=")); + aLine.append("pdfdevice="); aLine.append(static_cast<sal_Int32>(m_nPDFDevice)); aStream.WriteLine(aLine.makeStringAndClear()); - aLine.append(RTL_CONSTASCII_STRINGPARAM("colordevice=")); + aLine.append("colordevice="); aLine.append(static_cast<sal_Int32>(m_nColorDevice)); aStream.WriteLine(aLine.makeStringAndClear()); |