mirror of
https://github.com/weechat/weechat.git
synced 2026-07-08 10:43:13 +02:00
doc: add type annotations in Python prototype (scripting guide) (issue #1377)
This commit is contained in:
@@ -222,11 +222,11 @@ Funktionen werden aufgerufen mittels `+weechat_xxx(arg1, arg2, ...);+`.
|
||||
Ein WeeChat-Skript muss sich bei WeeChat "registrieren". Dazu muss das Skript
|
||||
zuerst die "register" Funktion ausführen.
|
||||
|
||||
Prototyp:
|
||||
Prototyp (Python):
|
||||
|
||||
[source,python]
|
||||
----
|
||||
weechat.register(Name, Author, Version, Lizenz, Beschreibung, Shutdown_Funktion, Zeichensatz)
|
||||
def register(name: str, author: str, version: str, license: str, description: str, shutdown_function: str, charset: str) -> int: ...
|
||||
----
|
||||
|
||||
Argumente:
|
||||
|
||||
@@ -212,11 +212,11 @@ Functions are called with `+weechat_xxx(arg1, arg2, ...);+`.
|
||||
All WeeChat scripts must "register" themselves to WeeChat, and this must be
|
||||
first WeeChat function called in script.
|
||||
|
||||
Prototype:
|
||||
Prototype (Python):
|
||||
|
||||
[source,python]
|
||||
----
|
||||
weechat.register(name, author, version, license, description, shutdown_function, charset)
|
||||
def register(name: str, author: str, version: str, license: str, description: str, shutdown_function: str, charset: str) -> int: ...
|
||||
----
|
||||
|
||||
Arguments:
|
||||
|
||||
@@ -222,11 +222,11 @@ Les fonctions sont appelées par `+weechat_xxx(arg1, arg2, ...);+`.
|
||||
Tous les scripts WeeChat doivent s'enregistrer ("register") auprès de WeeChat,
|
||||
et cela doit être la première fonction WeeChat appelée dans le script.
|
||||
|
||||
Prototype :
|
||||
Prototype (Python) :
|
||||
|
||||
[source,python]
|
||||
----
|
||||
weechat.register(name, author, version, license, description, shutdown_function, charset)
|
||||
def register(name: str, author: str, version: str, license: str, description: str, shutdown_function: str, charset: str) -> int: ...
|
||||
----
|
||||
|
||||
Paramètres :
|
||||
|
||||
@@ -233,11 +233,11 @@ Functions are called with `+weechat_xxx(arg1, arg2, ...);+`.
|
||||
Tutti gli script WeeChat devono "registrare" loro stessi in WeeChat, e questo
|
||||
deve essere la prima funzione chiamata nello script di WeeChat.
|
||||
|
||||
Prototipo:
|
||||
Prototipo (Python):
|
||||
|
||||
[source,python]
|
||||
----
|
||||
weechat.register(name, author, version, license, description, shutdown_function, charset)
|
||||
def register(name: str, author: str, version: str, license: str, description: str, shutdown_function: str, charset: str) -> int: ...
|
||||
----
|
||||
|
||||
Argomenti:
|
||||
|
||||
@@ -230,11 +230,11 @@ Functions are called with `+weechat_xxx(arg1, arg2, ...);+`.
|
||||
全ての WeeChat スクリプトは WeeChat
|
||||
に自分自身を「登録」し、登録はスクリプトの最初で行われなければいけません。
|
||||
|
||||
プロトタイプ:
|
||||
プロトタイプ (Python):
|
||||
|
||||
[source,python]
|
||||
----
|
||||
weechat.register(name, author, version, license, description, shutdown_function, charset)
|
||||
def register(name: str, author: str, version: str, license: str, description: str, shutdown_function: str, charset: str) -> int: ...
|
||||
----
|
||||
|
||||
引数:
|
||||
|
||||
@@ -217,11 +217,11 @@ Funkcje są wywoływane za pomocą `+weechat_xxx(arg1, arg2, ...);+`.
|
||||
Wszystkie skrypty WeeChat muszą się "zarejestrować" w WeeChat, musi to być pierwsza
|
||||
z funkcji WeeChat wywołana w skrypcie.
|
||||
|
||||
Prototyp:
|
||||
Prototyp (Python):
|
||||
|
||||
[source,python]
|
||||
----
|
||||
weechat.register(nazwa, autor, wersja, licencja, opis, funkcja_wyłączająca, kodowanie)
|
||||
def register(nazwa: str, autor: str, wersja: str, licencja: str, opis: str, funkcja_wyłączająca: str, kodowanie: str) -> int: ...
|
||||
----
|
||||
|
||||
Argumenty:
|
||||
|
||||
Reference in New Issue
Block a user