Create a mapping
A mapping is a local JSON lookup from CAD layer names to existing Revit style and type names. It is not exported Revit geometry.
Walkthrough
- Open a project made from the firm template, the template as a project document, or a project containing a vetted drafting detail.
- Choose Codex > Mapping > Create Mapping and select the source DXF.
- Choose All styles in open project, or Only styles used in active drafting view. The latter is available only in a drafting view.
- For each CAD layer, select a line style and/or text type. Text labels display paper size in millimeters and font; the saved mapping contains exact type names.
- Enable Closed outline -> region only for layers whose closed polylines should become filled regions, then select a filled-region type.
- Leave unwanted layers blank. They will be skipped with diagnostics, not assigned automatic defaults.
- Select Save Mapping. Replacing an existing file requires confirmation.
- Run Convert CAD with the same DXF and saved mapping.
Mapping creation reads the project without modifying it. Choices start blank; there is no automatic name matching. Changing the style scope clears choices that are no longer available and displays a notice.
Important rules
- Layer names and target names match exactly, including case.
- For ordinary linework, leave region conversion off. Explicit region mapping changes a closed outline into a fill rather than a detail-line outline.
- Region conversion requires a selected type. An entirely empty mapping cannot be saved.
- The layer inventory covers model-space entities exposed by the DXF reader; it does not expand nested block content or unused layers.
- Reuse a vetted mapping only with projects that have the same approved styles.
- Editing an existing mapping currently requires a JSON editor; the UI creates new mappings.
JSON shape
This example uses placeholders, not real firm names:
{
"layers": {
"DETAIL": {
"lineStyle": "EXACT EXISTING LINE STYLE NAME",
"textType": "EXACT EXISTING TEXT TYPE NAME"
},
"FILL": {
"filledRegionType": "EXACT EXISTING FILLED REGION TYPE NAME"
}
}
}
Only include properties relevant to that layer. For missing target names, see troubleshooting.