https://github.com/aloytag/mpl-modernqt
Modern Qt Matplotlib backend
https://github.com/aloytag/mpl-modernqt
backend matplotlib matplotlib-backend plotting python qtawesome
Last synced: about 2 months ago
JSON representation
Modern Qt Matplotlib backend
- Host: GitHub
- URL: https://github.com/aloytag/mpl-modernqt
- Owner: aloytag
- License: mit
- Created: 2024-01-23T16:54:29.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2026-02-12T21:27:21.000Z (4 months ago)
- Last Synced: 2026-03-16T04:54:23.922Z (3 months ago)
- Topics: backend, matplotlib, matplotlib-backend, plotting, python, qtawesome
- Language: Python
- Homepage:
- Size: 258 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# mpl-modernqt
A modern looking backend for Matplotlib based on the official Qt backend. Its main features are:
* `Phosphor Icons` (monochromatic) thanks to the [QtAwesome](https://github.com/spyder-ide/qtawesome) package.
* Modern theme with the [PyQtDarkTheme](https://github.com/5yutan5/PyQtDarkTheme) package.
* `Qt5` and `Qt6` support.
## Screenshots

Matplotlib figure (main window).

Figure settings.

Figure options.
## Installation
Using ```pip```, the official Python package manager...
On GNU/Linux and MacOS execute the following order in a terminal:
```bash
pip install mpl-modernqt -U
```
On MS Windows you may prefer:
```bash
python -m pip install mpl-modernqt -U
```
## Usage
```python
from matplotlib import use
use('module://mpl_modernqt.backend')
```
## Example code
```python
import numpy as np
from matplotlib import use
import matplotlib.pyplot as plt
use('module://mpl_modernqt.backend')
x = np.linspace(0, 7, 300)
y = np.sin(x)
plt.plot(x, y)
plt.show()
```
## License
This project uses the [MIT license](https://github.com/aloytag/mpl-modernqt/blob/main/LICENSE).