From 6b206eb366954596fb4030409ea9300239fcc705 Mon Sep 17 00:00:00 2001 From: Yixing Lao Date: Fri, 10 Jan 2025 20:46:28 +0800 Subject: [PATCH] refactor(camtools/render.py): update `font_type` parameter type to use `Literal` for better type safety and clarity --- camtools/render.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/camtools/render.py b/camtools/render.py index dee3d83..6218bdc 100644 --- a/camtools/render.py +++ b/camtools/render.py @@ -543,7 +543,7 @@ def render( def render_text( text: str, font_size: int = 72, - font_type: str = "tex", + font_type: Literal["tex", "serif", "sans", "mono"] = "tex", font_color: Tuple[float, float, float] = (0, 0, 0), tight_layout: bool = False, multiline_alignment: str = "left",