sophiasm
Topic Author
Posts: 1
Joined: 15 Jul 2026, 10:21

Loading different icon packs at runtime without restarting UI?

15 Jul 2026, 10:26

Hi everyone,

I'm building a UI where users can switch between multiple icon packs (default, outlined, and high-contrast) from the settings menu while the application is already running.

My current approach is to keep each icon pack in a separate ResourceDictionary with identical resource keys, then replace the merged dictionary at runtime. The icons update in some views, but a few controls continue showing the old resources until the view is recreated.

Is there a recommended way in NoesisGUI to swap an entire icon set during runtime so that all existing controls refresh automatically? Would using DynamicResource everywhere be the correct solution, or is there a better pattern for large icon libraries?

I'd appreciate any examples or best practices from projects that support runtime theme or icon switching.
Learning NoesisGUI one project at a time. Smash Karts Game
 
User avatar
jsantos
Site Admin
Posts: 4822
Joined: 20 Jan 2012, 17:18
Contact:

Re: Loading different icon packs at runtime without restarting UI?

15 Jul 2026, 14:38

Your approach seems sound. If you have multiple dictionaries and are binding to them using DynamicResource, then hot-swapping the dictionaries should update the icons.

Could you please paste a minimal reproducible example here that demonstrates the issue you're seeing?

Who is online

Users browsing this forum: No registered users and 14 guests