editeng/source/misc/svxacorr.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
New commits: commit 85549899ad814f401449dff9f0b57ccc25cca14a Author: Caolán McNamara <caol...@redhat.com> Date: Wed Nov 28 13:36:47 2012 +0000 Resolves: fdo#57640 we really want to *titlecase* the initial character http://srfi.schemers.org/srfi-13/mail-archive/msg00046.html summarizes well.. " - Titlecase <> uppercase Unicode defines three kinds of case mapping: lowercase, uppercase, and titlecase. The difference between uppercasing and titlecasing a character or character sequence can be seen in compound characters (that is, a single character that represents a compount of two characters). For example, in Unicode, character U+01F3 is LATIN SMALL LETTER DZ. (Let us write this compound character using ASCII as "dz".) This character uppercases to character U+01F1, LATIN CAPITAL LETTER DZ. (Which is basically "DZ".) But it titlecases to to character U+01F2, LATIN CAPITAL LETTER D WITH SMALL LETTER Z. (Which we can write "Dz".) character uppercase titlecase --------- --------- --------- dz DZ Dz " See TestCharacterClassification::testTitleCase for titlecase regression tests. (cherry picked from commit 150e32777c99a5d67a51726972f46c06dae8a6ac) Conflicts: editeng/source/misc/svxacorr.cxx Change-Id: I198379832d1910632bb6358149a5276b68d7c6eb Reviewed-on: https://gerrit.libreoffice.org/1191 Reviewed-by: Miklos Vajna <vmik...@suse.cz> Tested-by: Miklos Vajna <vmik...@suse.cz> diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx index 6d2440b..084a79f 100644 --- a/editeng/source/misc/svxacorr.cxx +++ b/editeng/source/misc/svxacorr.cxx @@ -888,7 +888,7 @@ sal_Bool SvxAutoCorrect::FnCptlSttSntnc( SvxAutoCorrDoc& rDoc, { // valid separator -> replace String sChar( *pWordStt ); - sChar = rCC.uppercase( sChar ); + sChar = rCC.titlecase( sChar ); //see fdo#56740 return sChar != *pWordStt && rDoc.ReplaceRange( xub_StrLen( pWordStt - pStart ), 1, sChar ); } @@ -1064,7 +1064,7 @@ sal_Bool SvxAutoCorrect::FnCptlSttSntnc( SvxAutoCorrDoc& rDoc, sal_Unicode cSave = *pWordStt; nSttPos = sal::static_int_cast< xub_StrLen >( pWordStt - rTxt.GetBuffer() ); String sChar( cSave ); - sChar = rCC.uppercase( sChar ); + sChar = rCC.titlecase( sChar ); //see fdo#56740 sal_Bool bRet = sChar.GetChar(0) != cSave && rDoc.ReplaceRange( nSttPos, 1, sChar ); // Parahaps someone wants to have the word
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits