[Libreoffice-commits] .: editeng/inc editeng/source
Andras Timar
timar at kemper.freedesktop.org
Mon Oct 24 02:02:17 PDT 2011
editeng/inc/editeng/svxacorr.hxx | 2 +-
editeng/source/misc/svxacorr.cxx | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
New commits:
commit d330483ad0106a750dec560b987c21aaa5394ab6
Author: Andras Timar <atimar at suse.com>
Date: Mon Oct 24 11:01:36 2011 +0200
autocorrect: non-breaking space before % in French fdo#41015
diff --git a/editeng/inc/editeng/svxacorr.hxx b/editeng/inc/editeng/svxacorr.hxx
index 0659b73..dd83531 100644
--- a/editeng/inc/editeng/svxacorr.hxx
+++ b/editeng/inc/editeng/svxacorr.hxx
@@ -53,7 +53,7 @@ class Window;
// Auto correct flags
const long CptlSttSntnc = 0x00000001; // Capital letters at the beginning of a sentence
const long CptlSttWrd = 0x00000002; // not two Capital letters at the beginning of a word
-const long AddNonBrkSpace = 0x00000004; // Add non breaking space before :;?!
+const long AddNonBrkSpace = 0x00000004; // Add non breaking space before :;?!%
const long ChgOrdinalNumber = 0x00000008; // Ordinal-Number 1st, 2nd,..
const long ChgToEnEmDash = 0x00000010; // - -> Endash/Emdash
const long ChgWeightUnderl = 0x00000020; // * -> Bold, _ -> Underscore
diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx
index 7e53771..9c74713 100644
--- a/editeng/source/misc/svxacorr.cxx
+++ b/editeng/source/misc/svxacorr.cxx
@@ -297,14 +297,14 @@ sal_Bool SvxAutoCorrect::IsAutoCorrectChar( sal_Unicode cChar )
{
return cChar == '\0' || cChar == '\t' || cChar == 0x0a ||
cChar == ' ' || cChar == '\'' || cChar == '\"' ||
- cChar == '*' || cChar == '_' ||
+ cChar == '*' || cChar == '_' || cChar == '%' ||
cChar == '.' || cChar == ',' || cChar == ';' ||
cChar == ':' || cChar == '?' || cChar == '!' || cChar == '/';
}
sal_Bool SvxAutoCorrect::NeedsHardspaceAutocorr( sal_Unicode cChar )
{
- return cChar == ';' || cChar == ':' || cChar == '?' || cChar == '!' ||
+ return cChar == '%' || cChar == ';' || cChar == ':' || cChar == '?' || cChar == '!' ||
cChar == '/' /*case for the urls exception*/;
}
@@ -661,7 +661,7 @@ sal_Bool SvxAutoCorrect::FnAddNonBrkSpace(
if ( rLocale.Language == OUString(RTL_CONSTASCII_USTRINGPARAM( "fr" )) )
{
bool bFrCA = rLocale.Country == OUString(RTL_CONSTASCII_USTRINGPARAM( "CA" ));
- OUString allChars = OUString(RTL_CONSTASCII_USTRINGPARAM( ":;!?" ));
+ OUString allChars = OUString(RTL_CONSTASCII_USTRINGPARAM( ":;?!%" ));
OUString chars( allChars );
if ( bFrCA )
chars = OUString(RTL_CONSTASCII_USTRINGPARAM( ":" ));
More information about the Libreoffice-commits
mailing list