bug: Workbench toolbars not appearing when switching workbenches #230
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
When switching to workbenches like Part Design, toolbars for that workbench do not appear. The toolbar area remains populated only with the global toolbars (File, Edit, View, Structure, etc.) and none of the workbench-specific toolbars are shown.
Root Cause
Workbenches like PartDesign, Sketcher, and Assembly mark their toolbars with
DefaultVisibility::Unavailable, meaning they are hidden by default and their toggle actions are disabled. These toolbars rely entirely on theEditingContextResolver(a Kindred Create feature insrc/Gui/EditingContext.cpp) to callToolBarManager::setState(toolbars, ForceAvailable)to make them visible.The
EditingContextResolveronly matches specific editing states:sketcher.editpartdesign.featurepartdesign.bodyassembly.editassembly.idleempty_documentGap: If you switch to the Part Design workbench but don't have a Body activated (or if the context doesn't match any of the registered conditions), the workbench's toolbars remain hidden because no context calls
ForceAvailablefor them.Diagnostic Script
Run in FreeCAD's Python console to see toolbar visibility state: