convert to markdown (#1)

Reviewed-on: #1
This commit is contained in:
Miguel Jacq 2025-11-08 00:30:46 -06:00
parent 31604a0cd2
commit 39576ac7f3
54 changed files with 1616 additions and 4012 deletions

21
tests/test_theme.py Normal file
View file

@ -0,0 +1,21 @@
import pytest
from PySide6.QtGui import QPalette
from bouquin.theme import Theme, ThemeConfig, ThemeManager
def test_theme_manager_apply_light_and_dark(app):
cfg = ThemeConfig(theme=Theme.LIGHT)
mgr = ThemeManager(app, cfg)
mgr.apply(Theme.LIGHT)
assert isinstance(app.palette(), QPalette)
mgr.set(Theme.DARK)
assert isinstance(app.palette(), QPalette)
@pytest.mark.gui
def test_theme_manager_system_roundtrip(app, qtbot):
cfg = ThemeConfig(theme=Theme.SYSTEM)
mgr = ThemeManager(app, cfg)
mgr.apply(cfg.theme)