File: cider-tree-view.el.html

A small tree view for result buffers that present a hierarchy of items the user can navigate, expand, and act on - think \"who calls this function\\", a call graph, or any flat list of jump-able results (a flat list is just a tree of depth one).

A node (see cider-tree-view-node) carries a display label, an optional primary action (on-visit, bound to RET), and an optional children-fn that yields its child nodes. Children are realized lazily: a node's children-fn runs the first time it is expanded, so a deep graph can be explored a level at a time without computing the whole thing up front.

The buffer keeps the node model and re-renders from it on every expand or collapse, rather than juggling overlays in place. That is a touch more work per toggle, but the trees here are small and the bookkeeping stays trivial.

Defined variables (7)

cider-tree-view--header-fnWhen non-nil, a function of no arguments that inserts content above the tree.
cider-tree-view--node-keymapKeymap put on a node’s label so a click visits it.
cider-tree-view--rootsThe list of root ‘cider-tree-view-node’s rendered in this buffer.
cider-tree-view-mode-abbrev-tableAbbrev table for ‘cider-tree-view-mode’.
cider-tree-view-mode-hookHook run after entering cider-tree-view mode.
cider-tree-view-mode-mapKeymap for ‘cider-tree-view-mode’.
cider-tree-view-mode-syntax-tableSyntax table for ‘cider-tree-view-mode’.

Defined functions (28)

cider-tree-view--children(NODE)
cider-tree-view--goto-node(NODE)
cider-tree-view--insert-node(NODE DEPTH)
cider-tree-view--render()
cider-tree-view-mode()
cider-tree-view-next-node()
cider-tree-view-node-at-point()
cider-tree-view-node-children(CL-X)
cider-tree-view-node-children--cmacro(CL-WHOLE-ARG CL-X)
cider-tree-view-node-children-fn(CL-X)
cider-tree-view-node-children-fn--cmacro(CL-WHOLE-ARG CL-X)
cider-tree-view-node-create
cider-tree-view-node-create--cmacro
cider-tree-view-node-expandable-p(NODE)
cider-tree-view-node-expanded(CL-X)
cider-tree-view-node-expanded--cmacro(CL-WHOLE-ARG CL-X)
cider-tree-view-node-label(CL-X)
cider-tree-view-node-label--cmacro(CL-WHOLE-ARG CL-X)
cider-tree-view-node-on-visit(CL-X)
cider-tree-view-node-on-visit--cmacro(CL-WHOLE-ARG CL-X)
cider-tree-view-node-p(CL-X)
cider-tree-view-node-p--cmacro(CL-WHOLE-ARG CL-X)
cider-tree-view-node-value(CL-X)
cider-tree-view-node-value--cmacro(CL-WHOLE-ARG CL-X)
cider-tree-view-previous-node()
cider-tree-view-render(ROOTS TITLE &optional HEADER-FN)
cider-tree-view-toggle()
cider-tree-view-visit(&optional EVENT)

Defined faces (0)