Show HN: Tkintergalactic - Declarative Tcl/Tk UI Library for Python
Published on: 2025-07-25 19:02:20
Tkintergalactic
Declarative Tcl/Tk UI library for Python.
Somewhat React-like (there is effectively a Tk VDOM).
Well typed.
Maps very closely to the underlying Tcl/Tk for ease of debugging.
Zero dependency.
On mac sometimes you have to start by wiggling the window.
Small enough to understand how it works.
In an incomplete state - much functionality missing.
Hello World
After pip install tkintergalactic , just run:
import tkintergalactic as tk counter = 0 @ tk . command () def inc_counter () -> None : global counter counter += 1 tk . Window ( app = lambda : tk . Frame ( tk . Button ( text = "Hello World!" , onbuttonrelease = inc_counter ), tk . Text ( content = f"Button clicked { counter } times" ), ), ). run ()
TODO list
from dataclasses import dataclass , field import tkintergalactic as tk @ dataclass class Task : description : str complete : bool = False @ dataclass class State : tasks : list [ Task ] = field ( default_factory = list ) new_task_description : str = "" sta
... Read full article.