RichTextCtrl macOS cursor positioning following tabs

Python 3.7, wxPython 4.1

I use the RichTextCtrl as the basis for a word processing window in my application. It’s common for my users to have left indent on a paragraph with the first line hanging out to the left for a speaker identifier followed by a Tab. (They are transcribing audio.) This has worked great for a decade using older wxPython versions, but now I’m updating everything trying to get my program working on Catalina. (Yeah, I’m late to the game here, I know.)

I find that this formatting causes mouse-click-positioning problems on macOS with Python 3.7.7 and wxPython 4.1. Specifically, when I try to click on the line anywhere after the tab character, the cursor gets placed incorrectly in the line with the tab. Cursor positioning works as expected in lines without tabs.

I do not see the problem on Windows with Python 3.7.7 and wxPython 4.1.x (a recent daily build, but not the latest).
I do not see the problem on macOS Mojave with Python 2.7.12 and wxPython
I see the problem with macOS Mojave and Catalina with Python 3.7.7 and either wxPython 4.1.0 or 4.1.1a1…, the most recent daily build.

I’ve attached a simple app that demonstrates the problem on macOS.

Any suggestions would be most appreciated.

David (2.8 KB)

I can confirm the problem, and fiddled with it a bit to see if anything shook out. Unfortunately I didn’t come up with anything. You may need to check with the wxWidgets folks about it.