//=====================================================================
        /// <summary>
        /// constructor
        /// </summary>
        public SpellCheckerConfiguration()
        {
            csharpOptions = new CSharpOptions();
            cadOptions = new CodeAnalysisDictionaryOptions();

            this.DefaultLanguage = new CultureInfo("en-US");

            this.SpellCheckAsYouType = this.IgnoreWordsWithDigits = this.IgnoreWordsInAllUppercase =
                this.IgnoreFormatSpecifiers = this.IgnoreFilenamesAndEMailAddresses =
                this.IgnoreXmlElementsInText = this.DetermineResourceFileLanguageFromName =
                this.InheritExcludedExtensions = this.InheritAdditionalDictionaryFolders =
                this.InheritIgnoredWords = this.InheritXmlSettings = true;

            this.TreatUnderscoreAsSeparator = false;

            ignoredWords = new HashSet<string>(DefaultIgnoredWords, StringComparer.OrdinalIgnoreCase);
            ignoredXmlElements = new HashSet<string>(DefaultIgnoredXmlElements);
            spellCheckedXmlAttributes = new HashSet<string>(DefaultSpellCheckedAttributes);
            excludedExtensions = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
            recognizedWords = new HashSet<string>(StringComparer.OrdinalIgnoreCase);

            additionalDictionaryFolders = new List<string>();

            deprecatedTerms = new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase);
            compoundTerms = new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase);
            unrecognizedWords = new Dictionary<string, IList<string>>(StringComparer.OrdinalIgnoreCase);
        }
Esempio n. 2
0
        //=====================================================================

        /// <summary>
        /// Constructor
        /// </summary>
        public SpellCheckerConfiguration()
        {
            csharpOptions = new CSharpOptions();
            cadOptions    = new CodeAnalysisDictionaryOptions();

            dictionaryLanguages = new List <CultureInfo>();

            this.SpellCheckAsYouType                        = this.IncludeInProjectSpellCheck = this.DetectDoubledWords =
                this.IgnoreWordsWithDigits                  = this.IgnoreWordsInAllUppercase = this.IgnoreWordsInMixedCase =
                    this.IgnoreFormatSpecifiers             = this.IgnoreFilenamesAndEMailAddresses =
                        this.IgnoreXmlElementsInText        = this.DetermineResourceFileLanguageFromName =
                            this.InheritIgnoredFilePatterns = this.InheritAdditionalDictionaryFolders =
                                this.InheritIgnoredWords    = this.InheritExclusionExpressions = this.InheritXmlSettings =
                                    this.IgnoreMnemonics    = this.EnableWpfTextBoxSpellChecking = true;

            ignoredWords              = new HashSet <string>(DefaultIgnoredWords, StringComparer.OrdinalIgnoreCase);
            ignoredXmlElements        = new HashSet <string>(DefaultIgnoredXmlElements);
            spellCheckedXmlAttributes = new HashSet <string>(DefaultSpellCheckedAttributes);
            recognizedWords           = new HashSet <string>(StringComparer.OrdinalIgnoreCase);

            additionalDictionaryFolders = new List <string>();

            exclusionExpressions   = new List <Regex>();
            ignoredFilePatterns    = new List <Regex>(DefaultIgnoredFilePatterns.Select(p => p.RegexFromFilePattern()));
            visualStudioExclusions = new List <Regex>(DefaultVisualStudioExclusions.Select(p => new Regex(p)));

            deprecatedTerms   = new Dictionary <string, string>(StringComparer.OrdinalIgnoreCase);
            compoundTerms     = new Dictionary <string, string>(StringComparer.OrdinalIgnoreCase);
            unrecognizedWords = new Dictionary <string, IList <string> >(StringComparer.OrdinalIgnoreCase);
        }
Esempio n. 3
0
        //=====================================================================

        /// <summary>
        /// constructor
        /// </summary>
        public SpellCheckerConfiguration()
        {
            csharpOptions = new CSharpOptions();
            cadOptions    = new CodeAnalysisDictionaryOptions();

            dictionaryLanguages = new List <CultureInfo>();

            this.SpellCheckAsYouType                   = this.IgnoreWordsWithDigits = this.IgnoreWordsInAllUppercase =
                this.IgnoreFormatSpecifiers            = this.IgnoreFilenamesAndEMailAddresses =
                    this.IgnoreXmlElementsInText       = this.DetermineResourceFileLanguageFromName =
                        this.InheritExcludedExtensions = this.InheritAdditionalDictionaryFolders =
                            this.InheritIgnoredWords   = this.InheritXmlSettings = true;

            this.TreatUnderscoreAsSeparator = false;

            ignoredWords              = new HashSet <string>(DefaultIgnoredWords, StringComparer.OrdinalIgnoreCase);
            ignoredXmlElements        = new HashSet <string>(DefaultIgnoredXmlElements);
            spellCheckedXmlAttributes = new HashSet <string>(DefaultSpellCheckedAttributes);
            excludedExtensions        = new HashSet <string>(StringComparer.OrdinalIgnoreCase);
            recognizedWords           = new HashSet <string>(StringComparer.OrdinalIgnoreCase);

            additionalDictionaryFolders = new List <string>();

            deprecatedTerms   = new Dictionary <string, string>(StringComparer.OrdinalIgnoreCase);
            compoundTerms     = new Dictionary <string, string>(StringComparer.OrdinalIgnoreCase);
            unrecognizedWords = new Dictionary <string, IList <string> >(StringComparer.OrdinalIgnoreCase);
        }