Some text navigation/editing keyboard shortcuts in macOS insert invisible ASCII characters in text fields
Description
On macOS, you can use shortcuts like Ctrl-b
and Ctrl-f
to move backward or forward by one character, or shortcuts like Ctrl-d
to delete the character in front of your cursor. For some text fields in KiCad, this works fine. But for others, these shortcuts insert some ASCII characters into the text field.
For example, when editing a component's Reference field, these shortcuts work fine. But if I attempt to edit the components Value field, then Ctrl-b
inserts ASCII character 2 (STX), Ctrl-f
inserts ASCII character 6 (ACK), and Ctrl-d
inserts ASCII character 4 (EOT). KiCad does display in the text field that this normally invisible characters are present, see the screenshots below.
Steps to reproduce
- In a new schematic, add a component like a resistor
- Double click on the resistor Reference field and confirm that Ctrl-b, Ctrl-f, and Ctrl-d work as expected (interestingly, Cmd-Z doesn't work for this field but does work for the Value field, which is unrelated but bizarre...)
- Close that dialog and double click on the resistor Value field. Try to use Ctrl-b, Ctrl-f, and Ctrl-d, and note that some unwanted characters get inserted like in the screenshots above.
KiCad Version
Application: KiCad Schematic Editor x86_64 on x86_64
Version: 7.0.5-0, release build
Libraries:
wxWidgets 3.2.2
FreeType 2.12.1
HarfBuzz 5.3.1
FontConfig 2.14.0
Platform: macOS Ventura Version 13.4 (Build 22F66), 64 bit, Little endian, wxMac
wxWidgets: 3.2.2 (wchar_t,wx containers)
Boost: 1.80.0
OCC: 7.6.3
Curl: 7.77.0
ngspice: 38
Compiler: Clang 13.0.0 with C++ ABI 1002
Build settings:
KICAD_SPICE=ON