Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

pane

Python bindings for Pane — a modern, minimalist Windows UI engine built on WPF. Build real native Windows app UIs from Python: buttons, checkboxes, sliders, text input, tabs, live light/dark theming and accent-color switching, all with a single custom-chrome window.

The engine itself is C#/WPF; this package drives it in-process via pythonnet, so widgets are the real native controls, not a re-implementation.

Windows only (WPF has no cross-platform equivalent). Requires the free .NET 8 Desktop Runtime — not the SDK, just the runtime.

Install

pip install pane-ui

Quick start

import pane

def build(window):
    window.Content = pane.stack(
        pane.text("Hello from Python", size="title", bold=True),
        pane.button("Click me", style="primary", on_click=lambda: print("clicked!")),
        pane.checkbox("Enable notifications", checked=True),
        spacing=12,
        margin=24,
    )

pane.run(build, title="My App")

Run the full widget gallery from the source repo for a tour of everything available: python examples/gallery.py.

Documentation

Full API reference - every widget, layout helper, the chat panel, the music player, theming, events, and the threading model:

  • Getting started - pane.run() and the builder pattern
  • The window - the real WPF Window object, fullscreen/state
  • Widgets - buttons, inputs, lists, menus, and every other control
  • Layout - stack, grid, card, sidebar, scroll
  • Chat - chat_panel(), the message-bubble widget
  • Music player - music_player(), the transport/seek/volume widget
  • Theming - light/dark mode, accent colors
  • Events - the on_* callback convention
  • Threading - pane.invoke() and background work
  • Value conversion - to_thickness(), to_color()

License

MIT