[Libreoffice-commits] core.git: 2 commits - include/tools lotuswordpro/source sc/source sw/inc sw/source tools/source

Caolán McNamara caolanm at redhat.com
Tue Oct 1 06:19:47 PDT 2013


 include/tools/string.hxx                     |    3 -
 lotuswordpro/source/filter/lwpnumericfmt.hxx |   13 ++--
 sc/source/filter/excel/excform.cxx           |    6 +-
 sc/source/filter/excel/excform8.cxx          |    4 -
 sc/source/filter/excel/namebuff.cxx          |    8 +-
 sc/source/filter/inc/namebuff.hxx            |   24 ++++----
 sc/source/ui/docshell/impex.cxx              |   24 ++++----
 sc/source/ui/miscdlgs/crnrdlg.cxx            |   20 +++----
 sw/inc/calc.hxx                              |   10 +--
 sw/source/core/bastyp/calc.cxx               |   44 +++++++--------
 sw/source/core/crsr/crstrvl.cxx              |    3 -
 sw/source/core/doc/docdraw.cxx               |   22 +++----
 sw/source/core/view/vprint.cxx               |    8 +-
 sw/source/filter/html/htmlform.cxx           |   16 ++---
 sw/source/filter/html/htmlftn.cxx            |   34 ++++++------
 sw/source/filter/ww8/writerwordglue.cxx      |   13 +---
 sw/source/filter/ww8/ww8par5.cxx             |    5 +
 sw/source/ui/index/cntex.cxx                 |   36 ++++--------
 sw/source/ui/misc/outline.cxx                |    3 -
 tools/source/string/strascii.cxx             |   75 ---------------------------
 20 files changed, 141 insertions(+), 230 deletions(-)

New commits:
commit d05a9ae25e4a397834330d868b68d92ca919e33b
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Oct 1 13:39:46 2013 +0100

    Related: fdo#38838 remove UniString::AssignAscii
    
    Change-Id: I263ef2594080ff7d47d5499c2b62e60e1689d2d6

diff --git a/include/tools/string.hxx b/include/tools/string.hxx
index 7f0e8d9..5ca0047 100644
--- a/include/tools/string.hxx
+++ b/include/tools/string.hxx
@@ -180,8 +180,7 @@ public:
     UniString&          Assign( sal_Unicode c );
     inline UniString & Assign(char c) // ...but allow "Assign('a')"
         { return Assign(static_cast< sal_Unicode >(c)); }
-    UniString&          AssignAscii( const sal_Char* pAsciiStr );
-    UniString&          AssignAscii( const sal_Char* pAsciiStr, xub_StrLen nLen );
+
     UniString&          operator =( const UniString& rStr )
                             { return Assign( rStr ); }
     UniString&          operator =( const OUString& rStr )
