summaryrefslogtreecommitdiff
path: root/editeng
diff options
context:
space:
mode:
authorAndras Timar <atimar@suse.com>2011-10-24 11:01:36 +0200
committerAndras Timar <atimar@suse.com>2011-10-24 11:02:25 +0200
commitd330483ad0106a750dec560b987c21aaa5394ab6 (patch)
tree68daa38a1b115dfde0a40df5bef81694dc059e2c /editeng
parent5f950b5d79d4567ae385fdf25de26b4d0e43e471 (diff)
autocorrect: non-breaking space before % in French fdo#41015
Diffstat (limited to 'editeng')
-rw-r--r--editeng/inc/editeng/svxacorr.hxx2
-rw-r--r--editeng/source/misc/svxacorr.cxx6
2 files changed, 4 insertions, 4 deletions
diff --git a/editeng/inc/editeng/svxacorr.hxx b/editeng/inc/editeng/svxacorr.hxx
index 0659b737949a..dd835312720f 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 7e53771e3b9c..9c74713223cd 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( ":" ));