This was much harder than thought, but thanks to the NVDA source giving
a good example, this is working well now on Windows. Sadly it isn't so
much on macOS Catalina with VoiceOver, but it is workable.
This replaces the FilePickerCtrl with a FileDialog so that the button
can be made custom, and uses the NVDA technique of grouping related
controls in a horizontal BoxSizer to associate the label with the chosen
map file's textbox. Layout is improved and add_widget() is simplified
as a result, too.
This also uses another NVDA technique to put the textbox (actually an
ExpandoTextCtrl) in the focus order.
Associate labels with controls
This was much harder than thought, but thanks to the NVDA source giving a good example, this is working well now on Windows. Sadly it isn't so much on macOS Catalina with VoiceOver, but it is workable.
This replaces the FilePickerCtrl with a FileDialog so that the button can be made custom, and uses the NVDA technique of grouping related controls in a horizontal BoxSizer to associate the label with the chosen map file's textbox. Layout is improved and add_widget() is simplified as a result, too.
This also uses another NVDA technique to put the textbox (actually an ExpandoTextCtrl) in the focus order.
Thanks to https://github.com/nvaccess/nvda/blob/55a9b32e4d3889c04a1ea4ad5834a59d8851e009/source/gui/guiHelper.py#L111 :-)
General labelling improvements
Use StaticBoxSizers on Windows to improve organisation and naming. This groups related controls like a