Lines Matching defs:node
128 function render_node($node, $lefttoright) {
130 if ($node->nodeName=='identifier' || $node->nodeName=='terminal') {
131 $text = html_entity_decode($node->getAttribute('value'));
136 if ($node->nodeName!='terminal') {
148 } else if ($node->nodeName=='option' || $node->nodeName=='loop') {
149 if ($node->nodeName=='loop')
151 $inner = render_node($node->firstChild, $lefttoright);
157 arrow($im, $w/2+EBNF_U/2, EBNF_U, $node->nodeName=='loop'?!$lefttoright:$lefttoright);
165 } else if ($node->nodeName=='sequence') {
166 $inner = render_childs($node, $lefttoright);
182 } else if ($node->nodeName=='choise') {
183 $inner = render_childs($node, $lefttoright);
202 } else if ($node->nodeName=='syntax') {
203 $title = $node->getAttribute('title');
204 $meta = $node->getAttribute('meta');
205 $node = $node->firstChild;
208 while ($node!=null) {
209 $names[] = $node->getAttribute('name');
210 $im = render_node($node->firstChild, $lefttoright);
212 $node = $node->nextSibling;
247 function render_childs($node, $lefttoright) {
249 $node = $node->firstChild;
250 while ($node!=null) {
251 $childs[] = render_node($node, $lefttoright);
252 $node = $node->nextSibling;