How do I type in pyautgui on macOS?

Asked 1 years ago, Updated 1 years ago, 437 views

How to enter and was successful.
Even if I let him type on the keyboard that I always type, another character was typed and it didn't work, so I looked it up many times on the Internet, but I couldn't find out.
Please let me know if you understand.

python macos pyautogui

2022-12-18 06:05

1 Answers

If you press the key marked '[', '@' will be entered.On the other hand, if you press the key marked ']', '[' will be entered.

Judging from this phenomenon, it seems that macOS recognizes that the English (ANSI array) keyboard ('[' on the right side of 'P' is used, but the Japanese (JIS array) keyboard ('@' on the right side of 'P') is used.

You can use the Keyboard Settings Assistant (app) to change the keyboard settings in macOS, but there are three ways to launch it:

(1) Apple Mark - > System Settings - > Keyboard - > Change Keyboard Type
(2) Start the terminal and do the following

open/System/Library/CoreServices/KeyboardSetupAssistant.app

(3) Launch Finder, follow the path above, and open KeyboardSetupAssistant.app

When the "Keyboard Settings Assistant" is started, follow the instructions and the keyboard type will be selected appropriately at the end, so it will be "completed."
(Additional)
The "Keyboard Configuration Assistant" can be used at least in macOS 10.13 (High Sierra) or later.


2022-12-18 06:57

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.