can_activate and reason before building controls around it.
ReadTools
ReadDocument and a host with tool support. The same copied result is included in DocumentSnapshot.context. Headless hosts do not provide viewport tools.
The native adapter observes viewport focus and retains the last focused view when a floating dialog takes focus. Before a view has been selected, it uses the costume view. Focus the intended viewport, then click Refresh in your dialog to obtain that context. Switching the context or active tool invalidates an older snapshot revision.
Catalog and current activation support
These 20 IDs are the current mapped entries from the
CostumeTools registry family. Other application workflows, including FFD, fit checking, shrink fitting, pose editing, and primitive creation, still need separate public adapters. The catalog is an initial foundation for broader coverage.
ActivateTool
ActivateToolRequest contains DocumentHandle document, Revision expected_revision, and std::string tool_id. Requires ReadDocument and ActivateTools, a current nonzero revision, and an entry with can_activate = true.
Activation selects and prepares an interactive tool. It does not translate a part, rotate geometry, take a measurement, or apply an avatar value by itself. Use the tool in the viewport after activation. Its subsequent user edits follow the application’s existing commands.
Selecting an already-active tool is a no-op; it does not toggle the tool off. Activation does not add an undo entry. API avatar edits instead use the dedicated undoable height and measurement commands.
The adapter rejects document protection and intermediate tool interactions. Switching away from other tools requires finishing or deactivating them in the application first. Tools that can change authored geometry or patterns during setup remain catalog-only until their adapter can preserve command and state rules. You cannot bypass these checks with a registered tool ID.
In Python, armorsmith.context is the launch snapshot. armorsmith.ops.tools.activate(tool="picker_id") constructs an action for a host-owned button; it does not execute a tool during Python evaluation. See the Blender-oriented guide for the current scripting model.