private void edit(DataType dt, String clickedName) {

		DataTypeManager dtm = model.getOriginalDataTypeManager();
		if (dtm == null) {
			// shouldn't happen
			model.setStatus("No Data Type Manager found for '" + clickedName + "'");
			return;
		}

		DataType actualType = dtm.getDataType(dt.getDataTypePath());
		if (actualType == null) {
			model.setStatus("Can't edit '" + dt.getDisplayName() + "' - type not found.");
			return;
		}

		dtmService.edit(actualType);
	}
Action for use in the composite data type editor.
This action has help associated with it.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/compositeeditor/EditComponentAction.java