rdoc 2.2.1 → 2.3.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of rdoc might be problematic. Click here for more details.

Files changed (95) hide show
  1. data.tar.gz.sig +2 -0
  2. data/.document +4 -0
  3. data/History.txt +35 -0
  4. data/Manifest.txt +36 -15
  5. data/README.txt +11 -27
  6. data/Rakefile +3 -0
  7. data/lib/rdoc.rb +1 -1
  8. data/lib/rdoc/cache.rb +32 -0
  9. data/lib/rdoc/code_objects.rb +121 -59
  10. data/lib/rdoc/generator.rb +196 -133
  11. data/lib/rdoc/generator/darkfish.rb +471 -0
  12. data/lib/rdoc/generator/html.rb +71 -60
  13. data/lib/rdoc/generator/html/html.rb +115 -115
  14. data/lib/rdoc/generator/html/one_page_html.rb +56 -56
  15. data/lib/rdoc/generator/ri.rb +2 -0
  16. data/lib/rdoc/generator/template/darkfish/.document +0 -0
  17. data/lib/rdoc/generator/template/darkfish/classpage.rhtml +302 -0
  18. data/lib/rdoc/generator/template/darkfish/filepage.rhtml +114 -0
  19. data/lib/rdoc/generator/template/darkfish/images/brick.png +0 -0
  20. data/lib/rdoc/generator/template/darkfish/images/brick_link.png +0 -0
  21. data/lib/rdoc/generator/template/darkfish/images/bug.png +0 -0
  22. data/lib/rdoc/generator/template/darkfish/images/bullet_black.png +0 -0
  23. data/lib/rdoc/generator/template/darkfish/images/bullet_toggle_minus.png +0 -0
  24. data/lib/rdoc/generator/template/darkfish/images/bullet_toggle_plus.png +0 -0
  25. data/lib/rdoc/generator/template/darkfish/images/date.png +0 -0
  26. data/lib/rdoc/generator/template/darkfish/images/find.png +0 -0
  27. data/lib/rdoc/generator/template/darkfish/images/loadingAnimation.gif +0 -0
  28. data/lib/rdoc/generator/template/darkfish/images/macFFBgHack.png +0 -0
  29. data/lib/rdoc/generator/template/darkfish/images/package.png +0 -0
  30. data/lib/rdoc/generator/template/darkfish/images/page_green.png +0 -0
  31. data/lib/rdoc/generator/template/darkfish/images/page_white_text.png +0 -0
  32. data/lib/rdoc/generator/template/darkfish/images/page_white_width.png +0 -0
  33. data/lib/rdoc/generator/template/darkfish/images/plugin.png +0 -0
  34. data/lib/rdoc/generator/template/darkfish/images/ruby.png +0 -0
  35. data/lib/rdoc/generator/template/darkfish/images/tag_green.png +0 -0
  36. data/lib/rdoc/generator/template/darkfish/images/wrench.png +0 -0
  37. data/lib/rdoc/generator/template/darkfish/images/wrench_orange.png +0 -0
  38. data/lib/rdoc/generator/template/darkfish/images/zoom.png +0 -0
  39. data/lib/rdoc/generator/template/darkfish/index.rhtml +57 -0
  40. data/lib/rdoc/generator/template/darkfish/js/darkfish.js +116 -0
  41. data/lib/rdoc/generator/template/darkfish/js/jquery.js +32 -0
  42. data/lib/rdoc/generator/template/darkfish/js/quicksearch.js +114 -0
  43. data/lib/rdoc/generator/template/darkfish/js/thickbox-compressed.js +10 -0
  44. data/lib/rdoc/generator/template/darkfish/rdoc.css +696 -0
  45. data/lib/rdoc/generator/xml.rb +19 -12
  46. data/lib/rdoc/generator/xml/rdf.rb +50 -50
  47. data/lib/rdoc/generator/xml/xml.rb +58 -58
  48. data/lib/rdoc/known_classes.rb +0 -1
  49. data/lib/rdoc/markup/preprocess.rb +4 -3
  50. data/lib/rdoc/markup/to_html.rb +4 -1
  51. data/lib/rdoc/markup/to_html_crossref.rb +28 -31
  52. data/lib/rdoc/options.rb +25 -20
  53. data/lib/rdoc/parser.rb +10 -2
  54. data/lib/rdoc/parser/c.rb +38 -29
  55. data/lib/rdoc/parser/f95.rb +32 -32
  56. data/lib/rdoc/parser/ruby.rb +5 -2
  57. data/lib/rdoc/parser/simple.rb +1 -0
  58. data/lib/rdoc/rdoc.rb +99 -47
  59. data/lib/rdoc/ri/cache.rb +6 -6
  60. data/lib/rdoc/ri/display.rb +22 -75
  61. data/lib/rdoc/ri/driver.rb +237 -78
  62. data/lib/rdoc/stats.rb +91 -28
  63. data/lib/rdoc/template.rb +6 -2
  64. data/test/test.ja.rdoc +8 -0
  65. data/test/test.ja.txt +8 -0
  66. data/test/test_attribute_manager.rb +9 -6
  67. data/test/test_rdoc_markup.rb +4 -2
  68. data/test/test_rdoc_markup_attribute_manager.rb +13 -3
  69. data/test/test_rdoc_markup_to_html.rb +18 -2
  70. data/test/test_rdoc_markup_to_html_crossref.rb +186 -249
  71. data/test/test_rdoc_parser.rb +17 -1
  72. data/test/test_rdoc_parser_c.rb +65 -10
  73. data/test/test_rdoc_parser_perl.rb +4 -2
  74. data/test/test_rdoc_parser_ruby.rb +6 -4
  75. data/test/test_rdoc_ri_attribute_formatter.rb +4 -2
  76. data/test/test_rdoc_ri_default_display.rb +8 -4
  77. data/test/test_rdoc_ri_driver.rb +4 -2
  78. data/test/test_rdoc_ri_formatter.rb +6 -4
  79. data/test/test_rdoc_ri_overstrike_formatter.rb +4 -2
  80. metadata +84 -33
  81. metadata.gz.sig +0 -0
  82. data/lib/rdoc/generator/chm.rb +0 -113
  83. data/lib/rdoc/generator/chm/chm.rb +0 -100
  84. data/lib/rdoc/generator/html/frameless.rb +0 -92
  85. data/lib/rdoc/generator/html/hefss.rb +0 -150
  86. data/lib/rdoc/generator/html/kilmer.rb +0 -151
  87. data/lib/rdoc/generator/html/kilmerfactory.rb +0 -427
  88. data/lib/rdoc/generator/texinfo.rb +0 -81
  89. data/lib/rdoc/generator/texinfo/class.texinfo.erb +0 -44
  90. data/lib/rdoc/generator/texinfo/file.texinfo.erb +0 -6
  91. data/lib/rdoc/generator/texinfo/method.texinfo.erb +0 -6
  92. data/lib/rdoc/generator/texinfo/texinfo.erb +0 -28
  93. data/test/rdoc_markup_to_html_crossref_reference.rb +0 -31
  94. data/test/test_rdoc_info_formatting.rb +0 -175
  95. data/test/test_rdoc_info_sections.rb +0 -136
