From 0dd085f8f327b08cf5d69c3e1b93ff82016995fb Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Sun, 28 Oct 2012 20:31:11 +0000 Subject: UniString->rtl::OUStringBuffer Change-Id: I9938d7c4ab5594baeb10f405f0aa0964ef84d6c5 --- sw/source/ui/docvw/edtwin.cxx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'sw/source/ui/docvw/edtwin.cxx') diff --git a/sw/source/ui/docvw/edtwin.cxx b/sw/source/ui/docvw/edtwin.cxx index e9eb4e99f858..41f61009f816 100644 --- a/sw/source/ui/docvw/edtwin.cxx +++ b/sw/source/ui/docvw/edtwin.cxx @@ -31,6 +31,7 @@ #include #include #include +#include #include #include #include @@ -2386,7 +2387,7 @@ KEYINPUT_CHECKTABLE_INSDEL: { // insert a blank ahead of the character. this ends up // between the expanded text and the new "non-word-seperator". - aInBuffer.Expand( aInBuffer.Len() + 1, ' ' ); + aInBuffer += ' '; } sal_Bool bIsAutoCorrectChar = SvxAutoCorrect::IsAutoCorrectChar( aCh ); @@ -2417,7 +2418,10 @@ KEYINPUT_CHECKTABLE_INSDEL: } else { - aInBuffer.Expand( aInBuffer.Len() + aKeyEvent.GetRepeat() + 1,aCh ); + rtl::OUStringBuffer aBuf(aInBuffer); + comphelper::string::padToLength(aBuf, + aInBuffer.Len() + aKeyEvent.GetRepeat() + 1, aCh); + aInBuffer = aBuf.makeStringAndClear(); bFlushCharBuffer = Application::AnyInput( VCL_INPUT_KEYBOARD ); bFlushBuffer = !bFlushCharBuffer; if( bFlushCharBuffer ) -- cgit