From d2771b63b94a8aae3c25c83e9dae9f83242f46c1 Mon Sep 17 00:00:00 2001 From: "Faisal M. Al-Otaibi" Date: Tue, 8 Apr 2014 09:42:20 +0300 Subject: fdo#77123: Add option ignore kashida to the search This patch will add new checkbox to ignore kashida in the search and replace dialog. Change-Id: I9e7179242751103b8418d922ade5b9145170ad15 --- unotools/source/config/searchopt.cxx | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'unotools') diff --git a/unotools/source/config/searchopt.cxx b/unotools/source/config/searchopt.cxx index 8f11a851edac..5a9e6d608478 100644 --- a/unotools/source/config/searchopt.cxx +++ b/unotools/source/config/searchopt.cxx @@ -33,7 +33,7 @@ using namespace utl; using namespace com::sun::star::uno; using namespace com::sun::star::i18n; -#define MAX_FLAGS_OFFSET 26 +#define MAX_FLAGS_OFFSET 27 class SvtSearchOptions_Impl: public ConfigItem, private boost::noncopyable { @@ -143,7 +143,8 @@ Sequence< OUString > SvtSearchOptions_Impl::GetPropertyNames() const "Japanese/IsIgnoreProlongedSoundMark", // 23 "Japanese/IsIgnoreMiddleDot", // 24 "IsNotes", // 25 - "IsIgnoreDiacritics_CTL" // 26 + "IsIgnoreDiacritics_CTL", // 26 + "IsIgnoreKashida_CTL" // 27 }; const int nCount = SAL_N_ELEMENTS( aPropNames ); @@ -287,6 +288,8 @@ sal_Int32 SvtSearchOptions::GetTransliterationFlags() const nRes |= TransliterationModules_ignoreMiddleDot_ja_JP; if ( IsIgnoreDiacritics_CTL()) nRes |= TransliterationModulesExtra::ignoreDiacritics_CTL; + if ( IsIgnoreKashida_CTL()) + nRes |= TransliterationModulesExtra::ignoreKashida_CTL; return nRes; } @@ -555,4 +558,14 @@ void SvtSearchOptions::SetIgnoreDiacritics_CTL( bool bVal ) pImpl->SetFlag( 26, bVal ); } +bool SvtSearchOptions::IsIgnoreKashida_CTL() const +{ + return pImpl->GetFlag( 27 ); +} + +void SvtSearchOptions::SetIgnoreKashida_CTL( bool bVal ) +{ + pImpl->SetFlag( 27, bVal ); +} + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ -- cgit