I created a project in python-3 using wxpython. I would like to know if there is a function that prevents marking of text (in grey/blue square) for deletion. For example I want to prevent marking: "bla bla this text is marked bla bla". I don't want to enable the user to mark his text and then press delete or another key that will cause the marked text to be deleted. Another option if someone knows, is how to identify if there is text that is currently marked or maybe the length of the marked text, and I'll do the other things.
Here is a basic code of creating a wx.stc.StyledTextCtrl:
import wx
from wx.stc import StyledTextCtrl
app = wx.App()
frame = wx.Frame(None, -1, title='2', pos=(0, 0), size=(500, 500))
frame.Show(True)
messageTxt = StyledTextCtrl(frame, id=wx.ID_ANY, pos=(0, 0), size=(100 * 3, 100),
style=wx.TE_MULTILINE, name="File")
app.SetTopWindow(frame)
app.MainLoop()