From 85cc5ba98519a6c6cc2e66fe913114f3d5376f20 Mon Sep 17 00:00:00 2001 From: Carlos Cordoba Date: Sun, 7 Jul 2024 17:34:25 -0500 Subject: [PATCH] Switcher: Make all text in items have the interface font size Also, show the item's description in italics to distinguish it from its title. --- spyder/plugins/switcher/widgets/item.py | 35 +++++++------------------ 1 file changed, 10 insertions(+), 25 deletions(-) diff --git a/spyder/plugins/switcher/widgets/item.py b/spyder/plugins/switcher/widgets/item.py index 0d9004c0d14..6de2acb1d70 100644 --- a/spyder/plugins/switcher/widgets/item.py +++ b/spyder/plugins/switcher/widgets/item.py @@ -184,18 +184,21 @@ class SwitcherItem(SwitcherBaseItem): {title} -   - - {description} - + +    + + + {description} + + - {shortcut} + {shortcut}   - {section} + {section} @@ -274,24 +277,6 @@ def _set_styles(self): if attr not in self._styles: self._styles[attr] = self._STYLES[attr] - rich_font = self._styles['title_font_size'] - - if sys.platform == 'darwin': - title_font_size = rich_font - description_font_size = title_font_size + 2 - elif os.name == 'nt': - title_font_size = rich_font - description_font_size = title_font_size + 1 - elif is_ubuntu(): - title_font_size = rich_font - 2 - description_font_size = title_font_size + 1 - else: - title_font_size = rich_font - 2 - description_font_size = title_font_size + 1 - - self._styles['description_font_size'] = description_font_size - self._styles['section_font_size'] = description_font_size - def _get_height(self): """ Return the expected height of this item's text, including