@7>
<@local(ps,name,id,switch,nclose)>
<@>
<$name = argv#0>
<$root = argv#1>
<$num = v.plugin_num(name)>
<$id = 'sidetag' . if(num != 1, num)>
<$ps = v.load_plgset(name)>
<$switch = ps.switch>
<$nclose = ps.nclose>
<$notag_arts = argv#2>
<@>
<@>-------------------------------------------------------------------
<@>再帰サブルーチン
<@>-------------------------------------------------------------------
<$sub = begin.function>
<@local(t, tid, p, node, tree, depth, x)>
<$node = argv#0>
<$tree = node.children>
<$depth = argv#1><@>prefix
<$p = "\t" %x depth>
<@p>
>
<@forexec(t, tree, begin.forexec)>
<$ifnext(!ps.disp_noart_tag && !t.qtall)>
<@ifexec(t.children && t.qt
<@p> - <@\>
<@ifexec(switch, begin)> <@\>
> <@\>
<$end> <@\>
<@t.sname><@if(switch, '')> (<@t.qtall>)
<@exec(sub, t, depth+1)>
<@p>
<$else>
<@p> - <@\>
<@t.sname> (<@t.qtall>)
<$end>
<$end.forexec>
<@ifexec(node.root && notag_arts && !ps.nodisp_notag, begin)>
- <@ps.notag_title || '(none)'> (<@notag_arts>)
<$end>
<@p>
<$end.function>
<@>-------------------------------------------------------------------
<@>タグリスト
<@>-------------------------------------------------------------------
<@ifexec(root && root.pkey, begin, begin)>
<$else>
<@ps.title || 'タグ'>
<$end>
<@ifexec(root, begin)>
<@exec(sub, root, 0)>
<$end>