@@ -6,113 +6,113 @@ module RDoc::Generator::HTML::ONE_PAGE_HTML
6
6
  include RDoc::Generator::HTML::Common
7
7
 
8
8
  CONTENTS_XML = <<-EOF
9
- <% if defined? classes and classes["description"] then %>
10
- <%= classes["description"] %>
9
+ <% if defined? classes and classes[:description] then %>
10
+ <%= classes[:description] %>
11
11
  <% end %>
12
12
 
13
- <% if defined? files and files["requires"] then %>
13
+ <% if defined? files and files[:requires] then %>
14
14
  <h4>Requires:</h4>
15
15
  <ul>
16
- <% files["requires"].each do |requires| %>
17
- <% if requires["aref"] then %>
18
- <li><a href="<%= requires["aref"] %>"><%= requires["name"] %></a></li>
16
+ <% files[:requires].each do |requires| %>
17
+ <% if requires[:aref] then %>
18
+ <li><a href="<%= requires[:aref] %>"><%= requires[:name] %></a></li>
19
19
  <% end %>
20
- <% unless requires["aref"] then %>
21
- <li><%= requires["name"] %></li>
20
+ <% unless requires[:aref] then %>
21
+ <li><%= requires[:name] %></li>
22
22
  <% end %>
23
- <% end %><%# files["requires"] %>
23
+ <% end %><%# files[:requires] %>
24
24
  </ul>
