1*2ee96f1cSAndrew Rist /**************************************************************
2cdf0e10cSrcweir *
3*2ee96f1cSAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one
4*2ee96f1cSAndrew Rist * or more contributor license agreements. See the NOTICE file
5*2ee96f1cSAndrew Rist * distributed with this work for additional information
6*2ee96f1cSAndrew Rist * regarding copyright ownership. The ASF licenses this file
7*2ee96f1cSAndrew Rist * to you under the Apache License, Version 2.0 (the
8*2ee96f1cSAndrew Rist * "License"); you may not use this file except in compliance
9*2ee96f1cSAndrew Rist * with the License. You may obtain a copy of the License at
10*2ee96f1cSAndrew Rist *
11*2ee96f1cSAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0
12*2ee96f1cSAndrew Rist *
13*2ee96f1cSAndrew Rist * Unless required by applicable law or agreed to in writing,
14*2ee96f1cSAndrew Rist * software distributed under the License is distributed on an
15*2ee96f1cSAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*2ee96f1cSAndrew Rist * KIND, either express or implied. See the License for the
17*2ee96f1cSAndrew Rist * specific language governing permissions and limitations
18*2ee96f1cSAndrew Rist * under the License.
19*2ee96f1cSAndrew Rist *
20*2ee96f1cSAndrew Rist *************************************************************/
21*2ee96f1cSAndrew Rist
22*2ee96f1cSAndrew Rist
23cdf0e10cSrcweir
24cdf0e10cSrcweir // MARKER(update_precomp.py): autogen include statement, do not remove
25cdf0e10cSrcweir #include "precompiled_cui.hxx"
26cdf0e10cSrcweir
27cdf0e10cSrcweir #include <tools/shl.hxx>
28cdf0e10cSrcweir #include <unotools/searchopt.hxx>
29cdf0e10cSrcweir #include <com/sun/star/i18n/TransliterationModules.hpp>
30cdf0e10cSrcweir #include <cuires.hrc>
31cdf0e10cSrcweir #include <dialmgr.hxx>
32cdf0e10cSrcweir #include <optjsearch.hxx>
33cdf0e10cSrcweir #include "optjsearch.hrc"
34cdf0e10cSrcweir
35cdf0e10cSrcweir using namespace com::sun::star::i18n;
36cdf0e10cSrcweir
37cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////
38cdf0e10cSrcweir
SvxJSearchOptionsPage(Window * pParent,const SfxItemSet & rSet)39cdf0e10cSrcweir SvxJSearchOptionsPage::SvxJSearchOptionsPage( Window* pParent, const SfxItemSet& rSet ) :
40cdf0e10cSrcweir SfxTabPage( pParent, CUI_RES( RID_SVXPAGE_JSEARCH_OPTIONS ), rSet ),
41cdf0e10cSrcweir
42cdf0e10cSrcweir aTreatAsEqual ( this, CUI_RES( FL_TREAT_AS_EQUAL ) ),
43cdf0e10cSrcweir aMatchCase ( this, CUI_RES( CB_MATCH_CASE ) ),
44cdf0e10cSrcweir aMatchFullHalfWidth ( this, CUI_RES( CB_MATCH_FULL_HALF_WIDTH ) ),
45cdf0e10cSrcweir aMatchHiraganaKatakana ( this, CUI_RES( CB_MATCH_HIRAGANA_KATAKANA ) ),
46cdf0e10cSrcweir aMatchContractions ( this, CUI_RES( CB_MATCH_CONTRACTIONS ) ),
47cdf0e10cSrcweir aMatchMinusDashChoon ( this, CUI_RES( CB_MATCH_MINUS_DASH_CHOON ) ),
48cdf0e10cSrcweir aMatchRepeatCharMarks ( this, CUI_RES( CB_MATCH_REPEAT_CHAR_MARKS ) ),
49cdf0e10cSrcweir aMatchVariantFormKanji ( this, CUI_RES( CB_MATCH_VARIANT_FORM_KANJI ) ),
50cdf0e10cSrcweir aMatchOldKanaForms ( this, CUI_RES( CB_MATCH_OLD_KANA_FORMS ) ),
51cdf0e10cSrcweir aMatchDiziDuzu ( this, CUI_RES( CB_MATCH_DIZI_DUZU ) ),
52cdf0e10cSrcweir aMatchBavaHafa ( this, CUI_RES( CB_MATCH_BAVA_HAFA ) ),
53cdf0e10cSrcweir aMatchTsithichiDhizi ( this, CUI_RES( CB_MATCH_TSITHICHI_DHIZI ) ),
54cdf0e10cSrcweir aMatchHyuiyuByuvyu ( this, CUI_RES( CB_MATCH_HYUFYU_BYUVYU ) ),
55cdf0e10cSrcweir aMatchSesheZeje ( this, CUI_RES( CB_MATCH_SESHE_ZEJE ) ),
56cdf0e10cSrcweir aMatchIaiya ( this, CUI_RES( CB_MATCH_IAIYA ) ),
57cdf0e10cSrcweir aMatchKiku ( this, CUI_RES( CB_MATCH_KIKU ) ),
58cdf0e10cSrcweir aMatchProlongedSoundMark ( this, CUI_RES( CB_MATCH_PROLONGED_SOUNDMARK ) ),
59cdf0e10cSrcweir aIgnore ( this, CUI_RES( FL_IGNORE ) ),
60cdf0e10cSrcweir aIgnorePunctuation ( this, CUI_RES( CB_IGNORE_PUNCTUATION ) ),
61cdf0e10cSrcweir aIgnoreWhitespace ( this, CUI_RES( CB_IGNORE_WHITESPACES ) ),
62cdf0e10cSrcweir aIgnoreMiddleDot ( this, CUI_RES( CB_IGNORE_MIDDLE_DOT ) )
63cdf0e10cSrcweir {
64cdf0e10cSrcweir FreeResource();
65cdf0e10cSrcweir bSaveOptions = sal_True;
66cdf0e10cSrcweir nTransliterationFlags = 0x00000000;
67cdf0e10cSrcweir }
68cdf0e10cSrcweir
69cdf0e10cSrcweir
~SvxJSearchOptionsPage()70cdf0e10cSrcweir SvxJSearchOptionsPage::~SvxJSearchOptionsPage()
71cdf0e10cSrcweir {
72cdf0e10cSrcweir }
73cdf0e10cSrcweir
74cdf0e10cSrcweir
Create(Window * pParent,const SfxItemSet & rSet)75cdf0e10cSrcweir SfxTabPage* SvxJSearchOptionsPage::Create( Window* pParent, const SfxItemSet& rSet )
76cdf0e10cSrcweir {
77cdf0e10cSrcweir return new SvxJSearchOptionsPage( pParent, rSet );
78cdf0e10cSrcweir }
79cdf0e10cSrcweir
80cdf0e10cSrcweir
SetTransliterationFlags(sal_Int32 nSettings)81cdf0e10cSrcweir void SvxJSearchOptionsPage::SetTransliterationFlags( sal_Int32 nSettings )
82cdf0e10cSrcweir {
83cdf0e10cSrcweir sal_Bool bVal = 0 != (nSettings & TransliterationModules_IGNORE_CASE);
84cdf0e10cSrcweir aMatchCase .Check( bVal ); //! treat as equal uppercase/lowercase
85cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_IGNORE_WIDTH);
86cdf0e10cSrcweir aMatchFullHalfWidth .Check( bVal );
87cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_IGNORE_KANA);
88cdf0e10cSrcweir aMatchHiraganaKatakana .Check( bVal );
89cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreSize_ja_JP);
90cdf0e10cSrcweir aMatchContractions .Check( bVal );
91cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreMinusSign_ja_JP);
92cdf0e10cSrcweir aMatchMinusDashChoon .Check( bVal );
93cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreIterationMark_ja_JP);
94cdf0e10cSrcweir aMatchRepeatCharMarks .Check( bVal );
95cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreTraditionalKanji_ja_JP);
96cdf0e10cSrcweir aMatchVariantFormKanji .Check( bVal );
97cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreTraditionalKana_ja_JP);
98cdf0e10cSrcweir aMatchOldKanaForms .Check( bVal );
99cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreZiZu_ja_JP);
100cdf0e10cSrcweir aMatchDiziDuzu .Check( bVal );
101cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreBaFa_ja_JP);
102cdf0e10cSrcweir aMatchBavaHafa .Check( bVal );
103cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreTiJi_ja_JP);
104cdf0e10cSrcweir aMatchTsithichiDhizi .Check( bVal );
105cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreHyuByu_ja_JP);
106cdf0e10cSrcweir aMatchHyuiyuByuvyu .Check( bVal );
107cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreSeZe_ja_JP);
108cdf0e10cSrcweir aMatchSesheZeje .Check( bVal );
109cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreIandEfollowedByYa_ja_JP);
110cdf0e10cSrcweir aMatchIaiya .Check( bVal );
111cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreKiKuFollowedBySa_ja_JP);
112cdf0e10cSrcweir aMatchKiku .Check( bVal );
113cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreSeparator_ja_JP);
114cdf0e10cSrcweir aIgnorePunctuation .Check( bVal );
115cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreSpace_ja_JP);
116cdf0e10cSrcweir aIgnoreWhitespace .Check( bVal );
117cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreProlongedSoundMark_ja_JP);
118cdf0e10cSrcweir aMatchProlongedSoundMark.Check( bVal );
119cdf0e10cSrcweir bVal = 0 != (nSettings & TransliterationModules_ignoreMiddleDot_ja_JP);
120cdf0e10cSrcweir aIgnoreMiddleDot .Check( bVal );
121cdf0e10cSrcweir
122cdf0e10cSrcweir nTransliterationFlags = nSettings;
123cdf0e10cSrcweir }
124cdf0e10cSrcweir
125cdf0e10cSrcweir
GetTransliterationFlags_Impl()126cdf0e10cSrcweir sal_Int32 SvxJSearchOptionsPage::GetTransliterationFlags_Impl()
127cdf0e10cSrcweir {
128cdf0e10cSrcweir sal_Int32 nTmp = 0;
129cdf0e10cSrcweir if (aMatchCase.IsChecked()) //! treat as equal uppercase/lowercase
130cdf0e10cSrcweir nTmp |= TransliterationModules_IGNORE_CASE;
131cdf0e10cSrcweir if (aMatchFullHalfWidth.IsChecked())
132cdf0e10cSrcweir nTmp |= TransliterationModules_IGNORE_WIDTH;
133cdf0e10cSrcweir if (aMatchHiraganaKatakana.IsChecked())
134cdf0e10cSrcweir nTmp |= TransliterationModules_IGNORE_KANA;
135cdf0e10cSrcweir if (aMatchContractions.IsChecked())
136cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreSize_ja_JP;
137cdf0e10cSrcweir if (aMatchMinusDashChoon.IsChecked())
138cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreMinusSign_ja_JP;
139cdf0e10cSrcweir if (aMatchRepeatCharMarks.IsChecked())
140cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreIterationMark_ja_JP;
141cdf0e10cSrcweir if (aMatchVariantFormKanji.IsChecked())
142cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreTraditionalKanji_ja_JP;
143cdf0e10cSrcweir if (aMatchOldKanaForms.IsChecked())
144cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreTraditionalKana_ja_JP;
145cdf0e10cSrcweir if (aMatchDiziDuzu.IsChecked())
146cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreZiZu_ja_JP;
147cdf0e10cSrcweir if (aMatchBavaHafa.IsChecked())
148cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreBaFa_ja_JP;
149cdf0e10cSrcweir if (aMatchTsithichiDhizi.IsChecked())
150cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreTiJi_ja_JP;
151cdf0e10cSrcweir if (aMatchHyuiyuByuvyu.IsChecked())
152cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreHyuByu_ja_JP;
153cdf0e10cSrcweir if (aMatchSesheZeje.IsChecked())
154cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreSeZe_ja_JP;
155cdf0e10cSrcweir if (aMatchIaiya.IsChecked())
156cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreIandEfollowedByYa_ja_JP;
157cdf0e10cSrcweir if (aMatchKiku.IsChecked())
158cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreKiKuFollowedBySa_ja_JP;
159cdf0e10cSrcweir if (aIgnorePunctuation.IsChecked())
160cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreSeparator_ja_JP;
161cdf0e10cSrcweir if (aIgnoreWhitespace.IsChecked())
162cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreSpace_ja_JP;
163cdf0e10cSrcweir if (aMatchProlongedSoundMark.IsChecked())
164cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreProlongedSoundMark_ja_JP;
165cdf0e10cSrcweir if (aIgnoreMiddleDot.IsChecked())
166cdf0e10cSrcweir nTmp |= TransliterationModules_ignoreMiddleDot_ja_JP;
167cdf0e10cSrcweir
168cdf0e10cSrcweir nTransliterationFlags = nTmp;
169cdf0e10cSrcweir return nTransliterationFlags;
170cdf0e10cSrcweir }
171cdf0e10cSrcweir
172cdf0e10cSrcweir
Reset(const SfxItemSet &)173cdf0e10cSrcweir void SvxJSearchOptionsPage::Reset( const SfxItemSet& )
174cdf0e10cSrcweir {
175cdf0e10cSrcweir SvtSearchOptions aOpt;
176cdf0e10cSrcweir
177cdf0e10cSrcweir // read settings from configuration
178cdf0e10cSrcweir aMatchCase .Check(!aOpt.IsMatchCase() ); //! treat as equal uppercase/lowercase
179cdf0e10cSrcweir aMatchFullHalfWidth .Check( aOpt.IsMatchFullHalfWidthForms() );
180cdf0e10cSrcweir aMatchHiraganaKatakana .Check( aOpt.IsMatchHiraganaKatakana() );
181cdf0e10cSrcweir aMatchContractions .Check( aOpt.IsMatchContractions() );
182cdf0e10cSrcweir aMatchMinusDashChoon .Check( aOpt.IsMatchMinusDashChoon() );
183cdf0e10cSrcweir aMatchRepeatCharMarks .Check( aOpt.IsMatchRepeatCharMarks() );
184cdf0e10cSrcweir aMatchVariantFormKanji .Check( aOpt.IsMatchVariantFormKanji() );
185cdf0e10cSrcweir aMatchOldKanaForms .Check( aOpt.IsMatchOldKanaForms() );
186cdf0e10cSrcweir aMatchDiziDuzu .Check( aOpt.IsMatchDiziDuzu() );
187cdf0e10cSrcweir aMatchBavaHafa .Check( aOpt.IsMatchBavaHafa() );
188cdf0e10cSrcweir aMatchTsithichiDhizi .Check( aOpt.IsMatchTsithichiDhizi() );
189cdf0e10cSrcweir aMatchHyuiyuByuvyu .Check( aOpt.IsMatchHyuiyuByuvyu() );
190cdf0e10cSrcweir aMatchSesheZeje .Check( aOpt.IsMatchSesheZeje() );
191cdf0e10cSrcweir aMatchIaiya .Check( aOpt.IsMatchIaiya() );
192cdf0e10cSrcweir aMatchKiku .Check( aOpt.IsMatchKiku() );
193cdf0e10cSrcweir aIgnorePunctuation .Check( aOpt.IsIgnorePunctuation() );
194cdf0e10cSrcweir aIgnoreWhitespace .Check( aOpt.IsIgnoreWhitespace() );
195cdf0e10cSrcweir aMatchProlongedSoundMark .Check( aOpt.IsIgnoreProlongedSoundMark() );
196cdf0e10cSrcweir aIgnoreMiddleDot .Check( aOpt.IsIgnoreMiddleDot() );
197cdf0e10cSrcweir
198cdf0e10cSrcweir nTransliterationFlags = GetTransliterationFlags_Impl();
199cdf0e10cSrcweir DBG_ASSERT( nTransliterationFlags == aOpt.GetTransliterationFlags(),
200cdf0e10cSrcweir "Transliteration settings different" );
201cdf0e10cSrcweir
202cdf0e10cSrcweir aMatchCase .SaveValue();
203cdf0e10cSrcweir aMatchFullHalfWidth .SaveValue();
204cdf0e10cSrcweir aMatchHiraganaKatakana .SaveValue();
205cdf0e10cSrcweir aMatchContractions .SaveValue();
206cdf0e10cSrcweir aMatchMinusDashChoon .SaveValue();
207cdf0e10cSrcweir aMatchRepeatCharMarks .SaveValue();
208cdf0e10cSrcweir aMatchVariantFormKanji .SaveValue();
209cdf0e10cSrcweir aMatchOldKanaForms .SaveValue();
210cdf0e10cSrcweir aMatchDiziDuzu .SaveValue();
211cdf0e10cSrcweir aMatchBavaHafa .SaveValue();
212cdf0e10cSrcweir aMatchTsithichiDhizi .SaveValue();
213cdf0e10cSrcweir aMatchHyuiyuByuvyu .SaveValue();
214cdf0e10cSrcweir aMatchSesheZeje .SaveValue();
215cdf0e10cSrcweir aMatchIaiya .SaveValue();
216cdf0e10cSrcweir aMatchKiku .SaveValue();
217cdf0e10cSrcweir aIgnorePunctuation .SaveValue();
218cdf0e10cSrcweir aIgnoreWhitespace .SaveValue();
219cdf0e10cSrcweir aMatchProlongedSoundMark .SaveValue();
220cdf0e10cSrcweir aIgnoreMiddleDot .SaveValue();
221cdf0e10cSrcweir }
222cdf0e10cSrcweir
223cdf0e10cSrcweir
FillItemSet(SfxItemSet &)224cdf0e10cSrcweir sal_Bool SvxJSearchOptionsPage::FillItemSet( SfxItemSet& )
225cdf0e10cSrcweir {
226cdf0e10cSrcweir sal_Bool bModified = sal_False;
227cdf0e10cSrcweir
228cdf0e10cSrcweir sal_Int32 nOldVal = nTransliterationFlags;
229cdf0e10cSrcweir nTransliterationFlags = GetTransliterationFlags_Impl();
230cdf0e10cSrcweir bModified = nOldVal != nTransliterationFlags;
231cdf0e10cSrcweir
232cdf0e10cSrcweir if (!IsSaveOptions())
233cdf0e10cSrcweir return bModified;
234cdf0e10cSrcweir
235cdf0e10cSrcweir bModified = sal_False;
236cdf0e10cSrcweir SvtSearchOptions aOpt;
237cdf0e10cSrcweir sal_Bool bNewVal, bChanged;
238cdf0e10cSrcweir
239cdf0e10cSrcweir bNewVal = aMatchCase.IsChecked(); //! treat as equal uppercase/lowercase
240cdf0e10cSrcweir bChanged = bNewVal != aMatchCase.GetSavedValue();
241cdf0e10cSrcweir if (bChanged)
242cdf0e10cSrcweir {
243cdf0e10cSrcweir aOpt.SetMatchCase(!bNewVal );
244cdf0e10cSrcweir bModified = sal_True;
245cdf0e10cSrcweir }
246cdf0e10cSrcweir bNewVal = aMatchFullHalfWidth.IsChecked();
247cdf0e10cSrcweir bChanged = bNewVal != aMatchFullHalfWidth.GetSavedValue();
248cdf0e10cSrcweir if (bChanged)
249cdf0e10cSrcweir {
250cdf0e10cSrcweir aOpt.SetMatchFullHalfWidthForms( bNewVal );
251cdf0e10cSrcweir bModified = sal_True;
252cdf0e10cSrcweir }
253cdf0e10cSrcweir bNewVal = aMatchHiraganaKatakana.IsChecked();
254cdf0e10cSrcweir bChanged = bNewVal != aMatchHiraganaKatakana.GetSavedValue();
255cdf0e10cSrcweir if (bChanged)
256cdf0e10cSrcweir {
257cdf0e10cSrcweir aOpt.SetMatchHiraganaKatakana( bNewVal );
258cdf0e10cSrcweir bModified = sal_True;
259cdf0e10cSrcweir }
260cdf0e10cSrcweir bNewVal = aMatchContractions.IsChecked();
261cdf0e10cSrcweir bChanged = bNewVal != aMatchContractions.GetSavedValue();
262cdf0e10cSrcweir if (bChanged)
263cdf0e10cSrcweir {
264cdf0e10cSrcweir aOpt.SetMatchContractions( bNewVal );
265cdf0e10cSrcweir bModified = sal_True;
266cdf0e10cSrcweir }
267cdf0e10cSrcweir bNewVal = aMatchMinusDashChoon.IsChecked();
268cdf0e10cSrcweir bChanged = bNewVal != aMatchMinusDashChoon.GetSavedValue();
269cdf0e10cSrcweir if (bChanged)
270cdf0e10cSrcweir {
271cdf0e10cSrcweir aOpt.SetMatchMinusDashChoon( bNewVal );
272cdf0e10cSrcweir bModified = sal_True;
273cdf0e10cSrcweir }
274cdf0e10cSrcweir bNewVal = aMatchRepeatCharMarks.IsChecked();
275cdf0e10cSrcweir bChanged = bNewVal != aMatchRepeatCharMarks.GetSavedValue();
276cdf0e10cSrcweir if (bChanged)
277cdf0e10cSrcweir {
278cdf0e10cSrcweir aOpt.SetMatchRepeatCharMarks( bNewVal );
279cdf0e10cSrcweir bModified = sal_True;
280cdf0e10cSrcweir }
281cdf0e10cSrcweir bNewVal = aMatchVariantFormKanji.IsChecked();
282cdf0e10cSrcweir bChanged = bNewVal != aMatchVariantFormKanji.GetSavedValue();
283cdf0e10cSrcweir if (bChanged)
284cdf0e10cSrcweir {
285cdf0e10cSrcweir aOpt.SetMatchVariantFormKanji( bNewVal );
286cdf0e10cSrcweir bModified = sal_True;
287cdf0e10cSrcweir }
288cdf0e10cSrcweir bNewVal = aMatchOldKanaForms.IsChecked();
289cdf0e10cSrcweir bChanged = bNewVal != aMatchOldKanaForms.GetSavedValue();
290cdf0e10cSrcweir if (bChanged)
291cdf0e10cSrcweir {
292cdf0e10cSrcweir aOpt.SetMatchOldKanaForms( bNewVal );
293cdf0e10cSrcweir bModified = sal_True;
294cdf0e10cSrcweir }
295cdf0e10cSrcweir bNewVal = aMatchDiziDuzu.IsChecked();
296cdf0e10cSrcweir bChanged = bNewVal != aMatchDiziDuzu.GetSavedValue();
297cdf0e10cSrcweir if (bChanged)
298cdf0e10cSrcweir {
299cdf0e10cSrcweir aOpt.SetMatchDiziDuzu( bNewVal );
300cdf0e10cSrcweir bModified = sal_True;
301cdf0e10cSrcweir }
302cdf0e10cSrcweir bNewVal = aMatchBavaHafa.IsChecked();
303cdf0e10cSrcweir bChanged = bNewVal != aMatchBavaHafa.GetSavedValue();
304cdf0e10cSrcweir if (bChanged)
305cdf0e10cSrcweir {
306cdf0e10cSrcweir aOpt.SetMatchBavaHafa( bNewVal );
307cdf0e10cSrcweir bModified = sal_True;
308cdf0e10cSrcweir }
309cdf0e10cSrcweir bNewVal = aMatchTsithichiDhizi.IsChecked();
310cdf0e10cSrcweir bChanged = bNewVal != aMatchTsithichiDhizi.GetSavedValue();
311cdf0e10cSrcweir if (bChanged)
312cdf0e10cSrcweir {
313cdf0e10cSrcweir aOpt.SetMatchTsithichiDhizi( bNewVal );
314cdf0e10cSrcweir bModified = sal_True;
315cdf0e10cSrcweir }
316cdf0e10cSrcweir bNewVal = aMatchHyuiyuByuvyu.IsChecked();
317cdf0e10cSrcweir bChanged = bNewVal != aMatchHyuiyuByuvyu.GetSavedValue();
318cdf0e10cSrcweir if (bChanged)
319cdf0e10cSrcweir {
320cdf0e10cSrcweir aOpt.SetMatchHyuiyuByuvyu( bNewVal );
321cdf0e10cSrcweir bModified = sal_True;
322cdf0e10cSrcweir }
323cdf0e10cSrcweir bNewVal = aMatchSesheZeje.IsChecked();
324cdf0e10cSrcweir bChanged = bNewVal != aMatchSesheZeje.GetSavedValue();
325cdf0e10cSrcweir if (bChanged)
326cdf0e10cSrcweir {
327cdf0e10cSrcweir aOpt.SetMatchSesheZeje( bNewVal );
328cdf0e10cSrcweir bModified = sal_True;
329cdf0e10cSrcweir }
330cdf0e10cSrcweir bNewVal = aMatchIaiya.IsChecked();
331cdf0e10cSrcweir bChanged = bNewVal != aMatchIaiya.GetSavedValue();
332cdf0e10cSrcweir if (bChanged)
333cdf0e10cSrcweir {
334cdf0e10cSrcweir aOpt.SetMatchIaiya( bNewVal );
335cdf0e10cSrcweir bModified = sal_True;
336cdf0e10cSrcweir }
337cdf0e10cSrcweir bNewVal = aMatchKiku.IsChecked();
338cdf0e10cSrcweir bChanged = bNewVal != aMatchKiku.GetSavedValue();
339cdf0e10cSrcweir if (bChanged)
340cdf0e10cSrcweir {
341cdf0e10cSrcweir aOpt.SetMatchKiku( bNewVal );
342cdf0e10cSrcweir bModified = sal_True;
343cdf0e10cSrcweir }
344cdf0e10cSrcweir bNewVal = aIgnorePunctuation.IsChecked();
345cdf0e10cSrcweir bChanged = bNewVal != aIgnorePunctuation.GetSavedValue();
346cdf0e10cSrcweir if (bChanged)
347cdf0e10cSrcweir {
348cdf0e10cSrcweir aOpt.SetIgnorePunctuation( bNewVal );
349cdf0e10cSrcweir bModified = sal_True;
350cdf0e10cSrcweir }
351cdf0e10cSrcweir bNewVal = aIgnoreWhitespace.IsChecked();
352cdf0e10cSrcweir bChanged = bNewVal != aIgnoreWhitespace.GetSavedValue();
353cdf0e10cSrcweir if (bChanged)
354cdf0e10cSrcweir {
355cdf0e10cSrcweir aOpt.SetIgnoreWhitespace( bNewVal );
356cdf0e10cSrcweir bModified = sal_True;
357cdf0e10cSrcweir }
358cdf0e10cSrcweir bNewVal = aMatchProlongedSoundMark.IsChecked();
359cdf0e10cSrcweir bChanged = bNewVal != aMatchProlongedSoundMark.GetSavedValue();
360cdf0e10cSrcweir if (bChanged)
361cdf0e10cSrcweir {
362cdf0e10cSrcweir aOpt.SetIgnoreProlongedSoundMark( bNewVal );
363cdf0e10cSrcweir bModified = sal_True;
364cdf0e10cSrcweir }
365cdf0e10cSrcweir bNewVal = aIgnoreMiddleDot.IsChecked();
366cdf0e10cSrcweir bChanged = bNewVal != aIgnoreMiddleDot.GetSavedValue();
367cdf0e10cSrcweir if (bChanged)
368cdf0e10cSrcweir {
369cdf0e10cSrcweir aOpt.SetIgnoreMiddleDot( bNewVal );
370cdf0e10cSrcweir bModified = sal_True;
371cdf0e10cSrcweir }
372cdf0e10cSrcweir
373cdf0e10cSrcweir return bModified;
374cdf0e10cSrcweir }
375cdf0e10cSrcweir
376cdf0e10cSrcweir
377cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////
378cdf0e10cSrcweir
379