Add support for using native spell checking in wxTextCtrl
Add wxTextCtrl::EnableSpellCheck() and implement it for wxMSW and wxGTK3. Closes #17544.
This commit is contained in:
@@ -448,6 +448,18 @@
|
||||
// Recommended setting: 1 (but may be safely disabled if you don't use it)
|
||||
#define wxUSE_SECRETSTORE 1
|
||||
|
||||
// Allow the use of the OS built-in spellchecker on wxTextCtrl (multiline
|
||||
// only). Currently only wxGTK3 and wxMSW are implemented.
|
||||
//
|
||||
// Default is 1 on wxGTK3 and wxMSW platforms and 0 otherwise.
|
||||
//
|
||||
// Recommended setting: 1 on supported platforms.
|
||||
#if (defined(__WXGTK3__) || defined(__WXMSW__))
|
||||
#define wxUSE_SPELLCHECK 1
|
||||
#else
|
||||
#define wxUSE_SPELLCHECK 0
|
||||
#endif
|
||||
|
||||
// Use wxStandardPaths class which allows to retrieve some standard locations
|
||||
// in the file system
|
||||
//
|
||||
|
@@ -96,6 +96,14 @@ public:
|
||||
// Overridden wxWindow methods
|
||||
virtual void SetWindowStyleFlag( long style ) wxOVERRIDE;
|
||||
|
||||
#if wxUSE_SPELLCHECK
|
||||
// Use native spelling and grammar checking functions.
|
||||
virtual bool EnableProofCheck(bool WXUNUSED(enable) = true,
|
||||
const wxTextProofOptions& WXUNUSED(options) =
|
||||
wxTextProofOptions()) wxOVERRIDE;
|
||||
virtual bool IsProofCheckEnabled() const wxOVERRIDE;
|
||||
#endif // wxUSE_SPELLCHECK
|
||||
|
||||
// Implementation from now on
|
||||
void OnDropFiles( wxDropFilesEvent &event );
|
||||
void OnChar( wxKeyEvent &event );
|
||||
|
Reference in New Issue
Block a user