1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154
|
<html lang="en">
<head>
<title>ECB - the Emacs Code Browser</title>
<meta http-equiv="Content-Type" content="text/html">
<meta name=description content="ECB - the Emacs Code Browser">
<meta name=generator content="makeinfo 4.2">
<link href="http://www.gnu.org/software/texinfo/" rel=generator-home>
</head>
<body>
<p>
Node:<a name="Expanding">Expanding</a>,
Next:<a rel=next accesskey=n href="Customizing-the-display.html#Customizing%20the%20display">Customizing the display</a>,
Previous:<a rel=previous accesskey=p href="Visiting-tags.html#Visiting%20tags">Visiting tags</a>,
Up:<a rel=up accesskey=u href="The-Methods-buffer.html#The%20Methods%20buffer">The Methods buffer</a>
<hr><br>
<h4>Explicit and automatic expanding of the ECB-methods-buffer</h4>
<h5>Explicit expanding all nodes to a certain expansion level</h5>
<p>With the command <code>ecb-expand-methods-nodes</code> (bound to <kbd>C-c .
x</kbd>) you can get a fast overlook of the contents of the source-buffer,
because this command allows precisely expanding all tags with a
certain indentation-level. So you can either expand no tags (or with
other words collapse all tags) or expand all tags so see the contents
of a buffer at one glance. Or you can expand exactly that tags of a
certain indentation level.
<p>Which node-types are expanded (rsp. collapsed) by this command
depends for semantic-sources on the options
<code>ecb-methods-nodes-expand-spec</code> and
<code>ecb-methods-nodes-collapse-spec</code>! For non-semantic-sources always
all node-types are expanded/collapsed, i.e. the two options above
takes no effect for these files.
<h5>Explicit expanding of the current node to a certain level</h5>
<p>With the popup-menu of the methods-buffer an even more precise
expansion is possible because it allows not only expanding all tags
(see above) but offers in addition expanding only the current-node
(for which the menu was activated) to an exact level of expansion:
<p>All menu-entries are label with an expansion-"level" whereas level
specifies precisely which level of nodes should be expanded. level
means the indentation-level of the NODE itself and its (recursive)
subnodes relative to the NODE itself.
<p>So a level value X means that all (sub)nodes with an indentation-level
<= X relative to NODE are expanded and all other are collapsed.
<p>Examples:
<ul>
<li>Expand this node to level 0:
Expand only the NODE itself because it is the only node which has
indentation 0 to itself. All deeper indented nodes will be collapsed.
This is also the important difference between using this menu compared
to clicking onto the expand-symbol of the node: The latter one expands
the NODE to that expansion-state it has before the last collapsing (so
when deeper nodes has been expanded they will be expanded now to). The
former one expands exactly(!) to level 0, means expand only the node
itself and collapse all(!) its subnodes recursively(!).
<li>Expand this node to level 1:
Expand the NODE itself and all of its direct subnodes - because only
the direct subnodes of NODE have indentation-level 1 relativ to NODE.
All deeper nodes will be collapsed.
<li>Collapse this node completely:
Collapses the current node recursively, means collapse not only the
node itself but also its subnodes, the subnodes of the subnodes and so
on! This is very differnt from clicking onto the collapse symbol
because this action only collapses the node itself but preserves the
expansion-state of all its subnodes!
</ul>
<p>Expanding the current node with the popup-menu ignores the settings in
the options <code>ecb-methods-nodes-expand-spec</code> and
<code>ecb-methods-nodes-collapse-spec</code>!
<h5>Automatic expansion ot tags after buffer-parsing</h5>
<p>With the option <code>ecb-show-tags</code> you tell ECB how to display tags
of a certain tag-class (see <a href="Customizing-the-display.html#Customizing%20the%20display">Customizing the display</a>). Among other
things you can tell ECB that a certain tag-class should be combined
under an expanded or collapsed bucket-node. But such a setting defines
the expansion-state of such a bucket-node only direct afterwards the
buffer has been (re)parsed, which can occur after opening a file,
after autom. reparsing the buffer via semantic or after manually
rebuilding the methods-buffer of ECB.
<p>The tag-class <code>type</code> (classes, interfaces, enumerations etc.) is
divided into several subtypes by semantic. The subtypes are strings
which names exactly if the tag with tag-class <code>type</code> is a class,
an interface, an enumeration, a typedef etc. With the option
<code>ecb-type-tag-expansion</code> you can tell ECB if these type-tags
should be autom. expanded after (reparsing) a buffer (see above) or if
they should be displayed collapsed - so all its members (methods,
variables etc.) are hidden.
<h5>Automatic expanding the ECB-methods-buffer for current tag</h5>
<p>If the option <code>ecb-highlight-tag-with-point</code> is switched on, then
always that node in the method-buffer is highlighted which belongs to
the current semantic-tag under point in the current active
edit-window. But if this node is invisible (probably because its
parent node is collapsed) then no node is highlighted if the auto.
expanding feature is switched off.
<p>You can either switch on this feature with the option
<code>ecb-auto-expand-tag-tree</code> or even easier with the command
<code>ecb-toggle-auto-expand-tag-tree</code>.
<p>There is another option
<code>ecb-expand-methods-switch-off-auto-expand</code> which makes both
explicit and auto. expanding best working together. See the
documentation of this option to get the details.
<p>The autom. expanding feature is only available for semantic-sources!
<p>Previous versions of ECB have always fully expanded the whole tree in
the Methods-buffer if the current tag in the source-buffer was not
visible in the current tree - e.g. because the variables-bucket was
collapsed or the containing type of a tag (e.g. the class of a method)
was collapsed. So in most cases much more was expanded as needed to
make the current tag visible.
<p>The mechanism of ECB 2.22 and higher only expands the needed parts of
the tree-buffer to make the related node visible: First we try to
highlight the current tag with current expansion-state of the
Methods-buffer. If the node is not visible so the tag can not be
highlighted then we go upstairs the ladder of type-tags the current
tag belongs to (e.g. we expand successive the nodes of the whole
class-hierachy of the current method-tag until the related node
becomes visible). If there is no containing type for the current tag
then the node of the tag is probably contained in a toplevel-bucket
which is currently collapsed; in this case we expand only this
bucket-node and try highlighting again. Only if this has still no
success then we expand the full tree-buffer and try to highlight the
current tag.
<p>There is another option
<code>ecb-auto-expand-tag-tree-collapse-other</code>: If this option is set
then auto. expanding the tag-tree collapses all not related nodes.
This means that all nodes which have no relevance for the currently
highlighted node will be collapsed, because they are not necessary to
make the highlighted node visible. This feature is switched off by
default because if always collapses the complete Methods-tree before
the following highlighting of the node for the current tag expands the
needed parts of the tree-buffer.
</body></html>
|