Module my_autopylot.keyboard39
Functions
def key_hit_enter(write_to_window='')
-
Description
This function is used to press the enter key on a desired window.
Args
write_to_window
:str
, optional- (Only in Windows)Name of Window you want to activate.
Eg
- Notepad. Defaults to "".
Returns
[status] status (bool): True if successful, False if not.
def key_press(key_1='', key_2='', key_3='', write_to_window='')
-
Description
Presses the given key / Emulates the given keystrokes on desired window.
Args
key_1
:str
, optional- Enter the 1st key
Eg
- ctrl or shift. Defaults to ''.
key_2
:str
, optional- Enter the 2nd key in combination.
Eg
- alt or A. Defaults to ''.
key_3
:str
, optional- Enter the 3rd key in combination.
Eg
- del or tab. Defaults to ''.
write_to_window
:str
, optional- (Only in Windows) Name of Window you want to activate. Defaults to "".
Returns
[status] status (bool): Whether the function is successful or failed.
def key_write_enter(text_to_write='', write_to_window='', key='e')
-
Description
This function is used to write given text to a window and then press the enter/tab key.
Args
text_to_write
:str
, optional- Text you wanted to type
Eg
- ClointFusion is awesone. Defaults to "".
write_to_window
:str
, optional- (Only in Windows) Name of Window you want to activate
Eg
- Notepad. Defaults to "".
key
:str
, optional- Press Enter key after typing.
Eg
- t for tab. Defaults to e
Returns
[status] status (bool): True if successful, False if not.