Focus in wx.TextCtrl


Javi Domínguez
 

Hello.

In a SettingsPanel, I have put an edit box like this:

helper.addItem(wx.TextCtrl(self, style=wx.TE_READONLY, value = ""))
But it doesn't get focus when I press the tab key. Am I doing something wrong or am I missing something?

I'm in NVDA 2021.1 beta 2

Greetings

Javi Dominguez


Adriano Barbieri
 

To solve I added |wx.TE_MULTILINE, but the editing field rises a little

Il 11/06/2021 13:17, Javi Domínguez ha scritto:

Hello.

In a SettingsPanel, I have put an edit box like this:

helper.addItem(wx.TextCtrl(self, style=wx.TE_READONLY, value = ""))

But it doesn't get focus when I press the tab key. Am I doing something wrong or am I missing something?

I'm in NVDA 2021.1 beta 2

Greetings

Javi Dominguez








James Scholes
 

I seem to recall filing this as a wxWidgets bug some time ago, i.e. the fact that single-line, read-only text controls don't facilitate in the tab order. I can't find the bug report right now, although it seems that they haven't fixed it anyway.

As another list member suggested, I think your best option is to just make it a multi-line field instead. Either that, or handle Tab/Shift+Tab instead which is messy.

Regards,

James Scholes

On 11/06/2021 at 6:17 am, Javi Domínguez wrote:
Hello.

In a SettingsPanel, I have put an edit box like this:

helper.addItem(wx.TextCtrl(self, style=wx.TE_READONLY, value = ""))
But it doesn't get focus when I press the tab key. Am I doing something
wrong or am I missing something?

I'm in NVDA 2021.1 beta 2

Greetings

Javi Dominguez