Create a definition list item node that describes the key type
    of a dict-type config field.

    Parameters
    ----------
    field : ``lsst.pex.config.Field``
        A ``lsst.pex.config.DictField`` or ``lsst.pex.config.DictConfigField``.
    state : ``docutils.statemachine.State``
        Usually the directive's ``state`` attribute.

    Returns
    -------
    ``docutils.nodes.definition_list_item``
        Definition list item that describes the key type for the field.

def create_keytype_item_node(field, state):
    """Create a definition list item node that describes the key type
    of a dict-type config field.

    Parameters
    ----------
    field : ``lsst.pex.config.Field``
        A ``lsst.pex.config.DictField`` or ``lsst.pex.config.DictConfigField``.
    state : ``docutils.statemachine.State``
        Usually the directive's ``state`` attribute.

    Returns
    -------
    ``docutils.nodes.definition_list_item``
        Definition list item that describes the key type for the field.
    """
    keytype_node = nodes.definition_list_item()
    keytype_node = nodes.term(text='Key type')
    keytype_def = nodes.definition()
    keytype_def += make_python_xref_nodes_for_type(
        field.keytype,
        state,
        hide_namespace=False)
    keytype_node += keytype_def
    return keytype_node