mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-11-28 09:21:55 +01:00
cms::with_active put its settings in place of the active settings on its thread, but cms::working() still read the process-wide working settings. Code inside with_active could therefore read active settings from one context and working settings from another, and a set_active on another thread changed the working half while the scope ran. Inside with_active, working() now gives the working settings of the context it was given: the ones for_document put a document's profiles in place of, else that context itself. use_document_profiles and for_document still read the process working settings, because they install or keep process-wide contexts. Outside with_active nothing changes. The app calls with_active only with for_document contexts (canvas panes and the color mode change on open), whose working settings are the process ones, so the app reads the same working settings as before.