more typing work

This commit is contained in:
Kovid Goyal
2020-03-12 08:10:51 +05:30
parent 21707171bb
commit 149ae2866a
22 changed files with 395 additions and 291 deletions

View File

@@ -20,7 +20,7 @@ your machine).
.. code-block:: python
def main(args):
def main(args: List[str]) -> str:
# this is the main entry point of the kitten, it will be executed in
# the overlay window when the kitten is launched
answer = input('Enter some text: ')
@@ -28,7 +28,7 @@ your machine).
# handle_result() function
return answer
def handle_result(args, answer, target_window_id, boss):
def handle_result(args: List[str], answer: str, target_window_id: int, boss: kitty.boss.Boss) -> None:
# get the kitty window into which to paste answer
w = boss.window_id_map.get(target_window_id)
if w is not None: