From 2af0b12d269cee41d601e28be7fa09cecb1458a0 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Thu, 20 Jan 2022 00:13:16 +0100 Subject: [PATCH] Avoid assert on text sample startup under MSW Use wxTE_RICH2 for a control that we call EnableProofCheck() on, as using this function without this style asserts in wxMSW. This should have been done in 5ba2461fd1 (Switch to using GSpell for wxTextCtrl proof checker in wxGTK, 2021-09-08). --- samples/text/text.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/text/text.cpp b/samples/text/text.cpp index e38f416496..4d40c8dcfb 100644 --- a/samples/text/text.cpp +++ b/samples/text/text.cpp @@ -1116,7 +1116,7 @@ MyPanel::MyPanel( wxFrame *frame, int x, int y, int w, int h ) m_text = new MyTextCtrl( this, wxID_ANY, "Single line.", wxDefaultPosition, wxDefaultSize, - wxTE_PROCESS_ENTER); + wxTE_PROCESS_ENTER | wxTE_RICH2); m_text->SetForegroundColour(*wxBLUE); m_text->SetBackgroundColour(*wxLIGHT_GREY); (*m_text) << " Appended.";