summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/linguistic/misc.hxx14
-rw-r--r--linguistic/source/misc.cxx18
-rw-r--r--linguistic/source/misc2.cxx10
3 files changed, 21 insertions, 21 deletions
diff --git a/include/linguistic/misc.hxx b/include/linguistic/misc.hxx
index 8e7b4b1353f1..3d6321ef1e74 100644
--- a/include/linguistic/misc.hxx
+++ b/include/linguistic/misc.hxx
@@ -117,10 +117,10 @@ LNG_DLLPUBLIC bool LinguIsUnspecified( LanguageType nLanguage );
// checks if file pointed to by rURL is readonly
// and may also check return if such a file exists or not
-sal_Bool IsReadOnly( const String &rURL, sal_Bool *pbExist = 0 );
+sal_Bool IsReadOnly( const OUString &rURL, sal_Bool *pbExist = 0 );
// checks if a file with the given URL exists
-sal_Bool FileExists( const String &rURL );
+sal_Bool FileExists( const OUString &rURL );
OUString GetDictionaryWriteablePath();
@@ -128,7 +128,7 @@ OUString GetDictionaryWriteablePath();
/// @returns an URL for a new and writable dictionary rDicName.
/// The URL will point to the path given by 'GetDictionaryWriteablePath'
-LNG_DLLPUBLIC String GetWritableDictionaryURL( const String &rDicName );
+LNG_DLLPUBLIC OUString GetWritableDictionaryURL( const OUString &rDicName );
LNG_DLLPUBLIC sal_Int32 GetPosInWordToCheck( const OUString &rTxt, sal_Int32 nPos );
@@ -139,14 +139,14 @@ LNG_DLLPUBLIC sal_Int32 GetPosInWordToCheck( const OUString &rTxt, sal_Int32 nPo
::com::sun::star::linguistic2::XHyphenatedWord > &rxHyphWord );
-LNG_DLLPUBLIC sal_Bool IsUpper( const String &rText, xub_StrLen nPos, xub_StrLen nLen, sal_Int16 nLanguage );
+LNG_DLLPUBLIC sal_Bool IsUpper( const OUString &rText, xub_StrLen nPos, xub_StrLen nLen, sal_Int16 nLanguage );
-inline sal_Bool IsUpper( const String &rText, sal_Int16 nLanguage ) { return IsUpper( rText, 0, rText.Len(), nLanguage ); }
+inline sal_Bool IsUpper( const OUString &rText, sal_Int16 nLanguage ) { return IsUpper( rText, 0, rText.getLength(), nLanguage ); }
LNG_DLLPUBLIC CapType SAL_CALL capitalType(const OUString&, CharClass *);
-String ToLower( const String &rText, sal_Int16 nLanguage );
+OUString ToLower( const OUString &rText, sal_Int16 nLanguage );
LNG_DLLPUBLIC sal_Bool HasDigits( const OUString &rText );
-LNG_DLLPUBLIC sal_Bool IsNumeric( const String &rText );
+LNG_DLLPUBLIC sal_Bool IsNumeric( const OUString &rText );
::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > GetOneInstanceService( const char *pServiceName );
diff --git a/linguistic/source/misc.cxx b/linguistic/source/misc.cxx
index d5b96bd69903..867dccfc4c38 100644
--- a/linguistic/source/misc.cxx
+++ b/linguistic/source/misc.cxx
@@ -392,12 +392,12 @@ uno::Sequence< sal_Int16 >
return aLangs;
}
-sal_Bool IsReadOnly( const String &rURL, sal_Bool *pbExist )
+sal_Bool IsReadOnly( const OUString &rURL, sal_Bool *pbExist )
{
sal_Bool bRes = sal_False;
sal_Bool bExists = sal_False;
- if (rURL.Len() > 0)
+ if (!rURL.isEmpty())
{
try
{
@@ -583,7 +583,7 @@ osl::Mutex & lcl_GetCharClassMutex()
return aMutex;
}
-sal_Bool IsUpper( const String &rText, xub_StrLen nPos, xub_StrLen nLen, sal_Int16 nLanguage )
+sal_Bool IsUpper( const OUString &rText, xub_StrLen nPos, xub_StrLen nLen, sal_Int16 nLanguage )
{
MutexGuard aGuard( lcl_GetCharClassMutex() );
@@ -599,7 +599,7 @@ CapType SAL_CALL capitalType(const OUString& aTerm, CharClass * pCC)
sal_Int32 tlen = aTerm.getLength();
if ((pCC) && (tlen))
{
- String aStr(aTerm);
+ OUString aStr(aTerm);
sal_Int32 nc = 0;
for (sal_uInt16 tindex = 0; tindex < tlen; tindex++)
{
@@ -620,7 +620,7 @@ CapType SAL_CALL capitalType(const OUString& aTerm, CharClass * pCC)
return CAPTYPE_UNKNOWN;
}
-String ToLower( const String &rText, sal_Int16 nLanguage )
+OUString ToLower( const OUString &rText, sal_Int16 nLanguage )
{
MutexGuard aGuard( lcl_GetCharClassMutex() );
@@ -689,17 +689,17 @@ sal_Bool HasDigits( const OUString &rText )
return sal_False;
}
-sal_Bool IsNumeric( const String &rText )
+sal_Bool IsNumeric( const OUString &rText )
{
sal_Bool bRes = sal_False;
- xub_StrLen nLen = rText.Len();
- if (nLen)
+ if (!rText.isEmpty())
{
+ xub_StrLen nLen = rText.getLength();
bRes = sal_True;
xub_StrLen i = 0;
while (i < nLen)
{
- sal_Unicode cChar = rText.GetChar( i++ );
+ sal_Unicode cChar = rText[ i++ ];
if ( !((sal_Unicode)'0' <= cChar && cChar <= (sal_Unicode)'9') )
{
bRes = sal_False;
diff --git a/linguistic/source/misc2.cxx b/linguistic/source/misc2.cxx
index eab239de6f03..726493ebb3b9 100644
--- a/linguistic/source/misc2.cxx
+++ b/linguistic/source/misc2.cxx
@@ -41,10 +41,10 @@ namespace linguistic
{
-sal_Bool FileExists( const String &rMainURL )
+sal_Bool FileExists( const OUString &rMainURL )
{
sal_Bool bExists = sal_False;
- if (rMainURL.Len())
+ if (!rMainURL.isEmpty())
{
try
{
@@ -123,7 +123,7 @@ OUString GetDictionaryWriteablePath()
{
uno::Sequence< OUString > aPaths( GetMultiPaths_Impl( "Dictionary", PATH_FLAG_WRITABLE ) );
DBG_ASSERT( aPaths.getLength() == 1, "Dictionary_writable path corrupted?" );
- String aRes;
+ OUString aRes;
if (aPaths.getLength() > 0)
aRes = aPaths[0];
return aRes;
@@ -134,10 +134,10 @@ uno::Sequence< OUString > GetDictionaryPaths( sal_Int16 nPathFlags )
return GetMultiPaths_Impl( "Dictionary", nPathFlags );
}
-String GetWritableDictionaryURL( const String &rDicName )
+OUString GetWritableDictionaryURL( const OUString &rDicName )
{
// new user writable dictionaries should be created in the 'writable' path
- String aDirName( GetDictionaryWriteablePath() );
+ OUString aDirName( GetDictionaryWriteablePath() );
// build URL to use for a new (persistent) dictionary
INetURLObject aURLObj;