Ship another application icon in packaged builds - #169
Open
BeckettFrey wants to merge 1 commit into
Open
Conversation
This was referenced Aug 19, 2026
The app never set an icon anywhere, so the packaged build reached users showing PyInstaller's generic executable icon and the generic Python icon in the taskbar. Three pieces are needed, because they cover different surfaces: - scripts/build.py now defaults PyInstaller's --icon to assets/vk.ico on Windows. This is the icon Explorer, the Start menu and a pinned shortcut read off the .exe itself, before the app has run at all, and it was previously an opt-in flag nobody passed. An explicit --icon still wins. - assets/ is bundled via --add-data, so the runtime lookup resolves inside a frozen build rather than only under `uv run main.py`. - QApplication.setWindowIcon and QMainWindow.setWindowIcon set the running app's taskbar and window icon; Qt needs both. get_app_icon_path prefers assets/vk.ico on Windows (multi-resolution, so it stays sharp at taskbar and title-bar sizes) and falls back to the PNG elsewhere. It resolves through get_assets_root, which handles the PyInstaller _MEIPASS case the same way get_config_root already does. The splash credit line that rode along with this originally is now #170.
BeckettFrey
force-pushed
the
feature/app-branding
branch
from
August 19, 2026 18:32
bc95613 to
65bd138
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Narrowed to the icon only. The splash credit line that originally rode along with this is now #170 (merged).
Correction to the original framing
An earlier version of this description claimed the packaged-build icon was broken. That was wrong —
tasks.pyhas always passed--iconon every platform:tasks.py:189— Windows:--icon ./assets/voxkit.icotasks.py:99— macOS:--icon ./assets/voxkit.icnsinstaller/windows/VoxKit.iss:29—SetupIconFile=..\..\assets\voxkit.icoThe
.exein Explorer, the Start menu, and the installer already carried an icon. This PR does not fix that, because it was not broken.What this actually changes
1. The icon now appears while the app is running — including under
uv run main.py. Qt needs it set explicitly and nothing ever calledsetWindowIcon.main.pysets it at theQApplicationlevel,src/voxkit/gui/__init__.pyat the window level; Qt needs both.2.
assets/is bundled into frozen builds via--add-data, so (1) also holds in a packaged build.get_assets_root()handles the_MEIPASScase exactly as the existingget_config_root()does.3. New icon art —
assets/vk.icoandassets/vk.png, added alongside the existingvoxkit.ico/voxkit.icns/voxkit.pngrather than replacing them.4. A
--iconfallback inscripts/build.pyfor direct invocation without the flag. The invoke tasks always pass--icon, so this never fires on the shipping path.Open question: do we want a new icon?
This is the part worth an actual decision, and it is independent of the plumbing above. Because the PR adds a second icon set instead of replacing the first, the two are now wired to different surfaces:
.exein Explorer / Start menu / pinned shortcutvoxkit.ico(existing)tasks.py:189voxkit.ico(existing)VoxKit.iss:29voxkit.icns(existing)tasks.py:99vk.ico/vk.png(new)get_app_icon_path()As it stands, a Windows user sees the old icon on the shortcut and the new one once the window opens. That wants resolving either way:
tasks.pyandVoxKit.issatvk.*, retirevoxkit.*.vk.*and pointget_app_icon_path()atvoxkit.ico/voxkit.png.Notes for review
assets/vk.pngis 4 MB and is the non-Windows runtime icon. That is a lot of weight in every bundle for an icon; downsizing is worth doing whichever art wins._MEIPASSresolution actually lands.Related