From 25a289445e600dc9ca3bccbe1313cc8824f448d7 Mon Sep 17 00:00:00 2001 From: Anon <git@anonweb.de> Date: Sat, 5 Aug 2023 12:55:53 +0200 Subject: [PATCH] py: add additional constants to ctx types --- python_payload/mypystubs/ctx.pyi | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/python_payload/mypystubs/ctx.pyi b/python_payload/mypystubs/ctx.pyi index 24dbe68bd4..079e4c6cb2 100644 --- a/python_payload/mypystubs/ctx.pyi +++ b/python_payload/mypystubs/ctx.pyi @@ -29,9 +29,19 @@ class Context(Protocol): global_alpha: float = 1.0 font: str = "" + ALPHABETIC: str = "alphabetic" + TOP: str = "top" + HANGING: str = "hanging" + MIDDLE: str = "middle" + IDEOGRAPHIC: str = "ideographic" + BOTTOM: str = "bottom" + + START: str = "start" + END: str = "end" + JUSTIFY: str = "justify" CENTER: str = "center" + LEFT: str = "left" RIGHT: str = "right" - MIDDLE: str = "middle" def __init__(self) -> None: ... def text_width(self, text: str) -> float: -- GitLab