diff --git a/docs/fix_readme.py b/docs/fix_readme.py index cc14682..82c1705 100644 --- a/docs/fix_readme.py +++ b/docs/fix_readme.py @@ -5,6 +5,7 @@ with open('../README.rst', 'r') as file: content = file.read() content = content.replace('images/dark.gif', 'https://github.com/UN-GCPDS/qt-material/raw/master/docs/source/images/dark.gif') content = content.replace('images/light.gif', 'https://github.com/UN-GCPDS/qt-material/raw/master/docs/source/images/light.gif') +content = content.replace('images/theme.gif', 'https://github.com/UN-GCPDS/qt-material/raw/master/docs/source/images/theme.gif') end = content.find('Indices and tables') with open('../README.rst', 'w') as file: file.write(content[:end]) diff --git a/docs/source/images/dark.gif b/docs/source/images/dark.gif index 1f77736..9a7e541 100644 Binary files a/docs/source/images/dark.gif and b/docs/source/images/dark.gif differ diff --git a/docs/source/images/light.gif b/docs/source/images/light.gif index d13be3b..213977d 100644 Binary files a/docs/source/images/light.gif and b/docs/source/images/light.gif differ diff --git a/docs/source/images/theme.gif b/docs/source/images/theme.gif new file mode 100644 index 0000000..9aa0dcb Binary files /dev/null and b/docs/source/images/theme.gif differ diff --git a/docs/source/index.rst b/docs/source/index.rst index 0061c91..a7c7a66 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -122,14 +122,31 @@ Save it as `my_theme.xml` or similar and apply the style sheet from Python. Light themes ------------ -Light themes will need to add `light_secondary` argument as `True`. +Light themes will need to add `invert_secondary` argument as `True`. .. code:: python - apply_stylesheet(app, theme='dark_teal.xml', light_secondary=True) + apply_stylesheet(app, theme='light_red.xml', invert_secondary=True) -New Themes +Run example +----------- + +A window with almost all widgets (see the previous screenshots) are available to +test all themes and **create new ones**. + +.. code:: bash + + git clone https://github.com/UN-GCPDS/qt-material.git + cd qt-material + python setup.py install + cd test + python main.py --PySide6 + +.. image:: images/theme.gif + + +New themes ---------- Do you have a custom theme? it looks good? create a