diff --git a/sc/source/filter/excel/excform.cxx b/sc/source/filter/excel/excform.cxx
index 0c34957..238a881 100644
--- a/sc/source/filter/excel/excform.cxx
+++ b/sc/source/filter/excel/excform.cxx
@@ -231,7 +231,7 @@ ConvErr ExcelToSc::Convert( const ScTokenArray*& pErgebnis, XclImpStream& aIn, s
     sal_uInt16          nUINT16;
     sal_Int16           nINT16;
     double          fDouble;
-    String          aString;
+    OUString        aString;
     sal_Bool            bError = false;
     sal_Bool            bArrayFormula = false;
     TokenId         nMerk0;
@@ -693,7 +693,7 @@ ConvErr ExcelToSc::Convert( const ScTokenArray*& pErgebnis, XclImpStream& aIn, s
             case 0x58:
             case 0x78:
             case 0x38: // Command-Equivalent Function           [333    ]
-                aString.AssignAscii( "COMM_EQU_FUNC" );
+                aString = "COMM_EQU_FUNC";
                 aIn >> nByte;
                 aString += OUString::number( nByte );
                 aIn >> nByte;
@@ -1779,7 +1779,7 @@ void ExcelToSc::ReadExtensionArray( unsigned int n, XclImpStream& aIn )
     sal_uInt8        nByte;
     sal_uInt16      nUINT16;
     double      fDouble;
-    String      aString;
+    OUString    aString;
     ScMatrix*   pMatrix;
 
     aIn >> nByte >> nUINT16;
diff --git a/sc/source/filter/excel/excform8.cxx b/sc/source/filter/excel/excform8.cxx
index 043b3f4..aa5a98f 100644
--- a/sc/source/filter/excel/excform8.cxx
+++ b/sc/source/filter/excel/excform8.cxx
@@ -143,7 +143,7 @@ ConvErr ExcelToSc8::Convert( const ScTokenArray*& rpTokArray, XclImpStream& aIn,
     sal_uInt8                   nOp, nLen, nByte;
     sal_uInt16                  nUINT16;
     double                  fDouble;
-    String                  aString;
+    OUString                aString;
     sal_Bool                    bError = false;
     sal_Bool                    bArrayFormula = false;
     TokenId                 nMerk0;
@@ -634,7 +634,7 @@ ConvErr ExcelToSc8::Convert( const ScTokenArray*& rpTokArray, XclImpStream& aIn,
             case 0x58:
             case 0x78:
             case 0x38: // Command-Equivalent Function           [333    ]
-                aString.AssignAscii( "COMM_EQU_FUNC" );
+                aString = "COMM_EQU_FUNC";
                 aIn >> nByte;
                 aString += OUString::number( nByte );
                 aIn >> nByte;
diff --git a/sc/source/filter/excel/namebuff.cxx b/sc/source/filter/excel/namebuff.cxx
index 4c75d64..b359297 100644
--- a/sc/source/filter/excel/namebuff.cxx
+++ b/sc/source/filter/excel/namebuff.cxx
@@ -31,10 +31,10 @@
 
 #include <string.h>
 
-sal_uInt32 StringHashEntry::MakeHashCode( const String& r )
+sal_uInt32 StringHashEntry::MakeHashCode( const OUString& r )
 {
-    sal_uInt32                 n = 0;
-    const sal_Unicode*              pAkt = r.GetBuffer();
+    sal_uInt32             n = 0;
+    const sal_Unicode*     pAkt = r.getStr();
     sal_Unicode            cAkt = *pAkt;
 
     while( cAkt )
@@ -60,7 +60,7 @@ NameBuffer::~NameBuffer()
 
 
 //void NameBuffer::operator <<( const SpString &rNewString )
-void NameBuffer::operator <<( const String &rNewString )
+void NameBuffer::operator <<( const OUString &rNewString )
 {
     OSL_ENSURE( maHashes.size() + nBase < 0xFFFF,
         "*NameBuffer::GetLastIndex(): Ich hab' die Nase voll!" );
diff --git a/sc/source/filter/inc/namebuff.hxx b/sc/source/filter/inc/namebuff.hxx
index 97aebc1..edea040 100644
--- a/sc/source/filter/inc/namebuff.hxx
+++ b/sc/source/filter/inc/namebuff.hxx
@@ -20,7 +20,7 @@
 #ifndef SC_NAMEBUFF_HXX
 #define SC_NAMEBUFF_HXX
 
-#include <tools/string.hxx>
+#include <rtl/ustring.hxx>
 #include "compiler.hxx"
 #include "root.hxx"
 #include "xiroot.hxx"
@@ -41,15 +41,15 @@ class StringHashEntry
 {
 private:
     friend class NameBuffer;
-    String          aString;
-    sal_uInt32          nHash;
+    OUString          aString;
+    sal_uInt32        nHash;
 
-    static sal_uInt32   MakeHashCode( const String& );
+    static sal_uInt32   MakeHashCode( const OUString& );
 public:
-    inline          StringHashEntry( const String& );
+    inline          StringHashEntry( const OUString& );
     inline          StringHashEntry( void );
     inline void     operator =( const sal_Char* );
-    inline void     operator =( const String& );
+    inline void     operator =( const OUString& );
     inline void     operator =( const StringHashEntry& );
     inline sal_Bool     operator ==( const StringHashEntry& ) const;
 };
@@ -60,7 +60,7 @@ inline StringHashEntry::StringHashEntry( void )
 }
 
 
-inline StringHashEntry::StringHashEntry( const String& r ) : aString( r )
+inline StringHashEntry::StringHashEntry( const OUString& r ) : aString( r )
 {
     nHash = MakeHashCode( r );
 }
@@ -68,12 +68,12 @@ inline StringHashEntry::StringHashEntry( const String& r ) : aString( r )
 
 inline void StringHashEntry::operator =( const sal_Char* p )
 {
-    aString.AssignAscii( p );
+    aString = OUString(p, strlen(p), RTL_TEXTENCODING_ASCII_US);
     nHash = MakeHashCode( aString );
 }
 
 
-inline void StringHashEntry::operator =( const String& r )
+inline void StringHashEntry::operator =( const OUString& r )
 {
     aString = r;
     nHash = MakeHashCode( r );
@@ -106,10 +106,10 @@ public:
     inline                  NameBuffer( RootData*, sal_uInt16 nNewBase );
 
     virtual                 ~NameBuffer();
-    inline const String*    Get( sal_uInt16 nIndex ) const;
+    inline const OUString*  Get( sal_uInt16 nIndex ) const;
     inline sal_uInt16       GetLastIndex() const;
     inline void             SetBase( sal_uInt16 nNewBase = 0 );
-    void                    operator <<( const String& rNewString );
+    void                    operator <<( const OUString& rNewString );
 };
 
 inline NameBuffer::NameBuffer( RootData* p ) : ExcRoot( p )
@@ -124,7 +124,7 @@ inline NameBuffer::NameBuffer( RootData* p, sal_uInt16 nNewBase ) : ExcRoot( p )
 }
 
 
-inline const String* NameBuffer::Get ( sal_uInt16 n ) const
+inline const OUString* NameBuffer::Get ( sal_uInt16 n ) const
 {
     if( n < nBase || n >= maHashes.size() )
         return NULL;
diff --git a/sc/source/ui/docshell/impex.cxx b/sc/source/ui/docshell/impex.cxx
index d46a1df..5557f9b 100644
--- a/sc/source/ui/docshell/impex.cxx
+++ b/sc/source/ui/docshell/impex.cxx
@@ -1961,7 +1961,7 @@ bool ScImportExport::Doc2Sylk( SvStream& rStrm )
     {
         for (nCol = nStartCol; nCol <= nEndCol; nCol++)
         {
-            String aBufStr;
+            OUString aBufStr;
             double nVal;
             bool bForm = false;
             SCROW r = nRow - nStartRow + 1;
@@ -1986,11 +1986,11 @@ bool ScImportExport::Doc2Sylk( SvStream& rStrm )
                             rtl_math_StringFormat_Automatic,
                             rtl_math_DecimalPlaces_Max, '.', true );
 
-                    aBufStr.AssignAscii(RTL_CONSTASCII_STRINGPARAM( "C;X" ));
+                    aBufStr = "C;X";
                     aBufStr += OUString::number( c );
-                    aBufStr.AppendAscii(RTL_CONSTASCII_STRINGPARAM( ";Y" ));
+                    aBufStr += ";Y";
                     aBufStr += OUString::number( r );
-                    aBufStr.AppendAscii(RTL_CONSTASCII_STRINGPARAM( ";K" ));
+                    aBufStr += ";K";
                     aBufStr += aValStr;
                     lcl_WriteSimpleString( rStrm, aBufStr );
                     goto checkformula;
@@ -2001,11 +2001,11 @@ bool ScImportExport::Doc2Sylk( SvStream& rStrm )
                     aCellStr = pDoc->GetString(nCol, nRow, aRange.aStart.Tab());
                     aCellStr.SearchAndReplaceAll( OUString('\n'), OUString(SYLK_LF) );
 
-                    aBufStr.AssignAscii(RTL_CONSTASCII_STRINGPARAM( "C;X" ));
+                    aBufStr = "C;X";
                     aBufStr += OUString::number( c );
-                    aBufStr.AppendAscii(RTL_CONSTASCII_STRINGPARAM( ";Y" ));
+                    aBufStr += ";Y";
                     aBufStr += OUString::number( r );
-                    aBufStr.AppendAscii(RTL_CONSTASCII_STRINGPARAM( ";K" ));
+                    aBufStr += ";K";
                     lcl_WriteSimpleString( rStrm, aBufStr );
                     lcl_WriteString( rStrm, aCellStr, '"', ';' );
 
@@ -2047,9 +2047,9 @@ bool ScImportExport::Doc2Sylk( SvStream& rStrm )
                                 pFCell->GetMatColsRows( nC, nR );
                                 nC += c - 1;
                                 nR += r - 1;
-                                aPrefix.AssignAscii( RTL_CONSTASCII_STRINGPARAM( ";R" ) );
+                                aPrefix = ";R";
                                 aPrefix += OUString::number( nR );
-                                aPrefix.AppendAscii( RTL_CONSTASCII_STRINGPARAM( ";C" ) );
+                                aPrefix += ";C";
                                 aPrefix += OUString::number( nC );
                                 aPrefix.AppendAscii( RTL_CONSTASCII_STRINGPARAM( ";M" ) );
                             }
@@ -2058,15 +2058,15 @@ bool ScImportExport::Doc2Sylk( SvStream& rStrm )
                             {   // diff expression with 'I' M$-extension
                                 ScAddress aPos;
                                 pFCell->GetMatrixOrigin( aPos );
-                                aPrefix.AssignAscii( RTL_CONSTASCII_STRINGPARAM( ";I;R" ) );
+                                aPrefix = ";I;R";
                                 aPrefix += OUString::number( aPos.Row() - nStartRow + 1 );
-                                aPrefix.AppendAscii( RTL_CONSTASCII_STRINGPARAM( ";C" ) );
+                                aPrefix += ";C";
                                 aPrefix += OUString::number( aPos.Col() - nStartCol + 1 );
                             }
                             break;
                             default:
                                 // formula Expression
-                                aPrefix.AssignAscii( RTL_CONSTASCII_STRINGPARAM( ";E" ) );
+                                aPrefix = ";E";
                         }
                         lcl_WriteSimpleString( rStrm, aPrefix );
                         if ( aCellStr.Len() )
diff --git a/sc/source/ui/miscdlgs/crnrdlg.cxx b/sc/source/ui/miscdlgs/crnrdlg.cxx
index e017385..f0f2cc4 100644
--- a/sc/source/ui/miscdlgs/crnrdlg.cxx
+++ b/sc/source/ui/miscdlgs/crnrdlg.cxx
@@ -493,7 +493,7 @@ void ScColRowNameRangesDlg::UpdateNames()
     SCROW nRow2;
     SCTAB nTab2;
     String rString;
-    String strShow;
+    OUString strShow;
     const ScAddress::Details aDetails(pDoc->GetAddressConvention());
 
     String aString;
@@ -518,23 +518,23 @@ void ScColRowNameRangesDlg::UpdateNames()
             SCCOL q=nCol1+3;
             if(q>nCol2) q=nCol2;
             //@008 Baue String zusammen
-            strShow.AssignAscii(RTL_CONSTASCII_STRINGPARAM(" ["));
+            strShow = " [";
             if(pDoc!=NULL)
             {
                 rString = pDoc->GetString(nCol1, nRow1, nTab1);
-                strShow +=rString;
+                strShow += rString;
                 for(SCCOL i=nCol1+1;i<=q;i++)
                 {
-                    strShow.AppendAscii(RTL_CONSTASCII_STRINGPARAM(", "));
+                    strShow += ", ";
                     rString = pDoc->GetString(i, nRow1, nTab1);
                     strShow += rString;
                 }
             }
             if(q<nCol2) // Zu lang? Ergaenzen um ",..."
             {
-                strShow.AppendAscii(RTL_CONSTASCII_STRINGPARAM(", ..."));
+                strShow += ", ...";
             }
-            strShow += ']';
+            strShow += "]";
 
             //@008 String einfuegen in Listbox
             String aInsStr = aString;
@@ -564,23 +564,23 @@ void ScColRowNameRangesDlg::UpdateNames()
                                             nCol2, nRow2, nTab2 );
             SCROW q=nRow1+3;
             if(q>nRow2) q=nRow2;
-            strShow.AssignAscii(RTL_CONSTASCII_STRINGPARAM(" ["));
+            strShow = " [";
             if(pDoc!=NULL)
             {
                 rString = pDoc->GetString(nCol1, nRow1, nTab1);
                 strShow += rString;
                 for(SCROW i=nRow1+1;i<=q;i++)
                 {
-                    strShow.AppendAscii(RTL_CONSTASCII_STRINGPARAM(", "));
+                    strShow += ", ";
                     rString = pDoc->GetString(nCol1, i, nTab1);
                     strShow += rString;
                 }
             }
             if(q<nRow2)
             {
-                strShow.AppendAscii(RTL_CONSTASCII_STRINGPARAM(", ..."));
+                strShow += ", ...";
             }
-            strShow += ']';
+            strShow += "]";
 
             String aInsStr = aString;
             aInsStr += strShow;
diff --git a/sw/inc/calc.hxx b/sw/inc/calc.hxx
index 4b98c2d..4051e65 100644
--- a/sw/inc/calc.hxx
+++ b/sw/inc/calc.hxx
@@ -138,9 +138,9 @@ public:
  ******************************************************************************/
 struct SwHash
 {
-            SwHash( const String& rStr );
+    SwHash( const OUString& rStr );
     virtual ~SwHash();
-    String  aStr;
+    OUString aStr;
     SwHash *pNext;
 };
 
@@ -149,18 +149,18 @@ struct SwCalcExp : public SwHash
     SwSbxValue  nValue;
     const SwFieldType* pFldType;
 
-    SwCalcExp( const String& rStr, const SwSbxValue& rVal,
+    SwCalcExp( const OUString& rStr, const SwSbxValue& rVal,
                 const SwFieldType* pFldType = 0 );
 };
 
-SwHash* Find( const String& rSrch, SwHash** ppTable,
+SwHash* Find( const OUString& rSrch, SwHash** ppTable,
                 sal_uInt16 nTblSize, sal_uInt16* pPos = 0 );
 
 void DeleteHashTable( SwHash** ppTable, sal_uInt16 nTblSize );
 
 // if _CalcOp != 0, this is a valid operator
 struct _CalcOp;
-_CalcOp* FindOperator( const String& rSearch );
+_CalcOp* FindOperator( const OUString& rSearch );
 
 /******************************************************************************
  *                               class SwCalc
diff --git a/sw/source/core/bastyp/calc.cxx b/sw/source/core/bastyp/calc.cxx
index bc6f4a6..24b0830 100644
--- a/sw/source/core/bastyp/calc.cxx
+++ b/sw/source/core/bastyp/calc.cxx
@@ -91,7 +91,7 @@ struct _CalcOp
 {
     union{
         const sal_Char* pName;
-        const String* pUName;
+        const OUString* pUName;
     };
     SwCalcOper eOp;
 };
@@ -157,16 +157,16 @@ static int SAL_CALL OperatorCompare( const void *pFirst, const void *pSecond)
     if( CALC_NAME == ((_CalcOp*)pFirst)->eOp )
     {
         if( CALC_NAME == ((_CalcOp*)pSecond)->eOp )
-            nRet = ((_CalcOp*)pFirst)->pUName->CompareTo(
+            nRet = ((_CalcOp*)pFirst)->pUName->compareTo(
                    *((_CalcOp*)pSecond)->pUName );
         else
-            nRet = ((_CalcOp*)pFirst)->pUName->CompareToAscii(
+            nRet = ((_CalcOp*)pFirst)->pUName->compareToAscii(
                    ((_CalcOp*)pSecond)->pName );
     }
     else
     {
         if( CALC_NAME == ((_CalcOp*)pSecond)->eOp )
-            nRet = -1 * ((_CalcOp*)pSecond)->pUName->CompareToAscii(
+            nRet = -1 * ((_CalcOp*)pSecond)->pUName->compareToAscii(
                         ((_CalcOp*)pFirst)->pName );
         else
             nRet = strcmp( ((_CalcOp*)pFirst)->pName,
@@ -176,7 +176,7 @@ static int SAL_CALL OperatorCompare( const void *pFirst, const void *pSecond)
 }
 }// extern "C"
 
-_CalcOp* FindOperator( const String& rSrch )
+_CalcOp* FindOperator( const OUString& rSrch )
 {
     _CalcOp aSrch;
     aSrch.pUName = &rSrch;
@@ -189,13 +189,13 @@ _CalcOp* FindOperator( const String& rSrch )
                               OperatorCompare );
 }
 
-SwHash* Find( const String& rStr, SwHash** ppTable,
+SwHash* Find( const OUString& rStr, SwHash** ppTable,
               sal_uInt16 nTblSize, sal_uInt16* pPos )
 {
     sal_uLong ii = 0;
-    for( xub_StrLen n = 0; n < rStr.Len(); ++n )
+    for( sal_Int32 n = 0; n < rStr.getLength(); ++n )
     {
-        ii = ii << 1 ^ rStr.GetChar( n );
+        ii = ii << 1 ^ rStr[n];
     }
     ii %= nTblSize;
 
@@ -241,7 +241,7 @@ SwCalc::SwCalc( SwDoc& rD )
     nListPor( 0 ),
     eError( CALC_NOERR )
 {
-    aErrExpr.aStr.AssignAscii( "~C_ERR~" );
+    aErrExpr.aStr = "~C_ERR~";
     memset( VarTable, 0, sizeof(VarTable) );
     LanguageType eLang = GetDocAppScriptLang( rDoc );
 
@@ -333,7 +333,7 @@ SwCalc::SwCalc( SwDoc& rD )
 
     for( n = 0; n < 25; ++n )
     {
-        sTmpStr.AssignAscii( sNTypeTab[ n ] );
+        sTmpStr = OUString::createFromAscii(sNTypeTab[n]);
         VarTable[ aHashValue[ n ] ] = new SwCalcExp( sTmpStr, nVal, 0 );
     }
 
@@ -358,7 +358,7 @@ SwCalc::SwCalc( SwDoc& rD )
                                         (String)rUserOptions.GetToken( aAdrToken[ n ] ));
 
     nVal.PutString( (String)rUserOptions.GetToken( aAdrToken[ 11 ] ));
-    sTmpStr.AssignAscii( sNTypeTab[ 25 ] );
+    sTmpStr = OUString::createFromAscii(sNTypeTab[25]);
     VarTable[ aHashValue[ 25 ] ]->pNext = new SwCalcExp( sTmpStr, nVal, 0 );
 
 } // SwCalc::SwCalc
@@ -443,7 +443,7 @@ String SwCalc::GetStrResult( double nValue, sal_Bool )
 
 SwCalcExp* SwCalc::VarInsert( const String &rStr )
 {
-    String aStr = pCharClass->lowercase( rStr );
+    OUString aStr = pCharClass->lowercase( rStr );
     return VarLook( aStr, 1 );
 }
 
@@ -452,7 +452,7 @@ SwCalcExp* SwCalc::VarLook( const String& rStr, sal_uInt16 ins )
     aErrExpr.nValue.SetVoidValue(false);
 
     sal_uInt16 ii = 0;
-    String aStr = pCharClass->lowercase( rStr );
+    OUString aStr = pCharClass->lowercase( rStr );
 
     SwHash* pFnd = Find( aStr, VarTable, TBLSZ, &ii );
 
@@ -608,7 +608,7 @@ void SwCalc::VarChange( const String& rStr, double nValue )
 
 void SwCalc::VarChange( const String& rStr, const SwSbxValue& rValue )
 {
-    String aStr = pCharClass->lowercase( rStr );
+    OUString aStr = pCharClass->lowercase( rStr );
 
     sal_uInt16 nPos = 0;
     SwCalcExp* pFnd = (SwCalcExp*)Find( aStr, VarTable, TBLSZ, &nPos );
@@ -1566,9 +1566,9 @@ sal_Bool SwCalc::IsValidVarName( const OUString& rStr, OUString* pValidName )
     return bRet;
 }
 
-SwHash::SwHash( const String& rStr ) :
-    aStr( rStr ),
-    pNext( 0 )
+SwHash::SwHash(const OUString& rStr)
+    : aStr(rStr)
+    , pNext(0)
 {
 }
 
@@ -1584,11 +1584,11 @@ void DeleteHashTable( SwHash **ppHashTable, sal_uInt16 nCount )
     delete [] ppHashTable;
 }
 
-SwCalcExp::SwCalcExp( const String& rStr, const SwSbxValue& rVal,
-                      const SwFieldType* pType )
-    : SwHash( rStr ),
-    nValue( rVal ),
-    pFldType( pType )
+SwCalcExp::SwCalcExp(const OUString& rStr, const SwSbxValue& rVal,
+                      const SwFieldType* pType)
+    : SwHash(rStr)
+    , nValue(rVal)
+    , pFldType(pType)
 {
 }
 
diff --git a/sw/source/core/crsr/crstrvl.cxx b/sw/source/core/crsr/crstrvl.cxx
index f70e564..02372e0 100644
--- a/sw/source/core/crsr/crstrvl.cxx
+++ b/sw/source/core/crsr/crstrvl.cxx
@@ -1451,8 +1451,7 @@ sal_Bool SwCrsrShell::GetContentAtPos( const Point& rPt,
                 else
                     pTxtNd->SwCntntNode::GetAttr( aSet );
 
-                rCntntAtPos.sStr.AssignAscii(
-                                    RTL_CONSTASCII_STRINGPARAM( "Pos: (" ));
+                rCntntAtPos.sStr = "Pos: (";
                 rCntntAtPos.sStr += OUString::number( aPos.nNode.GetIndex());
                 rCntntAtPos.sStr += ':';
                 rCntntAtPos.sStr += OUString::number( aPos.nContent.GetIndex());
diff --git a/sw/source/core/doc/docdraw.cxx b/sw/source/core/doc/docdraw.cxx
index 7860d25..110fcc8 100644
--- a/sw/source/core/doc/docdraw.cxx
+++ b/sw/source/core/doc/docdraw.cxx
@@ -556,25 +556,25 @@ void SwDoc::InitDrawModel()
 
     mpDrawModel->EnableUndo( GetIDocumentUndoRedo().DoesUndo() );
 
-    String sLayerNm;
-    sLayerNm.AssignAscii(RTL_CONSTASCII_STRINGPARAM("Hell" ));
+    OUString sLayerNm;
+    sLayerNm = "Hell";
     mnHell   = mpDrawModel->GetLayerAdmin().NewLayer( sLayerNm )->GetID();
 
-    sLayerNm.AssignAscii(RTL_CONSTASCII_STRINGPARAM("Heaven" ));
+    sLayerNm = "Heaven";
     mnHeaven = mpDrawModel->GetLayerAdmin().NewLayer( sLayerNm )->GetID();
 
-    sLayerNm.AssignAscii(RTL_CONSTASCII_STRINGPARAM("Controls" ));
+    sLayerNm = "Controls";
     mnControls = mpDrawModel->GetLayerAdmin().NewLayer( sLayerNm )->GetID();
 
     // add invisible layers corresponding to the visible ones.
     {
-        sLayerNm.AssignAscii(RTL_CONSTASCII_STRINGPARAM("InvisibleHell" ));
+        sLayerNm = "InvisibleHell";
         mnInvisibleHell   = mpDrawModel->GetLayerAdmin().NewLayer( sLayerNm )->GetID();
 
-        sLayerNm.AssignAscii(RTL_CONSTASCII_STRINGPARAM("InvisibleHeaven" ));
+        sLayerNm = "InvisibleHeaven";
         mnInvisibleHeaven = mpDrawModel->GetLayerAdmin().NewLayer( sLayerNm )->GetID();
 
-        sLayerNm.AssignAscii(RTL_CONSTASCII_STRINGPARAM("InvisibleControls" ));
+        sLayerNm = "InvisibleControls";
         mnInvisibleControls = mpDrawModel->GetLayerAdmin().NewLayer( sLayerNm )->GetID();
     }
 
@@ -625,14 +625,14 @@ void SwDoc::InitDrawModel()
 /** method to notify drawing page view about the invisible layers */
 void SwDoc::NotifyInvisibleLayers( SdrPageView& _rSdrPageView )
 {
-    String sLayerNm;
-    sLayerNm.AssignAscii(RTL_CONSTASCII_STRINGPARAM("InvisibleHell" ));
+    OUString sLayerNm;
+    sLayerNm = "InvisibleHell";
     _rSdrPageView.SetLayerVisible( sLayerNm, sal_False );
 
-    sLayerNm.AssignAscii(RTL_CONSTASCII_STRINGPARAM("InvisibleHeaven" ));
+    sLayerNm = "InvisibleHeaven";
     _rSdrPageView.SetLayerVisible( sLayerNm, sal_False );
 
-    sLayerNm.AssignAscii(RTL_CONSTASCII_STRINGPARAM("InvisibleControls" ));
+    sLayerNm = "InvisibleControls";
     _rSdrPageView.SetLayerVisible( sLayerNm, sal_False );
 }
 
diff --git a/sw/source/core/view/vprint.cxx b/sw/source/core/view/vprint.cxx
index b75bed1..de21216 100644
--- a/sw/source/core/view/vprint.cxx
+++ b/sw/source/core/view/vprint.cxx
@@ -92,7 +92,7 @@ SwQueuedPaint *SwPaintQueue::pQueue = 0;
 // saves some settings from the draw view
 class SwDrawViewSave
 {
-    String sLayerNm;
+    OUString sLayerNm;
     SdrView* pDV;
     sal_Bool bPrintControls;
 public:
@@ -586,7 +586,7 @@ SwDrawViewSave::SwDrawViewSave( SdrView* pSdrView )
 {
     if ( pDV )
     {
-        sLayerNm.AssignAscii( RTL_CONSTASCII_STRINGPARAM("Controls" ) );
+        sLayerNm = "Controls";
         bPrintControls = pDV->IsLayerPrintable( sLayerNm );
     }
 }
@@ -612,8 +612,8 @@ void ViewShell::PrepareForPrint( const SwPrintData &rOptions )
     if ( HasDrawView() )
     {
         SdrView *pDrawView = GetDrawView();
-        String sLayerNm;
-        sLayerNm.AssignAscii(RTL_CONSTASCII_STRINGPARAM("Controls" ));
+        OUString sLayerNm;
+        sLayerNm = "Controls";
         // OD 09.01.2003 #i6467# - consider, if view shell belongs to page preview
         if ( !IsPreView() )
         {
diff --git a/sw/source/filter/html/htmlform.cxx b/sw/source/filter/html/htmlform.cxx
index 73989d5..d039624 100644
--- a/sw/source/filter/html/htmlform.cxx
+++ b/sw/source/filter/html/htmlform.cxx
@@ -1461,8 +1461,8 @@ void SwHTMLParser::InsertInput()
     if( !pFormImpl || !pFormImpl->GetFormComps().is() )
         return;
 
-    String sImgSrc, aId, aClass, aStyle, sText;
-    String sName;
+    String sImgSrc, aId, aClass, aStyle, sName;
+    OUString sText;
     SvxMacroTableDtor aMacroTbl;
     std::vector<OUString> aUnoMacroTbl;
     std::vector<OUString> aUnoMacroParamTbl;
@@ -1705,7 +1705,7 @@ void SwHTMLParser::InsertInput()
         }
     }
 
-    aTmp <<= OUString(sText);
+    aTmp <<= sText;
 
     Size aSz( 0, 0 );       // defaults
     Size aTextSz( 0, 0 );   // Text-Size
@@ -1780,18 +1780,18 @@ void SwHTMLParser::InsertInput()
                 break;
             case HTML_IT_SUBMIT:
                 eButtonType = FormButtonType_SUBMIT;
-                if( !sText.Len() )
-                    sText.AssignAscii( OOO_STRING_SVTOOLS_HTML_IT_submit );
+                if (sText.isEmpty())
+                    sText = OOO_STRING_SVTOOLS_HTML_IT_submit;
                 break;
             case HTML_IT_RESET:
                 eButtonType = FormButtonType_RESET;
-                if( !sText.Len() )
-                    sText.AssignAscii( OOO_STRING_SVTOOLS_HTML_IT_reset );
+                if (sText.isEmpty())
+                    sText = OOO_STRING_SVTOOLS_HTML_IT_reset;
                 break;
             default:
                 ;
             }
-            aTmp <<= OUString(sText);
+            aTmp <<= sText;
             xPropSet->setPropertyValue("Label",
                                         aTmp );
 
diff --git a/sw/source/filter/html/htmlftn.cxx b/sw/source/filter/html/htmlftn.cxx
index 94cf659..5609ebd 100644
--- a/sw/source/filter/html/htmlftn.cxx
+++ b/sw/source/filter/html/htmlftn.cxx
@@ -336,18 +336,18 @@ void SwHTMLWriter::OutFootEndNotes()
         SwTxtFtn *pTxtFtn = (*pFootEndNotes)[i];
         pFmtFtn = &pTxtFtn->GetFtn();
 
-        String sFtnName, sClass;
+        OUString sFtnName, sClass;
         if( pFmtFtn->IsEndNote() )
         {
-            sClass.AssignAscii( OOO_STRING_SVTOOLS_HTML_sdendnote );
-            sFtnName.AssignAscii( OOO_STRING_SVTOOLS_HTML_sdendnote );
-            sFtnName.Append( OUString::number((sal_Int32)(++nEndNote)) );
+            sClass = OOO_STRING_SVTOOLS_HTML_sdendnote;
+            sFtnName = OOO_STRING_SVTOOLS_HTML_sdendnote;
+            sFtnName += OUString::number((sal_Int32)(++nEndNote));
         }
         else
         {
-            sClass.AssignAscii( OOO_STRING_SVTOOLS_HTML_sdfootnote );
-            sFtnName.AssignAscii( OOO_STRING_SVTOOLS_HTML_sdfootnote );
-            sFtnName.Append( OUString::number((sal_Int32)(++nFootNote)));
+            sClass = OOO_STRING_SVTOOLS_HTML_sdfootnote;
+            sFtnName = OOO_STRING_SVTOOLS_HTML_sdfootnote;
+            sFtnName += OUString::number((sal_Int32)(++nFootNote));
         }
 
         if( bLFPossible )
@@ -427,19 +427,19 @@ void SwHTMLWriter::OutFootEndNoteSym( const SwFmtFtn& rFmtFtn,
 {
     const SwEndNoteInfo *pInfo;
 
-    String sFtnName, sClass;
+    OUString sFtnName, sClass;
     if( rFmtFtn.IsEndNote() )
     {
-        sClass.AssignAscii( OOO_STRING_SVTOOLS_HTML_sdendnote_sym );
-        sFtnName.AssignAscii( OOO_STRING_SVTOOLS_HTML_sdendnote );
-        sFtnName.Append( OUString::number((sal_Int32)nEndNote) );
+        sClass = OOO_STRING_SVTOOLS_HTML_sdendnote_sym;
+        sFtnName = OOO_STRING_SVTOOLS_HTML_sdendnote;
+        sFtnName += OUString::number((sal_Int32)nEndNote);
         pInfo = &pDoc->GetEndNoteInfo();
     }
     else
     {
-        sClass.AssignAscii( OOO_STRING_SVTOOLS_HTML_sdfootnote_sym );
-        sFtnName.AssignAscii( OOO_STRING_SVTOOLS_HTML_sdfootnote );
-        sFtnName.Append( OUString::number((sal_Int32)nFootNote));
+        sClass = OOO_STRING_SVTOOLS_HTML_sdfootnote_sym;
+        sFtnName = OOO_STRING_SVTOOLS_HTML_sdfootnote;
+        sFtnName += OUString::number((sal_Int32)nFootNote);
         pInfo = &pDoc->GetFtnInfo();
     }
 
@@ -449,13 +449,13 @@ void SwHTMLWriter::OutFootEndNoteSym( const SwFmtFtn& rFmtFtn,
         switch( nScript )
         {
         case CSS1_OUTMODE_WESTERN:
-            sClass.AppendAscii( RTL_CONSTASCII_STRINGPARAM("-western") );
+            sClass += "-western";
             break;
         case CSS1_OUTMODE_CJK:
-            sClass.AppendAscii( RTL_CONSTASCII_STRINGPARAM("-cjk") );
+            sClass += "-cjk";
             break;
         case CSS1_OUTMODE_CTL:
-            sClass.AppendAscii( RTL_CONSTASCII_STRINGPARAM("-ctl") );
+            sClass += "-ctl";
             break;
         }
     }
diff --git a/sw/source/filter/ww8/writerwordglue.cxx b/sw/source/filter/ww8/writerwordglue.cxx
index a4e6d96..8f879f3 100644
--- a/sw/source/filter/ww8/writerwordglue.cxx
+++ b/sw/source/filter/ww8/writerwordglue.cxx
@@ -48,8 +48,6 @@
 #include <breakit.hxx>
 #include <i18nlangtag/mslangid.hxx>
 
-#define ASSIGN_CONST_ASC(s) AssignAscii(s)
-
 using namespace css;
 
 namespace myImplHelpers
@@ -314,14 +312,11 @@ namespace myImplHelpers
         return pColl ? 0 : maHelper.MakeStyle(aName);
     }
 
-    String FindBestMSSubstituteFont(const String &rFont)
+    OUString FindBestMSSubstituteFont(const OUString &rFont)
     {
-        String sRet;
-        if ( IsStarSymbol(rFont) )
-            sRet.ASSIGN_CONST_ASC("Arial Unicode MS");
-        else
-            sRet = GetSubsFontName(rFont, SUBSFONT_ONLYONE | SUBSFONT_MS);
-        return sRet;
+        if (IsStarSymbol(rFont))
+            return OUString("Arial Unicode MS");
+        return GetSubsFontName(rFont, SUBSFONT_ONLYONE | SUBSFONT_MS);
     }
 
     //Utility to remove entries before a given starting position
diff --git a/sw/source/filter/ww8/ww8par5.cxx b/sw/source/filter/ww8/ww8par5.cxx
index e3defb4..9a0163b 100644
--- a/sw/source/filter/ww8/ww8par5.cxx
+++ b/sw/source/filter/ww8/ww8par5.cxx
@@ -3309,7 +3309,8 @@ eF_ResT SwWW8ImplReader::Read_F_Hyperlink( WW8FieldDesc* /*pF*/, OUString& rStr
     }
 #endif
 
-    String sURL, sTarget, sMark;
+    String sURL, sMark;
+    OUString sTarget;
     bool bDataImport = false;
     //HYPERLINK "filename" [switches]
 
@@ -3332,7 +3333,7 @@ eF_ResT SwWW8ImplReader::Read_F_Hyperlink( WW8FieldDesc* /*pF*/, OUString& rStr
                     break;
 
                 case 'n':
-                    sTarget.AssignAscii( "_blank" );
+                    sTarget = "_blank";
                     bOptions = true;
                     break;
 
diff --git a/sw/source/ui/index/cntex.cxx b/sw/source/ui/index/cntex.cxx
index a3f96c3..791fc49 100644
--- a/sw/source/ui/index/cntex.cxx
+++ b/sw/source/ui/index/cntex.cxx
@@ -196,9 +196,8 @@ void SwMultiTOXTabDialog::CreateOrUpdateExample(
 
          uno::Reference< lang::XMultiServiceFactory >  xFact(xModel, uno::UNO_QUERY);
 
-            String sIndexTypeName;
-            sIndexTypeName.AssignAscii( IndexServiceNames[
-                    nTOXIndex <= TOX_AUTHORITIES ? nTOXIndex : TOX_USER] );
+         OUString sIndexTypeName(OUString::createFromAscii( IndexServiceNames[
+                    nTOXIndex <= TOX_AUTHORITIES ? nTOXIndex : TOX_USER] ));
             pxIndexSectionsArr[nTOXIndex]->xDocumentIndex = uno::Reference< text::XDocumentIndex > (xFact->createInstance(
                                                     sIndexTypeName), uno::UNO_QUERY);
          uno::Reference< text::XTextContent >  xContent(pxIndexSectionsArr[nTOXIndex]->xDocumentIndex, uno::UNO_QUERY);
@@ -311,7 +310,7 @@ void SwMultiTOXTabDialog::CreateOrUpdateExample(
             {
                 for(sal_uInt16 nCurrLevel = nStartLevel; nCurrLevel <= nEndLevel; nCurrLevel++)
                 {
-                    String sTokenType;
+                    OUString sTokenType;
                     uno::Sequence< beans::PropertyValues> aSequPropVals(10);
                     long nTokenIndex = 0;
                     long nParamCount = 2;
@@ -329,45 +328,36 @@ void SwMultiTOXTabDialog::CreateOrUpdateExample(
                         switch(aToken.eTokenType)
                         {
                             case TOKEN_ENTRY_NO     :
-                                sTokenType.AssignAscii(RTL_CONSTASCII_STRINGPARAM(
-                                                        "TokenEntryNumber"));
+                                sTokenType = "TokenEntryNumber";
                                 // numbering for content index
                             break;
                             case TOKEN_ENTRY_TEXT   :
                             case TOKEN_ENTRY        :
-                                sTokenType.AssignAscii(RTL_CONSTASCII_STRINGPARAM(
-                                                        "TokenEntryText"));
+                                sTokenType = "TokenEntryText";
                             break;
                             case TOKEN_TAB_STOP     :
                                 nParamCount += 3;
-                                sTokenType.AssignAscii(RTL_CONSTASCII_STRINGPARAM(
-                                                        "TokenTabStop"));
+                                sTokenType = "TokenTabStop";
                             break;
                             case TOKEN_TEXT         :
-                                sTokenType.AssignAscii(RTL_CONSTASCII_STRINGPARAM(
-                                                        "TokenText"));
+                                sTokenType = "TokenText";
                                 nParamCount += 1;
                             break;
                             case TOKEN_PAGE_NUMS    :
-                                sTokenType.AssignAscii(RTL_CONSTASCII_STRINGPARAM(
-                                                        "TokenPageNumber"));
+                                sTokenType = "TokenPageNumber";
                             break;
                             case TOKEN_CHAPTER_INFO :
-                                sTokenType.AssignAscii(RTL_CONSTASCII_STRINGPARAM(
-                                                        "TokenChapterInfo"));
+                                sTokenType = "TokenChapterInfo";
                             break;
                             case TOKEN_LINK_START   :
-                                sTokenType.AssignAscii(RTL_CONSTASCII_STRINGPARAM(
-                                                        "TokenHyperlinkStart"));
+                                sTokenType = "TokenHyperlinkStart";
                             break;
                             case TOKEN_LINK_END     :
-                                sTokenType.AssignAscii(RTL_CONSTASCII_STRINGPARAM(
-                                                        "TokenHyperlinkEnd"));
+                                sTokenType = "TokenHyperlinkEnd";
                             break;
                             case TOKEN_AUTHORITY :
                             {
-                                sTokenType.AssignAscii(RTL_CONSTASCII_STRINGPARAM(
-                                                    "TokenBibliographyDataField"));
+                                sTokenType = "TokenBibliographyDataField";
                             }
                             break;
                             default:; //prevent warning
@@ -375,7 +365,7 @@ void SwMultiTOXTabDialog::CreateOrUpdateExample(
                         beans::PropertyValues aPropVals(nParamCount);
                         beans::PropertyValue* pPropValArr = aPropVals.getArray();
                         pPropValArr[0].Name = "TokenType";
-                        pPropValArr[0].Value <<= OUString(sTokenType);
+                        pPropValArr[0].Value <<= sTokenType;
                         pPropValArr[1].Name = "CharacterStyleName";
                         pPropValArr[1].Value <<= OUString(aToken.sCharStyleName);
                         if(TOKEN_TAB_STOP == aToken.eTokenType)
diff --git a/sw/source/ui/misc/outline.cxx b/sw/source/ui/misc/outline.cxx
index 46ecbe6..f879821 100644
--- a/sw/source/ui/misc/outline.cxx
+++ b/sw/source/ui/misc/outline.cxx
@@ -768,7 +768,6 @@ void SwOutlineSettingsTabPage::SetWrtShell(SwWrtShell* pShell)
     m_pStartEdit->SetValue( rNumFmt.GetStart() );
 
     // create pool formats for headlines
-    String sStr;
     sal_uInt16 i;
     for( i = 0; i < MAXLEVEL; ++i )
     {
@@ -776,7 +775,7 @@ void SwOutlineSettingsTabPage::SetWrtShell(SwWrtShell* pShell)
                                     static_cast< sal_uInt16 >(RES_POOLCOLL_HEADLINE1 + i), aEmptyStr ));
         m_pLevelLB->InsertEntry( OUString::number(i + 1) );
     }
-    sStr.AssignAscii( RTL_CONSTASCII_STRINGPARAM( "1 - " ));
+    OUString sStr("1 - ");
     sStr += OUString::number(MAXLEVEL);
     m_pLevelLB->InsertEntry( sStr );
 
diff --git a/tools/source/string/strascii.cxx b/tools/source/string/strascii.cxx
index bf0d5a2..53a2bab 100644
--- a/tools/source/string/strascii.cxx
+++ b/tools/source/string/strascii.cxx
@@ -91,81 +91,6 @@ static sal_Int32 ImplStringCompareWithoutZeroAscii( const sal_Unicode* pStr1, co
     return nRet;
 }
 
-UniString& UniString::AssignAscii( const sal_Char* pAsciiStr )
-{
-    DBG_CHKTHIS( UniString, DbgCheckUniString );
-    DBG_ASSERT( pAsciiStr, "UniString::AssignAscii() - pAsciiStr is NULL" );
-
-    // Determine string length
-    xub_StrLen nLen = ImplStringLen( pAsciiStr );
-
-    if ( !nLen )
-    {
-        STRING_NEW((STRING_TYPE **)&mpData);
-    }
-    else
-    {
-        // Replace string in-place if new size is equal
-        if ( (nLen == mpData->mnLen) && (mpData->mnRefCount == 1) )
-            ImplCopyAsciiStr( mpData->maStr, pAsciiStr, nLen );
-        else
-        {
-            // release old string
-            STRING_RELEASE((STRING_TYPE *)mpData);
-
-            // copy new string
-            mpData = ImplAllocData( nLen );
-            ImplCopyAsciiStr( mpData->maStr, pAsciiStr, nLen );
-        }
-    }
-
-    return *this;
-}
-
-UniString& UniString::AssignAscii( const sal_Char* pAsciiStr, xub_StrLen nLen )
-{
-    DBG_CHKTHIS( UniString, DbgCheckUniString );
-    DBG_ASSERT( pAsciiStr, "UniString::AssignAscii() - pAsciiStr is NULL" );
-
-    if ( nLen == STRING_LEN )
-        nLen = ImplStringLen( pAsciiStr );
-
-#ifdef DBG_UTIL
-    if ( DbgIsAssert() )
-    {
-        for ( xub_StrLen i = 0; i < nLen; ++i )
-        {
-            if ( !pAsciiStr[i] )
-            {
-                OSL_FAIL( "UniString::AssignAscii() : nLen is wrong" );
-            }
-        }
-    }
-#endif
-
-    if ( !nLen )
-    {
-        STRING_NEW((STRING_TYPE **)&mpData);
-    }
-    else
-    {
-        // Replace string in-place if new size is equal
-        if ( (nLen == mpData->mnLen) && (mpData->mnRefCount == 1) )
-            ImplCopyAsciiStr( mpData->maStr, pAsciiStr, nLen );
-        else
-        {
-            // release old string
-            STRING_RELEASE((STRING_TYPE *)mpData);
-
-            // copy new string
-            mpData = ImplAllocData( nLen );
-            ImplCopyAsciiStr( mpData->maStr, pAsciiStr, nLen );
-        }
-    }
-
-    return *this;
-}
-
 UniString& UniString::AppendAscii( const sal_Char* pAsciiStr )
 {
     DBG_CHKTHIS( UniString, DbgCheckUniString );
commit 2655ef2d03b786b683723e92f3c76838fa012ab6
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Oct 1 12:25:05 2013 +0100

    fix OUString conversion in lotuswordpro
    
    second arg is number of input bytes, not number of resulting codepoints
    
    Change-Id: I76ab899fa3875f37075214363188cf897e018f22

diff --git a/lotuswordpro/source/filter/lwpnumericfmt.hxx b/lotuswordpro/source/filter/lwpnumericfmt.hxx
index cef91e9..599af74 100644
--- a/lotuswordpro/source/filter/lwpnumericfmt.hxx
+++ b/lotuswordpro/source/filter/lwpnumericfmt.hxx
@@ -180,6 +180,9 @@ enum
     FMT_EURO                = 52
 };
 
+#define RTL_CONSTUTF8_USTRINGPARAM( constAsciiStr ) (&(constAsciiStr)[0]), \
+    ((sal_Int32)(SAL_N_ELEMENTS(constAsciiStr)-1)), RTL_TEXTENCODING_UTF8
+
 class LwpCurrencyPool
 {
 public:
@@ -198,9 +201,9 @@ private:
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("oS"),sal_True, sal_True);//FMT_AUSTRIANSCHILLING = 3,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("BF"),sal_True, sal_True);//FMT_BELGIANFRANC      = 4,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("R$"),sal_False, sal_True);//FMT_BRAZILIANCRUZEIRO    = 5,
-        m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("\357\277\241", 1, RTL_TEXTENCODING_UTF8));                 //FMT_BRITISHPOUND      = 6,
+        m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString(RTL_CONSTUTF8_USTRINGPARAM("\357\277\241")));                 //FMT_BRITISHPOUND      = 6,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("C$"));                   //FMT_CANADIANDOLLAR        = 7,
-        m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("PRC\357\277\245", 1, RTL_TEXTENCODING_UTF8),sal_False,sal_True);   //FMT_CHINESEYUAN           = 8,
+        m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString(RTL_CONSTUTF8_USTRINGPARAM("PRC\357\277\245")),sal_False,sal_True);   //FMT_CHINESEYUAN           = 8,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("Kc"),sal_True, sal_True);//FMT_CZECHKORUNA           = 9,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("Dkr"),sal_False, sal_True);//FMT_DANISHKRONE         = 10,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("ECU"),sal_True, sal_True);//FMT_ECU                  = 11,
@@ -212,9 +215,9 @@ private:
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("Ft"),sal_True, sal_True);//FMT_HUNGARIANFORINT       = 17,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("Rs"),sal_False, sal_True);//FMT_INDIANRUPEE          = 18,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("Rp"),sal_False, sal_True);//FMT_INDONESIANRUPIAH = 19,
-        m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("IR\357\277\241",3, RTL_TEXTENCODING_UTF8));                   //FMT_IRISHPUNT         = 20,
+        m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString(RTL_CONSTUTF8_USTRINGPARAM("IR\357\277\241")));                   //FMT_IRISHPUNT         = 20,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("L."),sal_False, sal_True);//FMT_ITALIANLIRA          = 21,
-        m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("\357\277\245", 1, RTL_TEXTENCODING_UTF8));             //FMT_JAPANESEYEN           = 22,
+        m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString(RTL_CONSTUTF8_USTRINGPARAM("\357\277\245")));             //FMT_JAPANESEYEN           = 22,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("LF"),sal_True, sal_True);//FMT_LUXEMBOURGFRANC       = 23,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("Rm"),sal_False, sal_True);//FMT_MALAYSIANRINGGIT = 24,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("Mex$"));                 //FMT_MEXICANPESO           = 25,
@@ -238,7 +241,7 @@ private:
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("$"));                    //FMT_USDOLLAR          = 43,
         m_aCurrencyInfo[nC++]=LwpCurrencyInfo(OUString("OTH"),sal_False, sal_True);//FMT_OTHERCURRENCY       = 44,
 
-        m_aCurrencyInfo[FMT_EURO]=LwpCurrencyInfo(OUString("\342\202\254", 1, RTL_TEXTENCODING_UTF8));             //FMT_EURO              = 52
+        m_aCurrencyInfo[FMT_EURO]=LwpCurrencyInfo(OUString(RTL_CONSTUTF8_USTRINGPARAM("\342\202\254")));             //FMT_EURO              = 52
     }
 };
 


More information about the Libreoffice-commits mailing list