Metadata-Version: 2.4
Name: winmica
Version: 1.0.3
Summary: Windows 11 Mica backdrop effects using official Windows API
Home-page: https://github.com/amnweb/winmica
Author: AmN
License: MIT
Project-URL: Bug Tracker, https://github.com/amnweb/winmica/issues
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: Microsoft :: Windows :: Windows 11
Requires-Python: >=3.12
Description-Content-Type: text/markdown
License-File: LICENSE
Dynamic: author
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: license
Dynamic: license-file
Dynamic: project-url
Dynamic: requires-python
Dynamic: summary

# winmica
A simple Python package to enable Windows 11 Mica effects for PyQt6 applications using the official Windows API.

## Installation

Install this package (from the project root):
```bash
pip install winmica
```

## Usage Example (PyQt6)

```python
from PyQt6.QtWidgets import QApplication, QMainWindow
from PyQt6.QtCore import Qt
from winmica import EnableMica, BackdropType, is_mica_supported
import sys

class MyWindow(QMainWindow):
    def __init__(self):
        super().__init__()
        self.setWindowTitle("Mica Example")
        self.setGeometry(100, 100, 600, 400)
        self.setAttribute(Qt.WidgetAttribute.WA_TranslucentBackground, True)
        if is_mica_supported():
            hwnd = int(self.winId())
            EnableMica(hwnd, BackdropType.MICA)

if __name__ == "__main__":
    app = QApplication(sys.argv)
    window = MyWindow()
    window.show()
    sys.exit(app.exec())
```

## Features
- Official Windows 11 Mica Effect
- Simple API: `EnableMica(hwnd, backdrop_type)`
- Works with PyQt6 windows (may also work with PySide6 or Tkinter, but not tested)
- Detects system theme (light/dark)

## Effect Types
- `BackdropType.MICA` – Standard Mica
- `BackdropType.MICA_ALT` – Alternative Mica
- `BackdropType.AUTO` – Auto (let Windows decide)

## Result:
<img width="954" height="720" alt="mica" src="https://github.com/user-attachments/assets/81131740-1240-43d6-a006-6cf379cfa09c" />
<img width="954" height="720" alt="micaalt" src="https://github.com/user-attachments/assets/df3ee785-9610-41a7-845d-57cb1b469443" />
