summaryrefslogtreecommitdiff
path: root/vcl/source/edit/xtextedt.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2013-08-05 10:42:21 +0200
committerNoel Grandin <noel@peralex.com>2013-08-12 11:56:39 +0200
commit36593cd50c3229b00445fc232fcdf453fcb77cde (patch)
treeac36bc5cd2d2de475f5353e05fd81af06d57fc04 /vcl/source/edit/xtextedt.cxx
parentc9eb7eefd19ee5d9ecf5c6d4c2d701f169847a07 (diff)
convert vcl/xtextedt.hxx from String to OUString
Change-Id: I96ad6373fe04e6f936db92c4ce7f50e48e9c5a32
Diffstat (limited to 'vcl/source/edit/xtextedt.cxx')
-rw-r--r--vcl/source/edit/xtextedt.cxx14
1 files changed, 7 insertions, 7 deletions
diff --git a/vcl/source/edit/xtextedt.cxx b/vcl/source/edit/xtextedt.cxx
index 97149a304ad2..ceec23c24552 100644
--- a/vcl/source/edit/xtextedt.cxx
+++ b/vcl/source/edit/xtextedt.cxx
@@ -43,14 +43,14 @@ TextSelection ExtTextEngine::MatchGroup( const TextPaM& rCursor ) const
sal_uLong nParas = GetParagraphCount();
if ( ( nPara < nParas ) && ( nPos < GetTextLen( nPara ) ) )
{
- sal_uInt16 nMatchChar = maGroupChars.Search( GetText( rCursor.GetPara() )[ nPos ] );
- if ( nMatchChar != STRING_NOTFOUND )
+ sal_Int32 nMatchIndex = maGroupChars.indexOf( GetText( rCursor.GetPara() )[ nPos ] );
+ if ( nMatchIndex != -1 )
{
- if ( ( nMatchChar % 2 ) == 0 )
+ if ( ( nMatchIndex % 2 ) == 0 )
{
// search forwards
- sal_Unicode nSC = maGroupChars.GetChar( nMatchChar );
- sal_Unicode nEC = maGroupChars.GetChar( nMatchChar+1 );
+ sal_Unicode nSC = maGroupChars[ nMatchIndex ];
+ sal_Unicode nEC = maGroupChars[ nMatchIndex+1 ];
sal_uInt16 nCur = nPos+1;
sal_uInt16 nLevel = 1;
@@ -85,8 +85,8 @@ TextSelection ExtTextEngine::MatchGroup( const TextPaM& rCursor ) const
else
{
// search backwards
- sal_Unicode nEC = maGroupChars.GetChar( nMatchChar );
- sal_Unicode nSC = maGroupChars.GetChar( nMatchChar-1 );
+ sal_Unicode nEC = maGroupChars[ nMatchIndex ];
+ sal_Unicode nSC = maGroupChars[ nMatchIndex-1 ];
sal_uInt16 nCur = rCursor.GetIndex()-1;
sal_uInt16 nLevel = 1;