From 7150ce717fb24893d5b527a0587cc166f7c6ec68 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Mon, 4 Mar 2024 14:25:52 +0200 Subject: [PATCH] remove deprecated IsGermanPreReform property deprecated in 2008 (and seemingly never even implemented) Replace the use of this property in sample code and in Java unit tests with another property (I arbitrarily selected "IsIgnoreControlCharacters") Change-Id: I2cb474f895ac221952b59e98bfdbc01012095519 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164355 Tested-by: Jenkins Reviewed-by: Noel Grandin --- include/unotools/linguprops.hxx | 72 +++++++++---------- .../source/thesaurus/libnth/nthesdta.cxx | 4 -- .../source/thesaurus/libnth/nthesdta.hxx | 5 -- linguistic/source/lngopt.cxx | 2 - linguistic/workben/sprophelp.cxx | 17 +---- linguistic/workben/sprophelp.hxx | 3 - .../Linguistic/LinguisticExamples.java | 6 +- .../Linguistic/PropChgHelper_Hyph.java | 1 - .../Linguistic/PropChgHelper_Spell.java | 4 -- .../Linguistic/SampleHyphenator.java | 32 +-------- .../Linguistic/SampleSpellChecker.java | 15 +--- .../OfficeDev/Linguistic/SampleThesaurus.java | 2 - .../lng/com.sun.star.lingu2.LinguProps.csv | 1 - .../ifc/linguistic2/_LinguProperties.java | 1 - qadevOOo/tests/java/mod/_lnn/Hyphenator.java | 6 -- 15 files changed, 43 insertions(+), 128 deletions(-) diff --git a/include/unotools/linguprops.hxx b/include/unotools/linguprops.hxx index 81d2748eef3b..4c04e982cfa5 100644 --- a/include/unotools/linguprops.hxx +++ b/include/unotools/linguprops.hxx @@ -26,7 +26,6 @@ #endif // UNO property names for general options -inline constexpr OUString UPN_IS_GERMAN_PRE_REFORM = u"IsGermanPreReform"_ustr; /*! deprecated #i91949 !*/ inline constexpr OUString UPN_IS_USE_DICTIONARY_LIST = u"IsUseDictionaryList"_ustr; inline constexpr OUString UPN_IS_IGNORE_CONTROL_CHARACTERS = u"IsIgnoreControlCharacters"_ustr; inline constexpr OUString UPN_ACTIVE_DICTIONARIES = u"ActiveDictionaries"_ustr; @@ -75,42 +74,41 @@ inline constexpr OUString UPN_IS_GRAMMAR_AUTO = u"IsAutoGrammarC inline constexpr OUString UPN_IS_GRAMMAR_INTERACTIVE = u"IsInteractiveGrammarCheck"_ustr; // uno property handles -#define UPH_IS_GERMAN_PRE_REFORM 0 -#define UPH_IS_USE_DICTIONARY_LIST 1 -#define UPH_IS_IGNORE_CONTROL_CHARACTERS 2 -#define UPH_IS_SPELL_UPPER_CASE 3 -#define UPH_IS_SPELL_WITH_DIGITS 4 -#define UPH_HYPH_MIN_LEADING 5 -#define UPH_HYPH_MIN_TRAILING 6 -#define UPH_HYPH_MIN_WORD_LENGTH 7 -#define UPH_DEFAULT_LOCALE 8 -#define UPH_IS_SPELL_AUTO 9 -#define UPH_IS_SPELL_CLOSED_COMPOUND 10 -#define UPH_IS_SPELL_HYPHENATED_COMPOUND 11 -#define UPH_IS_SPELL_SPECIAL 12 -#define UPH_IS_HYPH_AUTO 13 -#define UPH_IS_HYPH_SPECIAL 14 -#define UPH_IS_WRAP_REVERSE 15 -#define UPH_DATA_FILES_CHANGED_CHECK_VALUE 16 -#define UPH_DEFAULT_LANGUAGE 17 -#define UPH_DEFAULT_LOCALE_CJK 18 -#define UPH_DEFAULT_LOCALE_CTL 19 -#define UPH_ACTIVE_DICTIONARIES 20 -#define UPH_ACTIVE_CONVERSION_DICTIONARIES 21 -#define UPH_IS_IGNORE_POST_POSITIONAL_WORD 22 -#define UPH_IS_AUTO_CLOSE_DIALOG 23 -#define UPH_IS_SHOW_ENTRIES_RECENTLY_USED_FIRST 24 -#define UPH_IS_AUTO_REPLACE_UNIQUE_ENTRIES 25 -#define UPH_IS_DIRECTION_TO_SIMPLIFIED 26 -#define UPH_IS_USE_CHARACTER_VARIANTS 27 -#define UPH_IS_TRANSLATE_COMMON_TERMS 28 -#define UPH_IS_REVERSE_MAPPING 29 -#define UPH_IS_GRAMMAR_AUTO 30 -#define UPH_IS_GRAMMAR_INTERACTIVE 31 -#define UPH_HYPH_NO_CAPS 32 -#define UPH_HYPH_NO_LAST_WORD 33 -#define UPH_HYPH_ZONE 34 -#define UPH_HYPH_KEEP 35 +#define UPH_IS_USE_DICTIONARY_LIST 0 +#define UPH_IS_IGNORE_CONTROL_CHARACTERS 1 +#define UPH_IS_SPELL_UPPER_CASE 2 +#define UPH_IS_SPELL_WITH_DIGITS 3 +#define UPH_HYPH_MIN_LEADING 4 +#define UPH_HYPH_MIN_TRAILING 5 +#define UPH_HYPH_MIN_WORD_LENGTH 6 +#define UPH_DEFAULT_LOCALE 7 +#define UPH_IS_SPELL_AUTO 8 +#define UPH_IS_SPELL_CLOSED_COMPOUND 9 +#define UPH_IS_SPELL_HYPHENATED_COMPOUND 10 +#define UPH_IS_SPELL_SPECIAL 11 +#define UPH_IS_HYPH_AUTO 12 +#define UPH_IS_HYPH_SPECIAL 13 +#define UPH_IS_WRAP_REVERSE 14 +#define UPH_DATA_FILES_CHANGED_CHECK_VALUE 15 +#define UPH_DEFAULT_LANGUAGE 16 +#define UPH_DEFAULT_LOCALE_CJK 17 +#define UPH_DEFAULT_LOCALE_CTL 18 +#define UPH_ACTIVE_DICTIONARIES 19 +#define UPH_ACTIVE_CONVERSION_DICTIONARIES 20 +#define UPH_IS_IGNORE_POST_POSITIONAL_WORD 21 +#define UPH_IS_AUTO_CLOSE_DIALOG 22 +#define UPH_IS_SHOW_ENTRIES_RECENTLY_USED_FIRST 23 +#define UPH_IS_AUTO_REPLACE_UNIQUE_ENTRIES 24 +#define UPH_IS_DIRECTION_TO_SIMPLIFIED 25 +#define UPH_IS_USE_CHARACTER_VARIANTS 26 +#define UPH_IS_TRANSLATE_COMMON_TERMS 27 +#define UPH_IS_REVERSE_MAPPING 28 +#define UPH_IS_GRAMMAR_AUTO 29 +#define UPH_IS_GRAMMAR_INTERACTIVE 30 +#define UPH_HYPH_NO_CAPS 31 +#define UPH_HYPH_NO_LAST_WORD 32 +#define UPH_HYPH_ZONE 33 +#define UPH_HYPH_KEEP 34 #ifdef __GNUC__ #pragma GCC diagnostic pop diff --git a/lingucomponent/source/thesaurus/libnth/nthesdta.cxx b/lingucomponent/source/thesaurus/libnth/nthesdta.cxx index 6d076d84841a..e69df4ab4c38 100644 --- a/lingucomponent/source/thesaurus/libnth/nthesdta.cxx +++ b/lingucomponent/source/thesaurus/libnth/nthesdta.cxx @@ -37,10 +37,6 @@ Meaning::Meaning(OUString _aTerm) : aSyn ( Sequence< OUString >(1) ), aTerm (std::move(_aTerm)) { -#if 0 - // this is for future use by a german thesaurus when one exists - bIsGermanPreReform = rHelper.IsGermanPreReform; -#endif } Meaning::~Meaning() diff --git a/lingucomponent/source/thesaurus/libnth/nthesdta.hxx b/lingucomponent/source/thesaurus/libnth/nthesdta.hxx index fb2c6438d751..8c18542b6138 100644 --- a/lingucomponent/source/thesaurus/libnth/nthesdta.hxx +++ b/lingucomponent/source/thesaurus/libnth/nthesdta.hxx @@ -32,11 +32,6 @@ class Meaning : css::uno::Sequence< OUString > aSyn; // list of synonyms, may be empty. OUString aTerm; -#if 0 - // this is for future use by a German thesaurus - sal_Bool bIsGermanPreReform; -#endif - Meaning(const Meaning &) = delete; Meaning & operator = (const Meaning &) = delete; diff --git a/linguistic/source/lngopt.cxx b/linguistic/source/lngopt.cxx index c33a05ab3a6f..42bb6df95719 100644 --- a/linguistic/source/lngopt.cxx +++ b/linguistic/source/lngopt.cxx @@ -155,8 +155,6 @@ static std::span lcl_GetLinguProps() ::cppu::UnoType::get(), 0, 0 }, { UPN_HYPH_MIN_WORD_LENGTH, UPH_HYPH_MIN_WORD_LENGTH, ::cppu::UnoType::get(), 0, 0 }, - { UPN_IS_GERMAN_PRE_REFORM, UPH_IS_GERMAN_PRE_REFORM, /*! deprecated !*/ - cppu::UnoType::get(), 0, 0 }, { UPN_IS_HYPH_AUTO, UPH_IS_HYPH_AUTO, cppu::UnoType::get(), 0, 0 }, { UPN_IS_HYPH_SPECIAL, UPH_IS_HYPH_SPECIAL, diff --git a/linguistic/workben/sprophelp.cxx b/linguistic/workben/sprophelp.cxx index 9da626319a72..f6326ba55fee 100644 --- a/linguistic/workben/sprophelp.cxx +++ b/linguistic/workben/sprophelp.cxx @@ -162,7 +162,6 @@ sal_Bool SAL_CALL static const char *aSP[] = { - UPN_IS_GERMAN_PRE_REFORM, UPN_IS_IGNORE_CONTROL_CHARACTERS, UPN_IS_USE_DICTIONARY_LIST, UPN_IS_SPELL_UPPER_CASE, @@ -188,12 +187,7 @@ PropertyHelper_Spell::PropertyHelper_Spell( sal_Bool *pbVal = NULL, *pbResVal = NULL; - if (OUString( UPN_IS_GERMAN_PRE_REFORM ) == pPropName[i]) - { - pbVal = &bIsGermanPreReform; - pbResVal = &bResIsGermanPreReform; - } - else if (OUString( UPN_IS_IGNORE_CONTROL_CHARACTERS ) == pPropName[i]) + if (OUString( UPN_IS_IGNORE_CONTROL_CHARACTERS ) == pPropName[i]) { pbVal = &bIsIgnoreControlCharacters; pbResVal = &bResIsIgnoreControlCharacters; @@ -246,7 +240,6 @@ PropertyHelper_Spell::~PropertyHelper_Spell() void PropertyHelper_Spell::SetDefault() { - bResIsGermanPreReform = bIsGermanPreReform = sal_False; bResIsIgnoreControlCharacters = bIsIgnoreControlCharacters = sal_True; bResIsUseDictionaryList = bIsUseDictionaryList = sal_True; bResIsSpellUpperCase = bIsSpellUpperCase = sal_False; @@ -277,12 +270,6 @@ void SAL_CALL pbVal = &bIsIgnoreControlCharacters; break; } - case UPH_IS_GERMAN_PRE_REFORM : - { - pbVal = &bIsGermanPreReform; - bSCWA = bSWWA = sal_True; - break; - } case UPH_IS_USE_DICTIONARY_LIST : { pbVal = &bIsUseDictionaryList; @@ -348,7 +335,6 @@ void PropertyHelper_Spell::SetTmpPropVals( const PropertyValues &rPropVals ) { // set return value to default value unless there is an // explicitly supplied temporary value - bResIsGermanPreReform = bIsGermanPreReform; bResIsIgnoreControlCharacters = bIsIgnoreControlCharacters; bResIsUseDictionaryList = bIsUseDictionaryList; bResIsSpellUpperCase = bIsSpellUpperCase; @@ -366,7 +352,6 @@ void PropertyHelper_Spell::SetTmpPropVals( const PropertyValues &rPropVals ) sal_Bool *pbResVal = NULL; switch (pVal[i].Handle) { - case UPH_IS_GERMAN_PRE_REFORM : pbResVal = &bResIsGermanPreReform; break; case UPH_IS_IGNORE_CONTROL_CHARACTERS : pbResVal = &bResIsIgnoreControlCharacters; break; case UPH_IS_USE_DICTIONARY_LIST : pbResVal = &bResIsUseDictionaryList; break; case UPH_IS_SPELL_UPPER_CASE : pbResVal = &bResIsSpellUpperCase; break; diff --git a/linguistic/workben/sprophelp.hxx b/linguistic/workben/sprophelp.hxx index 55fd48198387..3882c0abba5a 100644 --- a/linguistic/workben/sprophelp.hxx +++ b/linguistic/workben/sprophelp.hxx @@ -106,7 +106,6 @@ class PropertyHelper_Spell : public PropertyChgHelper { // default values - sal_Bool bIsGermanPreReform; sal_Bool bIsIgnoreControlCharacters; sal_Bool bIsUseDictionaryList; sal_Bool bIsSpellUpperCase; @@ -114,7 +113,6 @@ class PropertyHelper_Spell : sal_Bool bIsSpellCapitalization; // return values, will be set to default value or current temporary value - sal_Bool bResIsGermanPreReform; sal_Bool bResIsIgnoreControlCharacters; sal_Bool bResIsUseDictionaryList; sal_Bool bResIsSpellUpperCase; @@ -141,7 +139,6 @@ public: void SetTmpPropVals( const PropertyValues &rPropVals ); - sal_Bool IsGermanPreReform() const { return bResIsGermanPreReform; } sal_Bool IsIgnoreControlCharacters() const { return bResIsIgnoreControlCharacters; } sal_Bool IsUseDictionaryList() const { return bResIsUseDictionaryList; } sal_Bool IsSpellUpperCase() const { return bResIsSpellUpperCase; } diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/LinguisticExamples.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/LinguisticExamples.java index 9cbd481cb4b0..35a1a39e6e3b 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/LinguisticExamples.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/LinguisticExamples.java @@ -174,7 +174,7 @@ public class LinguisticExamples // in the LinguProperties property set need to be supllied. PropertyValue[] aProps = new PropertyValue[1]; aProps[0] = new PropertyValue(); - aProps[0].Name = "IsGermanPreReform"; + aProps[0].Name = "IsIgnoreControlCharacters"; aProps[0].Value = Boolean.TRUE; @@ -293,7 +293,7 @@ public class LinguisticExamples // set a spellchecker and hyphenator property value to a defined state try { - aLinguProps.setPropertyValue("IsGermanPreReform", Boolean.TRUE); + aLinguProps.setPropertyValue("IsIgnoreControlCharacters", Boolean.TRUE); } catch (Exception e) { } @@ -306,7 +306,7 @@ public class LinguisticExamples // event that eventually results in the listeners // 'processLinguServiceEvent' function being called try { - aLinguProps.setPropertyValue("IsGermanPreReform", Boolean.FALSE); + aLinguProps.setPropertyValue("IsIgnoreControlCharacters", Boolean.FALSE); } catch (Exception e) { } diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Hyph.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Hyph.java index 0945e413f11e..d1a6fb2e9752 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Hyph.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Hyph.java @@ -61,7 +61,6 @@ public class PropChgHelper_Hyph extends PropChgHelper // nothing to be done } else if (aEvt.PropertyName.equals( "IsUseDictionaryList" ) || - aEvt.PropertyName.equals( "IsGermanPreReform" ) || aEvt.PropertyName.equals( "HyphMinLeading" ) || aEvt.PropertyName.equals( "HyphMinTrailing" ) || aEvt.PropertyName.equals( "HyphMinWordLength" )) diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Spell.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Spell.java index a2df6db5f4fb..ff1bd4907fb3 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Spell.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Spell.java @@ -65,10 +65,6 @@ public class PropChgHelper_Spell extends PropChgHelper { // nothing to be done } - else if (aEvt.PropertyName.equals( "IsGermanPreReform" )) - { - bSCWA = bSWWA = true; - } else if (aEvt.PropertyName.equals( "IsUseDictionaryList" )) { bSCWA = bSWWA = true; diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleHyphenator.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleHyphenator.java index 930d42c320d7..4fcd413a723b 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleHyphenator.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleHyphenator.java @@ -79,7 +79,6 @@ public class SampleHyphenator extends ComponentBase implements { "IsIgnoreControlCharacters", "IsUseDictionaryList", - "IsGermanPreReform", "HyphMinLeading", "HyphMinTrailing", "HyphMinWordLength" @@ -225,7 +224,6 @@ public class SampleHyphenator extends ComponentBase implements //! them here. boolean bIsIgnoreControlCharacters = GetValueToUse( "IsIgnoreControlCharacters", true, aProperties ); boolean bIsUseDictionaryList = GetValueToUse( "IsUseDictionaryList", true, aProperties ); - boolean bIsGermanPreReform = GetValueToUse( "IsGermanPreReform", false, aProperties ); short nHyphMinLeading = GetValueToUse( "HyphMinLeading", (short)2, aProperties ); short nHyphMinTrailing = GetValueToUse( "HyphMinTrailing", (short)2, aProperties ); short nHyphMinWordLen = GetValueToUse( "HyphMinWordLength", (short)5, aProperties ); @@ -242,16 +240,7 @@ public class SampleHyphenator extends ComponentBase implements //!! implementation of your hyphenator if (IsEqual( aLocale, new Locale( "de", "DE", "" ) ) ) { - if (bIsGermanPreReform && aWord.equals( "Schiffahrt" )) - { - // Note: there is only one position where the word - // can be hyphenated... - - aHyphenatedWord = "Schifffahrt"; - nHyphenationPos = 4; - nHyphenPos = 5; - } - else if (!bIsGermanPreReform && aWord.equals( "Schifffahrt" )) + if (aWord.equals( "Schifffahrt" )) { nHyphenationPos = nHyphenPos = 5; } @@ -306,7 +295,6 @@ public class SampleHyphenator extends ComponentBase implements //! them here. boolean bIsIgnoreControlCharacters = GetValueToUse( "IsIgnoreControlCharacters", true, aProperties ); boolean bIsUseDictionaryList = GetValueToUse( "IsUseDictionaryList", true, aProperties ); - boolean bIsGermanPreReform = GetValueToUse( "IsGermanPreReform", false, aProperties ); short nHyphMinLeading = GetValueToUse( "HyphMinLeading", (short)2, aProperties ); short nHyphMinTrailing = GetValueToUse( "HyphMinTrailing", (short)2, aProperties ); short nHyphMinWordLen = GetValueToUse( "HyphMinWordLength", (short)5, aProperties ); @@ -317,15 +305,6 @@ public class SampleHyphenator extends ComponentBase implements //!! implementation of your hyphenator if ( IsEqual( aLocale, new Locale( "de", "DE", "" ) ) ) { - // there is an alternative spelling only when the - // word is hyphenated between the "ff" and old german spelling - // is set. - if (aWord.equals( "Schiffahrt" ) && - bIsGermanPreReform && nIndex == 4) - { - xRes = new XHyphenatedWord_impl(aWord, aLocale, - (short)4, "Schifffahrt", (short)5 ); - } } else if ( IsEqual( aLocale, new Locale( "en", "US", "" ) ) ) { @@ -355,7 +334,6 @@ public class SampleHyphenator extends ComponentBase implements //! them here. boolean bIsIgnoreControlCharacters = GetValueToUse( "IsIgnoreControlCharacters", true, aProperties ); boolean bIsUseDictionaryList = GetValueToUse( "IsUseDictionaryList", true, aProperties ); - boolean bIsGermanPreReform = GetValueToUse( "IsGermanPreReform", false, aProperties ); short nHyphMinLeading = GetValueToUse( "HyphMinLeading", (short)2, aProperties ); short nHyphMinTrailing = GetValueToUse( "HyphMinTrailing", (short)2, aProperties ); short nHyphMinWordLen = GetValueToUse( "HyphMinWordLength", (short)5, aProperties ); @@ -366,13 +344,7 @@ public class SampleHyphenator extends ComponentBase implements //!! implementation of your hyphenator if ( IsEqual( aLocale, new Locale( "de", "DE", "" ) ) ) { - if (bIsGermanPreReform && aWord.equals( "Schiffahrt" )) - { - short aPos[] = new short[] { (short) 4 }; - xRes = new XPossibleHyphens_impl(aWord, aLocale, - "Schiff=fahrt", aPos); - } - else if (!bIsGermanPreReform && aWord.equals( "Schifffahrt" )) + if (aWord.equals( "Schifffahrt" )) { short aPos[] = new short[] { (short) 5 }; xRes = new XPossibleHyphens_impl(aWord, aLocale, diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleSpellChecker.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleSpellChecker.java index ab4f565b30df..9608929932fa 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleSpellChecker.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleSpellChecker.java @@ -79,7 +79,6 @@ public class SampleSpellChecker extends ComponentBase implements { "IsIgnoreControlCharacters", "IsUseDictionaryList", - "IsGermanPreReform", "IsSpellUpperCase", "IsSpellWithDigits", }; @@ -161,12 +160,9 @@ public class SampleSpellChecker extends ComponentBase implements //!! This code needs to be replaced by code calling the actual //!! implementation of your spellchecker - boolean bIsGermanPreReform = GetValueToUse( "IsGermanPreReform", false, aProperties ); if (IsEqual( aLocale, new Locale( "de", "DE", "" ) )) { - if (bIsGermanPreReform && aWord.equals( "Schifffahrt" )) - nRes = SpellFailure.SPELLING_ERROR; - else if (!bIsGermanPreReform && aWord.equals( "Schiffahrt" )) + if (aWord.equals( "Schiffahrt" )) nRes = SpellFailure.SPELLING_ERROR; } else if (IsEqual( aLocale, new Locale( "en", "US", "" ) )) @@ -204,7 +200,6 @@ public class SampleSpellChecker extends ComponentBase implements //! The values for 'IsIgnoreControlCharacters' and 'IsUseDictionaryList' //! are handled by the dispatcher! Thus there is no need to access //! them here. - boolean bIsGermanPreReform = GetValueToUse( "IsGermanPreReform", false, aProperties ); boolean bIsSpellWithDigits = GetValueToUse( "IsSpellWithDigits", false, aProperties ); boolean bIsSpellUpperCase = GetValueToUse( "IsSpellUpperCase", false, aProperties ); @@ -212,12 +207,7 @@ public class SampleSpellChecker extends ComponentBase implements //!! implementation of your spellchecker if (IsEqual( aLocale, new Locale( "de", "DE", "" ) )) { - if (bIsGermanPreReform && aWord.equals( "Schifffahrt" )) - { - nType = SpellFailure.SPELLING_ERROR; - aProposals = new String[]{ "Schiffahrt" }; - } - else if (!bIsGermanPreReform && aWord.equals( "Schiffahrt" )) + if (aWord.equals( "Schiffahrt" )) { nType = SpellFailure.SPELLING_ERROR; aProposals = new String[]{ "Schifffahrt" }; @@ -298,7 +288,6 @@ public class SampleSpellChecker extends ComponentBase implements //! The values for 'IsIgnoreControlCharacters' and 'IsUseDictionaryList' //! are handled by the dispatcher! Thus there is no need to access //! them here. - boolean bIsGermanPreReform = GetValueToUse( "IsGermanPreReform", false, aProperties ); boolean bIsSpellWithDigits = GetValueToUse( "IsSpellWithDigits", false, aProperties ); boolean bIsSpellUpperCase = GetValueToUse( "IsSpellUpperCase", false, aProperties ); diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleThesaurus.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleThesaurus.java index f5c437095ec2..420d85d481aa 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleThesaurus.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleThesaurus.java @@ -73,7 +73,6 @@ public class SampleThesaurus extends ComponentBase implements { "IsIgnoreControlCharacters", "IsUseDictionaryList", - "IsGermanPreReform", }; // this service has no listeners thus we may use the base class, @@ -179,7 +178,6 @@ public class SampleThesaurus extends ComponentBase implements //! The values for 'IsIgnoreControlCharacters' and 'IsUseDictionaryList' //! are handled by the dispatcher! Thus there is no need to access //! them here. - boolean bIsGermanPreReform = GetValueToUse( "IsGermanPreReform", false, aProperties ); XMeaning[] aRes = null; diff --git a/qadevOOo/objdsc/lng/com.sun.star.lingu2.LinguProps.csv b/qadevOOo/objdsc/lng/com.sun.star.lingu2.LinguProps.csv index b2b6b1d16bfa..37e61d1d30fd 100644 --- a/qadevOOo/objdsc/lng/com.sun.star.lingu2.LinguProps.csv +++ b/qadevOOo/objdsc/lng/com.sun.star.lingu2.LinguProps.csv @@ -1,4 +1,3 @@ -"LinguProps";"com::sun::star::linguistic2::LinguProperties";"IsGermanPreReform" "LinguProps";"com::sun::star::linguistic2::LinguProperties";"IsUseDictionaryList" "LinguProps";"com::sun::star::linguistic2::LinguProperties";"IsIgnoreControlCharacters" "LinguProps";"com::sun::star::linguistic2::LinguProperties";"IsSpellUpperCase" diff --git a/qadevOOo/tests/java/ifc/linguistic2/_LinguProperties.java b/qadevOOo/tests/java/ifc/linguistic2/_LinguProperties.java index f81b496311fa..2c28fcd51bc6 100644 --- a/qadevOOo/tests/java/ifc/linguistic2/_LinguProperties.java +++ b/qadevOOo/tests/java/ifc/linguistic2/_LinguProperties.java @@ -24,7 +24,6 @@ import lib.MultiPropertyTest; * Testing com.sun.star.linguistic2.LinguProperties * service properties: *
    -*
  • 'IsGermanPreReform'
  • *
  • 'IsUseDictionaryList'
  • *
  • 'IsIgnoreControlCharacters'
  • *
  • 'IsSpellUpperCase'
  • diff --git a/qadevOOo/tests/java/mod/_lnn/Hyphenator.java b/qadevOOo/tests/java/mod/_lnn/Hyphenator.java index 40577a2115b7..c88eb621a6d4 100644 --- a/qadevOOo/tests/java/mod/_lnn/Hyphenator.java +++ b/qadevOOo/tests/java/mod/_lnn/Hyphenator.java @@ -24,9 +24,7 @@ import lib.TestCase; import lib.TestEnvironment; import lib.TestParameters; -import com.sun.star.beans.XPropertySet; import com.sun.star.lang.XMultiServiceFactory; -import com.sun.star.uno.UnoRuntime; import com.sun.star.uno.XInterface; /** @@ -77,10 +75,6 @@ public class Hyphenator extends TestCase { XMultiServiceFactory xMSF = Param.getMSF(); XInterface oObj = (XInterface)xMSF.createInstance ("com.sun.star.linguistic2.Hyphenator"); - Object LP = xMSF.createInstance - ("com.sun.star.linguistic2.LinguProperties"); - XPropertySet LProps = UnoRuntime.queryInterface(XPropertySet.class,LP); - LProps.setPropertyValue("IsGermanPreReform",Boolean.TRUE); String Iname = util.utils.getImplName(oObj); log.println("Implementation Name: "+Iname);