Ticket Q317371
Visible to All Users

spelling options are ignored

created 14 years ago

I try to set the spelling options, but no matter what, it follows the default behaviour described in
http://documentation.devexpress.com/#WindowsForms/clsDevExpressXtraSpellCheckerOptionsSpellingtopic
Whether I set the following values to True or False, doesn't change the behaviour (of check-as-you-type - that is the only spelling functionality that's relevant for us)
Code snippet:
            DevExpress.XtraSpellChecker.OptionsSpelling spellOptions = new DevExpress.XtraSpellChecker.OptionsSpelling();
            spellOptions.IgnoreEmails = DevExpress.Utils.DefaultBoolean.True;
            spellOptions.IgnoreMixedCaseWords = DevExpress.Utils.DefaultBoolean.True;
            spellOptions.IgnoreRepeatedWords = DevExpress.Utils.DefaultBoolean.True;
            spellOptions.IgnoreUpperCaseWords = DevExpress.Utils.DefaultBoolean.True;
            spellOptions.IgnoreUrls = DevExpress.Utils.DefaultBoolean.True;
            spellOptions.IgnoreWordsWithNumbers = DevExpress.Utils.DefaultBoolean.True;
            this.spellChecker1.SetSpellCheckerOptions(this, spellOptions);
            this.richEditControl1.SpellChecker = this.spellChecker1;
BR,
Johan Andersen

Show previous comments (2)
Alessandro (DevExpress Support) 14 years ago

    Hello Johan,
    By default, the options specified via the SpellChecker.OptionsSpelling property are used when checking a control. However, you can override these options for a particular control by calling the SpellChecker.SetSpellCheckerOptions() method with this control passed to this method as a parameter. Attached is a small sample, illustrating my statements in action. Does this help you?
    Thanks,
    Alessandro.

      Hello Allesandro,
      My point is that if it has no effect to do this:
                  this.spellChecker1.OptionsSpelling.IgnoreEmails = DevExpress.Utils.DefaultBoolean.False;
                  this.spellChecker1.OptionsSpelling.IgnoreMixedCaseWords = DevExpress.Utils.DefaultBoolean.False;
      Then maybe you shouldn't allow programmars to do so. That way you can force programmars to use setSpellingOptions() in stead.
      For me it's not a problem. It was just a suggestion to make it easier for your other customers that are going to use this in the future.
      BR,
      Johan

      Alessandro (DevExpress Support) 14 years ago

        Hello Johan,
        Thank you for the update. Basically, the default SpellChecker.OptionsSpelling settings affect a particular control if they are adjusted before calling the SpellChecker.Check() method for this control. After this method is called, the XtraSpellChecker constructs an the internal set of settings for the given control (this set is based on the SpellChecker.OptionsSpelling settings). This set can be modified further only via the explicite SpellChecker.SetSpellCheckerOptions() method call. Please let me know whether you need further clarification on this question. I will be glad to help you.
        Thanks,
        Alessandro.

        Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

        Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.