25
25
  <% end %>
26
26
 
27
- <% if defined? classes and classes["includes"] then %>
27
+ <% if defined? classes and classes[:includes] then %>
28
28
  <h4>Includes</h4>
29
29
  <ul>
30
- <% classes["includes"].each do |includes| %>
31
- <% if includes["aref"] then %>
32
- <li><a href="<%= includes["aref"] %>"><%= includes["name"] %></a></li>
30
+ <% classes[:includes].each do |includes| %>
31
+ <% if includes[:aref] then %>
32
+ <li><a href="<%= includes[:aref] %>"><%= includes[:name] %></a></li>
33
33
  <% end %>
34
- <% unless includes["aref"] then %>
35
- <li><%= includes["name"] %></li>
34
+ <% unless includes[:aref] then %>
35
+ <li><%= includes[:name] %></li>
36
36
  <% end %>
37
- <% end %><%# classes["includes"] %>
37
+ <% end %><%# classes[:includes] %>
38
38
  </ul>
39
39
  <% end %>
40
40
 
41
- <% if defined? classes and classes["sections"] then %>
42
- <% classes["sections"].each do |sections| %>
43
- <% if sections["attributes"] then %>
41
+ <% if defined? classes and classes[:sections] then %>
42
+ <% classes[:sections].each do |sections| %>
43
+ <% if sections[:attributes] then %>
44
44
  <h4>Attributes</h4>
45
45
  <table>
46
- <% sections["attributes"].each do |attributes| %>
47
- <tr><td><%= attributes["name"] %></td><td><%= attributes["rw"] %></td><td><%= attributes["a_desc"] %></td></tr>
48
- <% end %><%# sections["attributes"] %>
46
+ <% sections[:attributes].each do |attributes| %>
47
+ <tr><td><%= attributes[:name] %></td><td><%= attributes[:rw] %></td><td><%= attributes[:a_desc] %></td></tr>
48
+ <% end %><%# sections[:attributes] %>
49
49
  </table>
50
50
  <% end %>
51
51
 
52
- <% if sections["method_list"] then %>
52
+ <% if sections[:method_list] then %>
53
53
  <h3>Methods</h3>
54
- <% sections["method_list"].each do |method_list| %>
55
- <% if method_list["methods"] then %>
56
- <% method_list["methods"].each do |methods| %>
57
- <h4><%= methods["type"] %> <%= methods["category"] %> method:
58
- <% if methods["callseq"] then %>
59
- <a name="<%= methods["aref"] %>"><%= methods["callseq"] %></a>
54
+ <% sections[:method_list].each do |method_list| %>
55
+ <% if method_list[:methods] then %>
56
+ <% method_list[:methods].each do |methods| %>
57
+ <h4><%= methods[:type] %> <%= methods[:category] %> method:
58
+ <% if methods[:callseq] then %>
59
+ <a name="<%= methods[:aref] %>"><%= methods[:callseq] %></a>
60
60
  <% end %>
61
- <% unless methods["callseq"] then %>
62
- <a name="<%= methods["aref"] %>"><%= methods["name"] %><%= methods["params"] %></a></h4>
61
+ <% unless methods[:callseq] then %>
62
+ <a name="<%= methods[:aref] %>"><%= methods[:name] %><%= methods[:params] %></a></h4>
63
63
  <% end %>
64
64
 
65
- <% if methods["m_desc"] then %>
66
- <%= methods["m_desc"] %>
65
+ <% if methods[:m_desc] then %>
66
+ <%= methods[:m_desc] %>
67
67
  <% end %>
68
68
 
69
- <% if methods["sourcecode"] then %>
69
+ <% if methods[:sourcecode] then %>
70
70
  <blockquote><pre>
71
- <%= methods["sourcecode"] %>
71
+ <%= methods[:sourcecode] %>
72
72
  </pre></blockquote>
73
73
  <% end %>
74
- <% end %><%# method_list["methods"] %>
74
+ <% end %><%# method_list[:methods] %>
75
75
  <% end %>
76
- <% end %><%# sections["method_list"] %>
76
+ <% end %><%# sections[:method_list] %>
77
77
  <% end %>
