"""App stylesheet knobs that must track the font zoom ladder.""" from aare.gui import styles def test_control_height_scales_with_font_ladder(): """Buttons/inputs pinned at 16px clipped descenders at 125/150%; the pin must scale with the ladder in both sheets.""" try: styles.set_font_scale(1.0) for theme in (styles.THEME_SUNRISE, styles.THEME_SUNSET): assert "max-height: 16px" in styles.build_app_stylesheet(theme), theme styles.set_font_scale(1.5) for theme in (styles.THEME_SUNRISE, styles.THEME_SUNSET): sheet = styles.build_app_stylesheet(theme) assert "max-height: 24px" in sheet, theme assert "max-height: 16px" not in sheet, theme finally: styles.set_font_scale(1.0)