From ebdfafd2f61f2cd8ca0bba80c86d027d1cface27 Mon Sep 17 00:00:00 2001 From: Zachary Lentz Date: Wed, 9 Oct 2024 14:23:32 -0700 Subject: [PATCH 1/2] FIX: stop here for empty comboboxes --- typhos/dynamic_font.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/typhos/dynamic_font.py b/typhos/dynamic_font.py index a084c590..580ec91e 100644 --- a/typhos/dynamic_font.py +++ b/typhos/dynamic_font.py @@ -276,6 +276,8 @@ def set_font_size() -> None: ) for text in combo_options ] + if not font_sizes: + return set_font_common( widget=widget, font_size=min(font_sizes), From f503653a42c9f7be9d8b5498662c12e4fc1f6d0b Mon Sep 17 00:00:00 2001 From: Zachary Lentz Date: Wed, 9 Oct 2024 14:41:51 -0700 Subject: [PATCH 2/2] DOC: add pre-release notes for 621 --- .../621-fix_combobox_resize_crash.rst | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 docs/source/upcoming_release_notes/621-fix_combobox_resize_crash.rst diff --git a/docs/source/upcoming_release_notes/621-fix_combobox_resize_crash.rst b/docs/source/upcoming_release_notes/621-fix_combobox_resize_crash.rst new file mode 100644 index 00000000..c3c97c8b --- /dev/null +++ b/docs/source/upcoming_release_notes/621-fix_combobox_resize_crash.rst @@ -0,0 +1,23 @@ +621 fix_combobox_resize_crash +############################# + +API Breaks +---------- +- N/A + +Features +-------- +- N/A + +Bugfixes +-------- +- Fix an issue where dynamic font scaling applied to a combobox + with no entries would raise an exception and close typhos. + +Maintenance +----------- +- N/A + +Contributors +------------ +- zllentz