diff options
-rw-r--r-- | editeng/source/editeng/editeng.cxx | 10 | ||||
-rw-r--r-- | editeng/source/editeng/impedit.hxx | 3 | ||||
-rw-r--r-- | editeng/source/editeng/impedit2.cxx | 3 | ||||
-rw-r--r-- | editeng/source/outliner/outlin2.cxx | 4 | ||||
-rw-r--r-- | editeng/source/outliner/outlvw.cxx | 6 | ||||
-rw-r--r-- | include/editeng/editeng.hxx | 4 | ||||
-rw-r--r-- | include/editeng/outliner.hxx | 6 | ||||
-rw-r--r-- | sc/source/ui/app/inputwin.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/drawfunc/drtxtob.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/view/editsh.cxx | 4 | ||||
-rw-r--r-- | sd/source/ui/presenter/PresenterTextView.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/view/drtxtob.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/view/drviewsf.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/view/outlnvsh.cxx | 2 | ||||
-rw-r--r-- | starmath/source/document.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/shells/annotsh.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/shells/drwtxtex.cxx | 2 |
17 files changed, 27 insertions, 31 deletions
diff --git a/editeng/source/editeng/editeng.cxx b/editeng/source/editeng/editeng.cxx index 9bf29e5c2e9b..0684bfe0782d 100644 --- a/editeng/source/editeng/editeng.cxx +++ b/editeng/source/editeng/editeng.cxx @@ -1359,7 +1359,7 @@ sal_Bool EditEngine::PostKeyEvent( const KeyEvent& rKeyEvent, EditView* pEditVie // Only at end of word... sal_uInt16 nIndex = aCurSel.Max().GetIndex(); if ( ( nIndex >= aCurSel.Max().GetNode()->Len() ) || - ( pImpEditEngine->aWordDelimiters.Search( aCurSel.Max().GetNode()->GetChar( nIndex ) ) != STRING_NOTFOUND ) ) + ( pImpEditEngine->aWordDelimiters.indexOf( aCurSel.Max().GetNode()->GetChar( nIndex ) ) != -1 ) ) { EditPaM aStart( pImpEditEngine->WordLeft( aCurSel.Max() ) ); String aWord = pImpEditEngine->GetSelected( EditSelection( aStart, aCurSel.Max() ) ); @@ -2246,15 +2246,15 @@ SfxStyleSheetPool* EditEngine::GetStyleSheetPool() return pImpEditEngine->GetStyleSheetPool(); } -void EditEngine::SetWordDelimiters( const XubString& rDelimiters ) +void EditEngine::SetWordDelimiters( const OUString& rDelimiters ) { DBG_CHKTHIS( EditEngine, 0 ); pImpEditEngine->aWordDelimiters = rDelimiters; - if ( pImpEditEngine->aWordDelimiters.Search( CH_FEATURE ) == STRING_NOTFOUND ) - pImpEditEngine->aWordDelimiters.Insert( CH_FEATURE ); + if (pImpEditEngine->aWordDelimiters.indexOf(CH_FEATURE) == -1) + pImpEditEngine->aWordDelimiters += OUString(CH_FEATURE); } -XubString EditEngine::GetWordDelimiters() const +OUString EditEngine::GetWordDelimiters() const { DBG_CHKTHIS( EditEngine, 0 ); return pImpEditEngine->aWordDelimiters; diff --git a/editeng/source/editeng/impedit.hxx b/editeng/source/editeng/impedit.hxx index 55b98f15fcb6..92bcac41b144 100644 --- a/editeng/source/editeng/impedit.hxx +++ b/editeng/source/editeng/impedit.hxx @@ -412,8 +412,7 @@ private: std::vector<EENotify> aNotifyCache; - XubString aWordDelimiters; - XubString aGroupChars; + OUString aWordDelimiters; EditSelFunctionSet aSelFuncSet; EditSelectionEngine aSelEngine; diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx index bba2f2a5dcf7..1503a7b869dc 100644 --- a/editeng/source/editeng/impedit2.cxx +++ b/editeng/source/editeng/impedit2.cxx @@ -83,8 +83,7 @@ ImpEditEngine::ImpEditEngine( EditEngine* pEE, SfxItemPool* pItemPool ) : aMinAutoPaperSize( 0x0, 0x0 ), aMaxAutoPaperSize( 0x7FFFFFFF, 0x7FFFFFFF ), aEditDoc( pItemPool ), - aWordDelimiters( RTL_CONSTASCII_USTRINGPARAM( " .,;:-'`'?!_=\"{}()[]\0xFF" ) ), - aGroupChars( RTL_CONSTASCII_USTRINGPARAM( "{}()[]" ) ), + aWordDelimiters(" .,;:-'`'?!_=\"{}()[]\0xFF"), bKernAsianPunctuation(false), bAddExtLeading(false), bIsFormatting(false), diff --git a/editeng/source/outliner/outlin2.cxx b/editeng/source/outliner/outlin2.cxx index a5251a1c5d46..ff8bc7449e59 100644 --- a/editeng/source/outliner/outlin2.cxx +++ b/editeng/source/outliner/outlin2.cxx @@ -181,13 +181,13 @@ void Outliner::RemoveFields( sal_Bool bKeepFieldText, TypeId aType ) pEditEngine->RemoveFields( bKeepFieldText, aType ); } -void Outliner::SetWordDelimiters( const String& rDelimiters ) +void Outliner::SetWordDelimiters( const OUString& rDelimiters ) { DBG_CHKTHIS(Outliner,0); pEditEngine->SetWordDelimiters( rDelimiters ); } -String Outliner::GetWordDelimiters() const +OUString Outliner::GetWordDelimiters() const { DBG_CHKTHIS(Outliner,0); return pEditEngine->GetWordDelimiters(); diff --git a/editeng/source/outliner/outlvw.cxx b/editeng/source/outliner/outlvw.cxx index a72f2bc9c30a..a9701fe0880a 100644 --- a/editeng/source/outliner/outlvw.cxx +++ b/editeng/source/outliner/outlvw.cxx @@ -1562,7 +1562,7 @@ Selection OutlinerView::GetSurroundingTextSelection() const // returns: true if a word for thesaurus look-up was found at the current cursor position. // The status string will be word + iso language string (e.g. "light#en-US") bool EDITENG_DLLPUBLIC GetStatusValueForThesaurusFromContext( - String &rStatusVal, + OUString &rStatusVal, LanguageType &rLang, const EditView &rEditView ) { @@ -1578,9 +1578,7 @@ bool EDITENG_DLLPUBLIC GetStatusValueForThesaurusFromContext( OUString aLangText( LanguageTag::convertToBcp47( nLang ) ); // set word and locale to look up as status value - OUString aStatusVal= aText + "#" + aLangText; - - rStatusVal = aStatusVal; + rStatusVal = aText + "#" + aLangText; rLang = nLang; return aText.getLength() > 0; diff --git a/include/editeng/editeng.hxx b/include/editeng/editeng.hxx index a3ba78d93e40..0246cbeaa47e 100644 --- a/include/editeng/editeng.hxx +++ b/include/editeng/editeng.hxx @@ -385,8 +385,8 @@ public: const SfxStyleSheet* GetStyleSheet( sal_Int32 nPara ) const; SfxStyleSheet* GetStyleSheet( sal_Int32 nPara ); - void SetWordDelimiters( const String& rDelimiters ); - String GetWordDelimiters() const; + void SetWordDelimiters( const OUString& rDelimiters ); + OUString GetWordDelimiters() const; void EraseVirtualDevice(); diff --git a/include/editeng/outliner.hxx b/include/editeng/outliner.hxx index c9c0b0bc1a23..0f1a540f76a2 100644 --- a/include/editeng/outliner.hxx +++ b/include/editeng/outliner.hxx @@ -385,7 +385,7 @@ public: // some thesaurus functionality to avoid code duplication in different projects... -bool EDITENG_DLLPUBLIC GetStatusValueForThesaurusFromContext( String &rStatusVal, LanguageType &rLang, const EditView &rEditView ); +bool EDITENG_DLLPUBLIC GetStatusValueForThesaurusFromContext( OUString &rStatusVal, LanguageType &rLang, const EditView &rEditView ); void EDITENG_DLLPUBLIC ReplaceTextWithSynonym( EditView &rEditView, const String &rSynonmText ); typedef ::std::vector< OutlinerView* > ViewList; @@ -857,8 +857,8 @@ public: EBulletInfo GetBulletInfo( sal_Int32 nPara ); - void SetWordDelimiters( const String& rDelimiters ); - String GetWordDelimiters() const; + void SetWordDelimiters( const OUString& rDelimiters ); + OUString GetWordDelimiters() const; String GetWord( sal_Int32 nPara, xub_StrLen nIndex ); void StripPortions(); diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx index 795902e4d4c7..4fb2ad7f01bc 100644 --- a/sc/source/ui/app/inputwin.cxx +++ b/sc/source/ui/app/inputwin.cxx @@ -1957,7 +1957,7 @@ void ScTextWnd::MakeDialogEditView() pEditEngine = pNew; pEditEngine->SetUpdateMode( false ); - pEditEngine->SetWordDelimiters( pEditEngine->GetWordDelimiters() += '=' ); + pEditEngine->SetWordDelimiters( pEditEngine->GetWordDelimiters() + "=" ); pEditEngine->SetPaperSize( Size( bIsRTL ? USHRT_MAX : THESIZE, 300 ) ); SfxItemSet* pSet = new SfxItemSet( pEditEngine->GetEmptyItemSet() ); diff --git a/sc/source/ui/drawfunc/drtxtob.cxx b/sc/source/ui/drawfunc/drtxtob.cxx index 8e97dd2bc6e6..5a1a45b46ed8 100644 --- a/sc/source/ui/drawfunc/drtxtob.cxx +++ b/sc/source/ui/drawfunc/drtxtob.cxx @@ -456,7 +456,7 @@ void ScDrawTextObjectBar::GetState( SfxItemSet& rSet ) SdrView * pView = pViewData->GetScDrawView(); OutlinerView* pOutView = pView->GetTextEditOutlinerView(); - String aStatusVal; + OUString aStatusVal; LanguageType nLang = LANGUAGE_NONE; bool bIsLookUpWord = false; if ( pOutView ) diff --git a/sc/source/ui/view/editsh.cxx b/sc/source/ui/view/editsh.cxx index 66538712910f..58fc54220271 100644 --- a/sc/source/ui/view/editsh.cxx +++ b/sc/source/ui/view/editsh.cxx @@ -715,7 +715,7 @@ void ScEditShell::GetState( SfxItemSet& rSet ) case SID_THES: { - String aStatusVal; + OUString aStatusVal; LanguageType nLang = LANGUAGE_NONE; bool bIsLookUpWord = GetStatusValueForThesaurusFromContext( aStatusVal, nLang, *pActiveView ); rSet.Put( SfxStringItem( SID_THES, aStatusVal ) ); @@ -1143,7 +1143,7 @@ String ScEditShell::GetSelectionText( sal_Bool bWholeWord ) ESelection aSel = pEditView->GetSelection(); String aStrCurrentDelimiters = pEngine->GetWordDelimiters(); - pEngine->SetWordDelimiters(OUString(" .,;\"'")); + pEngine->SetWordDelimiters(" .,;\"'"); aStrSelection = pEngine->GetWord( aSel.nEndPara, aSel.nEndPos ); pEngine->SetWordDelimiters( aStrCurrentDelimiters ); } diff --git a/sd/source/ui/presenter/PresenterTextView.cxx b/sd/source/ui/presenter/PresenterTextView.cxx index 349eefef3b97..cb124320d3d6 100644 --- a/sd/source/ui/presenter/PresenterTextView.cxx +++ b/sd/source/ui/presenter/PresenterTextView.cxx @@ -399,7 +399,7 @@ EditEngine* PresenterTextView::Implementation::CreateEditEngine (void) (~EE_CNTRL_UNDOATTRIBS) & (~EE_CNTRL_PASTESPECIAL)); - pEditEngine->SetWordDelimiters (OUString(" .=+-*/(){}[];\"")); + pEditEngine->SetWordDelimiters (" .=+-*/(){}[];\""); pEditEngine->SetRefMapMode (MAP_PIXEL); pEditEngine->SetPaperSize (Size(800, 0)); pEditEngine->EraseVirtualDevice(); diff --git a/sd/source/ui/view/drtxtob.cxx b/sd/source/ui/view/drtxtob.cxx index 5bbaa045e7d2..d65f1b0ea468 100644 --- a/sd/source/ui/view/drtxtob.cxx +++ b/sd/source/ui/view/drtxtob.cxx @@ -395,7 +395,7 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet ) if( mpView && mpView->GetTextEditOutlinerView() ) { EditView & rEditView = mpView->GetTextEditOutlinerView()->GetEditView(); - String aStatusVal; + OUString aStatusVal; LanguageType nLang = LANGUAGE_NONE; bool bIsLookUpWord = GetStatusValueForThesaurusFromContext( aStatusVal, nLang, rEditView ); rSet.Put( SfxStringItem( SID_THES, aStatusVal ) ); diff --git a/sd/source/ui/view/drviewsf.cxx b/sd/source/ui/view/drviewsf.cxx index 418ab1fa6305..5bb62d27e801 100644 --- a/sd/source/ui/view/drviewsf.cxx +++ b/sd/source/ui/view/drviewsf.cxx @@ -757,7 +757,7 @@ String DrawViewShell::GetSelectionText(sal_Bool bCompleteWords) ESelection aSel = pOlView->GetSelection(); OUString aStrCurrentDelimiters = pOl->GetWordDelimiters(); - pOl->SetWordDelimiters( OUString(" .,;\"'" )); + pOl->SetWordDelimiters(" .,;\"'"); aStrSelection = pOl->GetWord( aSel.nEndPara, aSel.nEndPos ); pOl->SetWordDelimiters( aStrCurrentDelimiters ); } diff --git a/sd/source/ui/view/outlnvsh.cxx b/sd/source/ui/view/outlnvsh.cxx index d9e72fd641b6..cf375fad7180 100644 --- a/sd/source/ui/view/outlnvsh.cxx +++ b/sd/source/ui/view/outlnvsh.cxx @@ -1479,7 +1479,7 @@ String OutlineViewShell::GetSelectionText(sal_Bool bCompleteWords) ESelection aSel = pOutlinerView->GetSelection(); OUString aStrCurrentDelimiters = pOl->GetWordDelimiters(); - pOl->SetWordDelimiters( OUString( " .,;\"'" ) ); + pOl->SetWordDelimiters(" .,;\"'"); aStrSelection = pOl->GetWord( aSel.nEndPara, aSel.nEndPos ); pOl->SetWordDelimiters( aStrCurrentDelimiters ); } diff --git a/starmath/source/document.cxx b/starmath/source/document.cxx index e49faecbc852..6e91900c35e4 100644 --- a/starmath/source/document.cxx +++ b/starmath/source/document.cxx @@ -393,7 +393,7 @@ EditEngine& SmDocShell::GetEditEngine() (~EE_CNTRL_UNDOATTRIBS) & (~EE_CNTRL_PASTESPECIAL) ); - pEditEngine->SetWordDelimiters( OUString(" .=+-*/(){}[];\"" ) ); + pEditEngine->SetWordDelimiters(" .=+-*/(){}[];\""); pEditEngine->SetRefMapMode( MAP_PIXEL ); pEditEngine->SetPaperSize( Size( 800, 0 ) ); diff --git a/sw/source/ui/shells/annotsh.cxx b/sw/source/ui/shells/annotsh.cxx index 13da065de283..fcb4c3d44130 100644 --- a/sw/source/ui/shells/annotsh.cxx +++ b/sw/source/ui/shells/annotsh.cxx @@ -1317,7 +1317,7 @@ void SwAnnotationShell::GetLinguState(SfxItemSet &rSet) case SID_THES: { - String aStatusVal; + OUString aStatusVal; LanguageType nLang = LANGUAGE_NONE; bool bIsLookUpWord = GetStatusValueForThesaurusFromContext( aStatusVal, nLang, pOLV->GetEditView() ); rSet.Put( SfxStringItem( SID_THES, aStatusVal ) ); diff --git a/sw/source/ui/shells/drwtxtex.cxx b/sw/source/ui/shells/drwtxtex.cxx index 24bdeb8d2d09..910497d489e4 100644 --- a/sw/source/ui/shells/drwtxtex.cxx +++ b/sw/source/ui/shells/drwtxtex.cxx @@ -597,7 +597,7 @@ void SwDrawTextShell::GetState(SfxItemSet& rSet) case SID_THES: { - String aStatusVal; + OUString aStatusVal; LanguageType nLang = LANGUAGE_NONE; bool bIsLookUpWord = GetStatusValueForThesaurusFromContext( aStatusVal, nLang, pOLV->GetEditView() ); rSet.Put( SfxStringItem( SID_THES, aStatusVal ) ); |