1 require 'rdoc/generator/html'
2 require 'rdoc/generator/html/html'
4 module RDoc::Generator::HTML::HEFSS
6 FONTS = "Verdana, Arial, Helvetica, sans-serif"
9 body,p { font-family: Verdana, Arial, Helvetica, sans-serif;
10 color: #000040; background: #BBBBBB;
13 td { font-family: Verdana, Arial, Helvetica, sans-serif;
17 .attr-rw { font-size: small; color: #444488 }
19 .title-row {color: #eeeeff;
23 .big-title-font { color: white;
24 font-family: Verdana, Arial, Helvetica, sans-serif;
28 .small-title-font { color: purple;
29 font-family: Verdana, Arial, Helvetica, sans-serif;
32 .aqua { color: purple }
34 .method-name, attr-name {
35 font-family: monospace; font-weight: bold;
42 padding: 5px 0px 5px 20px;
52 padding: 5px 0px 5px 20px;
59 font-family: monospace;
73 text_decoration: none;
74 padding: 3px 3px 3px 20px;
81 text_decoration: none;
82 padding: 3px 3px 3px 20px;
87 font-family: monospace;
89 text_decoration: none;
90 padding: 3px 3px 3px 20px;
97 font-family: monospace;
98 text_decoration: none;
99 padding: 3px 3px 3px 20px;
106 .srcbut { float: right }
112 <title><%= values["title"] %></title>
113 <meta http-equiv="Content-Type" content="text/html; charset=<%= values["charset"] %>">
114 <link rel="stylesheet" href="<%= values["style_url"] %>" type="text/css" media="screen" />
115 <script type="text/javascript" language="JavaScript">
117 function popCode(url) {
118 parent.frames.source.location = url
123 <body bgcolor="#BBBBBB">
125 <%= template_include %> <!-- banner header -->
127 <% if values["diagram"] then %>
128 <table width="100%"><tr><td align="center">
129 <%= values["diagram"] %>
133 <% if values["description"] then %>
134 <div class="description"><%= values["description"] %></div>
137 <% if values["requires"] then %>
138 <table cellpadding="5" width="100%">
139 <tr><td class="tablesubtitle">Required files</td></tr>
141 <div class="name-list">
142 <% values["requires"].each do |requires| %>
143 <%= href requires["aref"], requires["name"] %>
144 <% end %><%# values["requires"] %>
148 <% if values["sections"] then %>
149 <% values["sections"].each do |sections| %>
150 <% if sections["method_list"] then %>
151 <% sections["method_list"].each do |method_list| %>
152 <% if method_list["methods"] then %>
153 <table cellpadding="5" width="100%">
154 <tr><td class="tablesubtitle">Subroutines and Functions</td></tr>
156 <div class="name-list">
157 <% method_list["methods"].each do |methods| %>
158 <a href="<%= methods["codeurl"] %>" target="source"><%= methods["name"] %></a>
159 <% end %><%# values["methods"] %>
162 <% end %><%# values["method_list"] %>
165 <% if sections["attributes"] then %>
166 <table cellpadding="5" width="100%">
167 <tr><td class="tablesubtitle">Arguments</td></tr>
169 <table cellspacing="5">
170 <% sections["attributes"].each do |attributes| %>
172 <% if attributes["rw"] then %>
173 <td align="center" class="attr-rw"> [<%= attributes["rw"] %>] </td>
175 <% unless attributes["rw"] then %>
178 <td class="attr-name"><%= attributes["name"] %></td>
179 <td><%= attributes["a_desc"] %></td>
181 <% end %><%# values["attributes"] %>
184 <% end %><%# values["sections"] %>
187 <% if values["classlist"] then %>
188 <table cellpadding="5" width="100%">
189 <tr><td class="tablesubtitle">Modules</td></tr>
191 <%= values["classlist"] %><br />
194 <%= template_include %> <!-- method descriptions -->
202 <tr class="title-row">
203 <td><table width="100%"><tr>
204 <td class="big-title-font" colspan="2"><font size="-3"><b>File</b><br /></font><%= values["short_name"] %></td>
205 <td align="right"><table cellspacing="0" cellpadding="2">
207 <td class="small-title-font">Path:</td>
208 <td class="small-title-font"><%= values["full_path"] %>
209 <% if values["cvsurl"] then %>
210 (<a href="<%= values["cvsurl"] %>"><acronym title="Concurrent Versioning System">CVS</acronym></a>)
215 <td class="small-title-font">Modified:</td>
216 <td class="small-title-font"><%= values["dtm_modified"] %></td>
219 </td></tr></table></td>
225 <table width="100%" border="0" cellspacing="0">
226 <tr class="title-row">
227 <td class="big-title-font">
228 <font size="-3"><b><%= values["classmod"] %></b><br /></font><%= values["full_name"] %>
231 <table cellspacing="0" cellpadding="2">
233 <td class="small-title-font">In:</td>
234 <td class="small-title-font">
235 <% values["infiles"].each do |infiles| %>
236 <%= href infiles["full_path_url"], infiles["full_path"] %>
237 <% if infiles["cvsurl"] then %>
238 (<a href="<%= infiles["cvsurl"] %>"><acronym title="Concurrent Versioning System">CVS</acronym></a>)
240 <% end %><%# values["infiles"] %>
243 <% if values["parent"] then %>
245 <td class="small-title-font">Parent:</td>
246 <td class="small-title-font">
247 <% if values["par_url"] then %>
248 <a href="<%= values["par_url"] %>" class="cyan">
250 <%= values["parent"] %>
251 <% if values["par_url"] then %>
264 <% if values["includes"] then %>
265 <div class="tablesubsubtitle">Uses</div><br />
266 <div class="name-list">
267 <% values["includes"].each do |includes| %>
268 <span class="method-name"><%= href includes["aref"], includes["name"] %></span>
269 <% end %><%# values["includes"] %>
273 <% if values["sections"] then %>
274 <% values["sections"].each do |sections| %>
275 <% if sections["method_list"] then %>
276 <% sections["method_list"].each do |method_list| %>
277 <% if method_list["methods"] then %>
278 <table cellpadding="5" width="100%">
279 <tr><td class="tablesubtitle"><%= method_list["type"] %> <%= method_list["category"] %> methods</td></tr>
281 <% method_list["methods"].each do |methods| %>
282 <table width="100%" cellspacing="0" cellpadding="5" border="0">
283 <tr><td class="methodtitle">
284 <a name="<%= methods["aref"] %>">
285 <b><%= methods["name"] %></b><%= methods["params"] %>
286 <% if methods["codeurl"] then %>
287 <a href="<%= methods["codeurl"] %>" target="source" class="srclink">src</a>
291 <% if method_list["m_desc"] then %>
292 <div class="description">
293 <%= method_list["m_desc"] %>
296 <% end %><%# method_list["methods"] %>
298 <% end %><%# sections["method_list"] %>
300 <% end %><%# values["sections"] %>
306 <head><title><%= values["title"] %></title>
307 <meta http-equiv="Content-Type" content="text/html; charset=<%= values["charset"] %>">
308 <style type="text/css">
309 .kw { color: #3333FF; font-weight: bold }
310 .cmt { color: green; font-style: italic }
311 .str { color: #662222; font-style: italic }
312 .re { color: #662222; }
313 .ruby-comment { color: green; font-style: italic }
314 .ruby-constant { color: #4433aa; font-weight: bold; }
315 .ruby-identifier { color: #222222; }
316 .ruby-ivar { color: #2233dd; }
317 .ruby-keyword { color: #3333FF; font-weight: bold }
318 .ruby-node { color: #777777; }
319 .ruby-operator { color: #111111; }
320 .ruby-regexp { color: #662222; }
321 .ruby-value { color: #662222; font-style: italic }
324 <body bgcolor="#BBBBBB">
325 <pre><%= values["code"] %></pre>
331 <%= template_include %>
337 <meta http-equiv="Content-Type" content="text/html; charset=<%= values["charset"] %>">
338 <style type="text/css">
341 background-color: #bbbbbb;
342 font-family: #{FONTS};
362 <base target="docwin">
365 <div class="banner"><%= values["list_title"] %></div>
366 <% values["entries"].each do |entries| %>
367 <a href="<%= entries["href"] %>"><%= entries["name"] %></a><br />
368 <% end %><%# values["entries"] %>
372 CLASS_INDEX = FILE_INDEX
373 METHOD_INDEX = FILE_INDEX
378 <title><%= values["title"] %></title>
379 <meta http-equiv="Content-Type" content="text/html; charset=<%= values["charset"] %>">
382 <frameset cols="20%,*">
383 <frameset rows="15%,35%,50%">
384 <frame src="fr_file_index.html" title="Files" name="Files">
385 <frame src="fr_class_index.html" name="Modules">
386 <frame src="fr_method_index.html" name="Subroutines and Functions">
388 <frameset rows="80%,20%">
389 <frame src="<%= values["initial_page"] %>" name="docwin">
390 <frame src="blank.html" name="source">
393 <body bgcolor="#BBBBBB">
394 Click <a href="html/index.html">here</a> for a non-frames
395 version of this page.
403 # Blank page to use as a target
405 <html><body bgcolor="#BBBBBB"></body></html>
408 def write_extra_pages
409 template = TemplatePage.new(BLANK)
410 File.open("blank.html", "w") { |f| template.write_html_on(f, {}) }