78
- <% end %><%# classes["sections"] %>
78
+ <% end %><%# classes[:sections] %>
79
79
  <% end %>
80
80
  EOF
81
81
 
82
82
  ONE_PAGE = XHTML_STRICT_PREAMBLE + HTML_ELEMENT + %{
83
83
  <head>
84
- <title><%= values["title"] %></title>
85
- <meta http-equiv="Content-Type" content="text/html; charset=<%= values["charset"] %>" />
84
+ <title><%= values[:title] %></title>
85
+ <meta http-equiv="Content-Type" content="text/html; charset=<%= values[:charset] %>" />
86
86
  </head>
87
87
  <body>
88
- <% values["files"].each do |files| %>
89
- <h2>File: <a name="<%= files["href"] %>"><%= files["short_name"] %></a></h2>
88
+ <% values[:files].each do |files| %>
89
+ <h2>File: <a name="<%= files[:href] %>"><%= files[:short_name] %></a></h2>
90
90
  <table>
91
- <tr><td>Path:</td><td><%= files["full_path"] %></td></tr>
92
- <tr><td>Modified:</td><td><%= files["dtm_modified"] %></td></tr>
91
+ <tr><td>Path:</td><td><%= files[:full_path] %></td></tr>
92
+ <tr><td>Modified:</td><td><%= files[:dtm_modified] %></td></tr>
93
93
  </table>
94
94
  } + CONTENTS_XML + %{
95
- <% end %><%# values["files"] %>
95
+ <% end %><%# values[:files] %>
96
96
 
97
- <% if values["classes"] then %>
97
+ <% if values[:classes] then %>
98
98
  <h2>Classes</h2>
99
- <% values["classes"].each do |classes| %>
100
- <% if classes["parent"] then %>
101
- <h3><%= classes["classmod"] %> <a name="<%= classes["href"] %>"><%= classes["full_name"] %></a> &lt; <%= href classes["par_url"], classes["parent"] %></h3>
99
+ <% values[:classes].each do |classes| %>
100
+ <% if classes[:parent] then %>
101
+ <h3><%= classes[:classmod] %> <a name="<%= classes[:href] %>"><%= classes[:full_name] %></a> &lt; <%= href classes[:par_url], classes[:parent] %></h3>
102
102
  <% end %>
103
- <% unless classes["parent"] then %>
104
- <h3><%= classes["classmod"] %> <%= classes["full_name"] %></h3>
103
+ <% unless classes[:parent] then %>
104
+ <h3><%= classes[:classmod] %> <%= classes[:full_name] %></h3>
105
105
  <% end %>
106
106
 
107
- <% if classes["infiles"] then %>
107
+ <% if classes[:infiles] then %>
108
108
  (in files
109
- <% classes["infiles"].each do |infiles| %>
110
- <%= href infiles["full_path_url"], infiles["full_path"] %>
111
- <% end %><%# classes["infiles"] %>
109
+ <% classes[:infiles].each do |infiles| %>
110
+ <%= href infiles[:full_path_url], infiles[:full_path] %>
111
+ <% end %><%# classes[:infiles] %>
112
112
  )
113
113
  <% end %>
114
114
  } + CONTENTS_XML + %{
115
- <% end %><%# values["classes"] %>
115
+ <% end %><%# values[:classes] %>
116
116
  <% end %>
117
117
  </body>
118
118
  </html>
@@ -8,6 +8,8 @@ require 'rdoc/ri/descriptions'
8
8
 
9
9
  class RDoc::Generator::RI
10
10
 
11
+ RDoc::RDoc.add_generator self
12
+
11
13
  ##
12
14
  # Generator may need to return specific subclasses depending on the
13
15
  # options they are passed. Because of this we create them using a factory
@@ -0,0 +1,302 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
3
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
4
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
5
+ <head>
6
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
7
+
8
+ <title><%= classinfo[:classmod] %>: <%= classinfo[:full_name] %></title>
9
+
10
+ <link rel="stylesheet" href="<%= rel_prefix %>/rdoc.css" type="text/css" media="screen" />
11
+
12
+ <script src="<%= rel_prefix %>/js/jquery.js" type="text/javascript"
13
+ charset="utf-8"></script>
14
+ <script src="<%= rel_prefix %>/js/thickbox-compressed.js" type="text/javascript"
15
+ charset="utf-8"></script>
16
+ <script src="<%= rel_prefix %>/js/quicksearch.js" type="text/javascript"
17
+ charset="utf-8"></script>
18
+ <script src="<%= rel_prefix %>/js/darkfish.js" type="text/javascript"
19
+ charset="utf-8"></script>
20
+
21
+ </head>
22
+ <body class="<%= classinfo[:classmod].downcase %>">
23
+
24
+ <div id="metadata">
25
+ <div id="file-metadata">
26
+ <div id="file-list-section" class="section">
27
+ <h3 class="section-header">In Files</h3>
28
+ <div class="section-body">
29
+ <ul>
30
+ <% classinfo[:infiles].each do |file| %>
31
+ <li><a href="<%= rel_prefix %>/<%= file[:full_path] %>.html?TB_iframe=true&amp;height=550&amp;width=785"
32
+ class="thickbox" title="<%= file[:full_path] %>"><%= file[:full_path] %></a></li>
33
+ <% end %>
34
+ </ul>
35
+ </div>
36
+ </div>
37
+
38
+ <% if !svninfo.empty? %>
39
+ <div id="file-svninfo-section" class="section">
40
+ <h3 class="section-header">Subversion Info</h3>
41
+ <div class="section-body">
42
+ <dl class="svninfo">
43
+ <dt>Rev</dt>
44
+ <dd><%= svninfo[:rev] %></dd>
45
+
46
+ <dt>Last Checked In</dt>
47
+ <dd><%= svninfo[:commitdate].strftime('%Y-%m-%d %H:%M:%S') %>
48
+ (<%= svninfo[:commitdelta] %> ago)</dd>
49
+
50
+ <dt>Checked in by</dt>
51
+ <dd><%= svninfo[:committer] %></dd>
52
+ </dl>
53
+ </div>
54
+ </div>
55
+ <% end %>
56
+ </div>
57
+
58
+ <div id="class-metadata">
59
+
60
+ <!-- Parent Class -->
61
+ <% if classinfo[:classmod] == 'Class' %>
62
+ <div id="parent-class-section" class="section">
63
+ <h3 class="section-header">Parent</h3>
64
+ <% if classinfo[:par_url] %>
65
+ <p class="link"><a href="<%= classinfo[:par_url] %>"><%= classinfo[:parent] %></a></p>
66
+ <% else %>
67
+ <p class="link"><%= classinfo[:parent] %></p>
68
+ <% end %>
69
+ </div>
70
+ <% end %>
71
+
72
+ <!-- Namespace Contents -->
73
+ <% if classinfo[:sections].first.key?( :classlist ) %>
74
+ <div id="namespace-list-section" class="section">
75
+ <h3 class="section-header">Namespace</h3>
76
+ <ul class="link-list">
77
+ <% classinfo[:sections].first[:classlist].each do |desc| %>
78
+ <li><%= desc.sub(/^(\w+)/, %Q{<span class="type">\\1</span>}) %></li>
79
+ <% end %>
80
+ </ul>
81
+ </div>
82
+ <% end %>
83
+
84
+ <!-- Method Quickref -->
85
+ <% if classinfo.key?( :methods ) %>
86
+ <div id="method-list-section" class="section">
87
+ <h3 class="section-header">Methods</h3>
88
+ <ul class="link-list">
89
+ <% classinfo[:methods].each do |meth| %>
90
+ <li><a href="#<%= meth[:name] %>"><%= meth[:name]
91
+ %></a></li>
92
+ <% end %>
93
+ </ul>
94
+ </div>
95
+ <% end %>
96
+
97
+ <!-- Included Modules -->
98
+ <% if classinfo[:includes] %>
99
+ <div id="includes-section" class="section">
100
+ <h3 class="section-header">Included Modules</h3>
101
+ <ul class="link-list">
102
+ <% classinfo[:includes].each do |inc| %>
103
+ <% if inc[:aref].nil? %>
104
+ <li><span class="include"><%= inc[:name] %></span></li>
105
+ <% else %>
106
+ <li><a class="include" href="<%= inc[:aref] %>"><%= inc[:name] %></a></li>
107
+ <% end %>
108
+ <% end %>
109
+ </ul>
110
+ </div>
111
+ <% end %>
112
+ </div>
113
+
114
+ <div id="project-metadata">
115
+ <% simple_files = files.select {|_, file| file[:parser] == RDoc::Parser::Simple } %>
116
+ <% unless simple_files.empty? then %>
117
+ <div id="fileindex-section" class="section project-section">
118
+ <h3 class="section-header">Files</h3>
119
+ <ul>
120
+ <% simple_files.sort_by {|name,_| name }.each do |name, file| %>
121
+ <li class="file"><a href="<%= rel_prefix %>/<%= file[:short_name] %>.html"><%= h file[:short_name] %></a></li>
122
+ <% end %>
123
+ </ul>
124
+ </div>
125
+ <% end %>
126
+
127
+ <div id="classindex-section" class="section project-section">
128
+ <h3 class="section-header">Class Index
129
+ <span class="search-toggle"><img src="<%= rel_prefix %>/images/find.png"
130
+ height="16" width="16" alt="[+]"
131
+ title="show/hide quicksearch" /></span></h3>
132
+ <form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
133
+ <fieldset>
134
+ <legend>Quicksearch</legend>
135
+ <input type="text" name="quicksearch" value=""
136
+ class="quicksearch-field" />
137
+ </fieldset>
138
+ </form>
139
+
140
+ <ul class="link-list">
141
+ <% modsort.each do |cname| %>
142
+ <% cinfo = classes[cname] %>
143
+ <li><a href="<%= rel_prefix %>/<%= cinfo[:outfile] %>"><%= cname %></a></li>
144
+ <% end %>
145
+ </ul>
146
+ <div id="no-class-search-results" style="display: none;">No matching classes.</div>
147
+ </div>
148
+
149
+ <% if $DEBUG %>
150
+ <div id="debugging-toggle"><img src="<%= rel_prefix %>/images/bug.png"
151
+ alt="toggle debugging" height="16" width="16" /></div>
152
+ <% end %>
153
+ </div>
154
+ </div>
155
+
156
+ <div id="documentation">
157
+ <% if classinfo[:classmod] == 'Class' %>
158
+ <h1 class="class"><%= classinfo[:full_name] %></h1>
159
+ <% else %>
160
+ <h1 class="module"><%= classinfo[:full_name] %></h1>
161
+ <% end %>
162
+
163
+ <div id="description">
164
+ <%= classinfo[:description] %>
165
+ </div>
166
+
167
+
168
+ <!-- Constants -->
169
+ <% if classinfo[:sections].first[:constants] %>
170
+ <div id="constants-list" class="section">
171
+ <h3 class="section-header">Constants</h3>
172
+ <dl>
173
+ <% classinfo[:sections].first[:constants].each do |const| %>
174
+ <dt><a name="<%= const[:name] %>"><%= const[:name] %></a></dt>
175
+ <% if const[:desc] %>
176
+ <dd class="description"><%= const[:desc].strip %></dd>
177
+ <% else %>
178
+ <dd class="description missing-docs">(Not documented)</dd>
179
+ <% end %>
180
+ <% end %>
181
+ </dl>
182
+ </div>
183
+ <% end %>
184
+
185
+ <!-- Attributes -->
186
+ <% if classinfo[:sections].first[:attributes] %>
187
+ <div id="attribute-method-details" class="method-section section">
188
+ <h3 class="section-header">Attributes</h3>
189
+
190
+ <% classinfo[:sections].first[:attributes].each do |attrib| %>
191
+ <div id="<%= attrib[:name].downcase.gsub(/[^a-z]+/, '-') %>-attribute-method" class="method-detail">
192
+ <a name="<%= attrib[:name] %>"></a>
193
+ <% if attrib[:rw] =~ /w/i %>
194
+ <a name="<%= attrib[:name] %>="></a>
195
+ <% end %>
196
+ <div class="method-heading attribute-method-heading">
197
+ <span class="method-name"><%= h attrib[:name] %></span><span
198
+ class="attribute-access-type">[<%= attrib[:rw] %>]</span>
199
+ </div>
200
+
201
+ <div class="method-description">
202
+ <% if attrib[:a_desc] && !attrib[:a_desc].empty? %>
203
+ <%= attrib[:a_desc].strip %>
204
+ <% else %>
205
+ <p class="missing-docs">(Not documented)</p>
206
+ <% end %>
207
+ </div>
208
+ </div>
209
+ <% end %>
210
+ </div>
211
+ <% end %>
212
+
213
+ <!-- Methods -->
214
+ <% if classinfo[:sections].first[:method_list] %>
215
+ <% classinfo[:sections].first[:method_list].each do |methodlist| %>
216
+ <div id="<%= methodlist[:type].downcase %>-<%= methodlist[:category].downcase %>-method-details" class="method-section section">
217
+ <h3 class="section-header"><%= methodlist[:type] %> <%= methodlist[:category] %> Methods</h3>
218
+
219
+ <% methodlist[:methods].each do |methodinfo| %>
220
+
221
+ <%
222
+ # If the method doesn't have a 'name' attribute, it's defined in C, so make one out of the
223
+ # first method name in the callseq.
224
+ unless methodinfo[:name]
225
+ methodinfo[:name] = methodinfo[:callseq][/^.*?\.(\w+)/, 1] || methodinfo[:callseq]
226
+ end
227
+ %>
228
+ <% if methodinfo[:m_desc] =~ /Alias for/ %>
229
+ <div id="<%= methodinfo[:name].gsub( /[^a-z]+/, '-' ) %>-method" class="method-detail method-alias">
230
+ <% else %>
231
+ <div id="<%= methodinfo[:name].gsub( /[^a-z]+/, '-' ) %>-method" class="method-detail">
232
+ <% end %>
233
+ <a name="<%= methodinfo[:name] %>"></a>
234
+
235
+ <div class="method-heading">
236
+ <% if methodinfo[:callseq] %>
237
+ <span class="method-callseq"><%= methodinfo[:callseq].strip.gsub( /^\w.*?\./m, '') %></span>
238
+ <span class="method-click-advice">click to toggle source</span>
239
+ <% else %>
240
+ <span class="method-name"><%= methodinfo[:name] %></span><span
241
+ class="method-args"><%= methodinfo[:params] %></span>
242
+ <span class="method-click-advice">click to toggle source</span>
243
+ <% end %>
244
+ </div>
245
+
246
+ <div class="method-description">
247
+ <% if methodinfo[:m_desc] %>
248
+ <%= methodinfo[:m_desc].strip %>
249
+ <% else %>
250
+ <p class="missing-docs">(Not documented)</p>
251
+ <% end %>
252
+
253
+ <% if methodinfo[:sourcecode] %>
254
+ <div class="method-source-code"
255
+ id="<%= methodinfo[:name].gsub( /[^a-z]+/, '-' ) %>-source">
256
+ <pre>
257
+ <%= methodinfo[:sourcecode] %>
258
+ </pre>
259
+ </div>
260
+ <% end %>
261
+ </div>
262
+
263
+ <% if methodinfo[:aka] %>
264
+ <div class="aliases">
265
+ Also aliased as: <%= methodinfo[:aka].collect do |aliasinfo|
266
+ %{<a href="#{aliasinfo[:aref]}">#{aliasinfo[:name]}</a>}
267
+ end.join(", ") %>
268
+ </div>
269
+ <% end %>
270
+ </div>
271
+
272
+ <% end %>
273
+ </div>
274
+ <% end %>
275
+ <% end %>
276
+
277
+ </div>
278
+
279
+
280
+ <div id="rdoc-debugging-section-dump" class="debugging-section">
281
+ <% if $DEBUG %>
282
+ <% classinfo[:sections].first.keys.each do |section| %>
283
+ <div class="section">
284
+ <h2 class="section-header"><%= section %></h2>
285
+
286
+ <pre><%= h classinfo[:sections].first[section].to_yaml %></pre>
287
+ </div>
288
+ <% end %>
289
+ <% else %>
290
+ <p>Disabled; run with $DEBUG to generate this.</p>
291
+ <% end %>
292
+ </div>
293
+
294
+ <div id="validator-badges">
295
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
296
+ <p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
297
+ Rdoc Generator</a> <%= RDoc::Generator::Darkfish::VERSION %></small>.</p>
298
+ </div>
299
+
300
+ </body>
301
+ </html>
302
+