Skip to content

Ostinato: icons come from iconkit - #67

Merged
bdbarnett merged 16 commits into
mainfrom
ostinato-iconkit
Nov 12, 2026
Merged

bdbarnett merged 16 commits into
mainfrom
ostinato-iconkit

Conversation

@bdbarnett

Copy link
Copy Markdown
Contributor

Ostinato's buttons now show iconkit icons: crisp alpha-mask images, tinted to match the button's text colour in its normal, hovered and checked states. The four icon font files and their build script are gone, so there is less to download and nothing to load before the buttons draw.

Icons that iconkit's shared sets lack live in app/ui/_icons_<size>.py, rebuilt with scripts/make_icons.py. Material's PNGs come in 18, 24, 36 and 48 px, so Ostinato's sizes are those, where they were 20, 24, 32 and 48; the choice of size by window scale works as before. A missing icon or size raises an error that names it.

I served the page and ran it in Chromium at 1920x1080: transport, song view, pattern editor and inspector look the same as before, including the armed-record red and the orange Ostinato menu arrow. Ostinato's tests pass. The Windows desktop app loads iconkit the same way but I haven't run it.

@bdbarnett

Copy link
Copy Markdown
Contributor Author

Ran the desktop app on Windows (CPython 3.14.6, four engines as processes) from this branch: the window opens and every icon draws in the transport, the pattern editor and the instrument panel, in its normal and checked colours. The only tracebacks in the log are BrokenPipeError from the engine and mixer processes when the window was force-closed after the screenshot.

appkit's Home and apps still import iconkit the same way, but the package now
lives in PyDevices/pydevices at packages/iconkit (omnipython-iconkit), beside
pdwidgets and palettes, so that apps/lib stays the one omnipython-applibs
package and pdwidgets and appkit can both depend on one small package.

Removed here: lib/iconkit, its generator and contact-sheet tools, its tests and
its icons page; appkit's manifest no longer includes it. The appkit tests find
iconkit at packages/iconkit/lib in the pydevices checkout PYDEVICES_LIB belongs
to (or ICONKIT_LIB). The index check raises with the fix when iconkit isn't
importable. The README, appkit README, how-it-works and app.json icon docs link
to the package's README and icons page.

Ran: the appkit index and script tests on CPython against the new location,
including a new one for the missing-iconkit message; Home and appkit import on
unix MicroPython with iconkit taken from packages/iconkit/lib.
…tton's colours

The icon fonts and their loader are gone. Icons iconkit's shared 24 and 48 px
sets lack are in app/ui/_icons_<size>.py, made by scripts/make_icons.py at
18, 24, 36 and 48 px (the sizes Material's PNGs come in). The page and the
desktop app load iconkit from the shared lib/. Tests cover every icon at every
size and what the page loads; the page ran in Chromium with the icons in
normal, checked and hovered states.
The page server, the boot list, the desktop app, the Windows staging script
and the tests look for packages/iconkit/lib in the pydevices checkout (beside
this repo, at PYDEVICES_LIB's checkout, or ICONKIT_LIB) and stop with how to
fix it when it isn't there. Ran the tests, the page in Chromium and the
Windows desktop app with the icons drawn.
iconkit moved to the pydevices repo, and Ostinato's tests stop with a
message when they can't find it. The job now checks pydevices out and
points ICONKIT_LIB at packages/iconkit/lib. Ran the tests locally with
ICONKIT_LIB set: 11 pass.
…on check

appkit's manifest.py no longer assumes iconkit sits beside it. It freezes iconkit
from the folder iconkit= names (pydevices' packages/iconkit, or <tree>/iconkit in
an omnipython-lib tree), else from $PYDEVICES_LIBRARY, and with apps= it puts that
source on the host's import path while the index checks each app's icon. With
neither it stops and says to pass iconkit= or set PYDEVICES_LIBRARY, so a build
never freezes a Home that cannot import.

Ran: the manifest tests under MicroPython's own manifest reader in an isolated
interpreter (they fail on the previous manifest with the host ImportError and pass
now, including the two missing-iconkit messages), and a unix MicroPython build that
freezes appkit with apps= (Home, Clock, Weather) from an omnipython-lib tree.
@bdbarnett
bdbarnett deleted the branch iconkit November 12, 2026 05:11
@bdbarnett bdbarnett closed this Nov 12, 2026
@bdbarnett bdbarnett reopened this Nov 12, 2026
@bdbarnett
bdbarnett changed the base branch from iconkit to main November 12, 2026 05:12
@bdbarnett
bdbarnett merged commit 7639e1a into main Nov 12, 2026
6 checks passed
@bdbarnett
bdbarnett deleted the ostinato-iconkit branch November 12, 2026 05:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant