annotate view/layout/default/library.tt @ 11:573272ec604b

almost comlete doxygen library
author sergey
date Thu, 15 May 2014 18:24:02 +0400
parents 7d92a42f8e18
children d9551c7e7101
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
1 [%
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
2 labels(
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
3 CollectionTitle = "Home (%name%)"
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
4 );
11
573272ec604b almost comlete doxygen library
sergey
parents: 8
diff changeset
5 document.dojo.enable = 1;
8
7d92a42f8e18 improved doxygen library
sergey
parents: 7
diff changeset
6
7
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
7 document.css.push(css.library);
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
8
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
9 CollectionClass = 'Benzin::Doxygen::Model::Collection';
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
10 CompoundClass = 'Benzin::Doxygen::Model::Compound';
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
11 MemberClass = 'Benzin::Doxygen::Model::Member';
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
12
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
13 Icons = {
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
14 namespace = 'NS',
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
15 class = 'C',
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
16 variable = 'Var',
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
17 function = 'F',
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
18 property = 'P',
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
19 interface = 'I',
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
20 struct = 'S',
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
21 enum = 'E',
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
22 event = 'Ev'
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
23 };
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
24
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
25 NullIcon = '  ';
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
26
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
27 coll = resource.Seek('doxygenCollection');
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
28
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
29 compounds = coll.location.compounds;
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
30 members = resource.Seek('compound').location || coll.location.members;
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
31
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
32 document.title = model.canonicalName;
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
33
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
34 MACRO GetLocationFor(model) BLOCK;
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
35 members.Child(model.doxId) IF model.isa(MemberClass);
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
36 compounds.Child(model.doxId) IF model.isa(CompoundClass);
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
37 END;
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
38 %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
39 [% MACRO IconKind(model) BLOCK %]<span class="icon">[% Icons.item(model.kind) || NullIcon %]</span>[% END %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
40 [% MACRO Link(model,label,title) BLOCK %]<a class="$model.kind $model.protection" [% IF title %]title="$title" [% END %]href="[% GetLocationFor(model) %]">[% IconKind(model) %] $label</a>[% END %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
41 [% MACRO CompoundSiblings(model) BLOCK %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
42 [% compound = model.isa(MemberClass) ? model.compound : model %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
43 <ul class="members">
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
44 [% FOREACH item IN compound.GetSiblings({ kind = { '-not_in' = [ 'file', 'dir' ] } }) %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
45 <li [% IF item.doxId == compound.doxId %]class="active"[% END %]>[% Link(item,item.shortName, item.canonicalName) %]</li>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
46 [% END %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
47 </ul>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
48 [% END %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
49 [% MACRO Members(model) BLOCK %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
50 [% compound = model.isa(MemberClass) ? model.compound : model %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
51 <ul class="members">
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
52 [% FOREACH item IN compound.GetMembers({ kind = { '-not_in' = [ 'file', 'dir' ] } }) %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
53 <li [% IF item.doxId == model.doxId %]class="active"[% END %]>[% Link(item,item.shortName, item.canonicalName) %]</li>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
54 [% END %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
55 </ul>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
56 [% END %]
11
573272ec604b almost comlete doxygen library
sergey
parents: 8
diff changeset
57 [% BLOCK LAYOUT;
573272ec604b almost comlete doxygen library
sergey
parents: 8
diff changeset
58 render('base', content = content);
573272ec604b almost comlete doxygen library
sergey
parents: 8
diff changeset
59 END %]
573272ec604b almost comlete doxygen library
sergey
parents: 8
diff changeset
60 [% WRAPPER LAYOUT %]
7
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
61 <div class="library-pane">
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
62
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
63 <div id="toc-nav" class="nav-pane left">
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
64 [% IF model.isa(CollectionClass) %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
65
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
66 <ul class="dox-nav-menu">
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
67 <li class="last"><a href="$coll.location" title="$coll.model.description">[% CollectionTitle( name = coll.model.name) %]</a></li>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
68 [% Members(model) %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
69 </ul>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
70 [% ELSE %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
71 [%
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
72 parents = model.GetParents({ kind = { '-not_in' = [ 'file', 'dir' ] } });
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
73 parents.push(model) IF model.isa(CompoundClass);
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
74 %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
75 <ul class="dox-nav-menu">
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
76 <li [% IF !parents.size %]class="last"[% END %]><a href="$coll.location" title="$coll.model.description">[% CollectionTitle( name = coll.model.name) %]</a></li>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
77 [% FOREACH parent IN parents %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
78 <li [% IF loop.last %]class="last"[% END %]>[% Link(parent, parent.shortName, parent.canonicalName) %]</li>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
79 [% END %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
80 [% Members(model) %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
81 </ul>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
82 [% END %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
83 </div>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
84 <div id="siblings-nav" class="nav-pane right">
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
85 [% CompoundSiblings(model) %]
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
86 </div>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
87 <div id="content-pane" class="content-pane">
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
88 $content
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
89 </div>
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
90 <script type="text/javascript">
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
91 require(['implab/sticky'],function(sticky) {
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
92 sticky('toc-nav',{ along: 'content-pane' });
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
93 sticky('siblings-nav', { along: 'content-pane' });
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
94 });
fa7a99c2d079 dox library templates and schemas
sergey
parents:
diff changeset
95 </script>
8
7d92a42f8e18 improved doxygen library
sergey
parents: 7
diff changeset
96 </div>
11
573272ec604b almost comlete doxygen library
sergey
parents: 8
diff changeset
97 [% END %]