Module: RDoc::Generator::HTML::HEFSS

Defined in:
lib/rdoc/generator/html/hefss.rb

Constant Summary collapse

FONTS =
"Verdana, Arial, Helvetica, sans-serif"
STYLE =
"body,p { font-family: Verdana, Arial, Helvetica, sans-serif;\n     color: #000040; background: #BBBBBB;\n}\n\ntd { font-family: Verdana, Arial, Helvetica, sans-serif;\n     color: #000040;\n}\n\n.attr-rw { font-size: small; color: #444488 }\n\n.title-row {color:      #eeeeff;\n   background: #BBBBDD;\n}\n\n.big-title-font { color: white;\n                font-family: Verdana, Arial, Helvetica, sans-serif;\n                font-size: large;\n                height: 50px}\n\n.small-title-font { color: purple;\n                  font-family: Verdana, Arial, Helvetica, sans-serif;\n                  font-size: small; }\n\n.aqua { color: purple }\n\n.method-name, attr-name {\n    font-family: monospace; font-weight: bold;\n}\n\n.tablesubtitle {\n width: 100%;\n margin-top: 1ex;\n margin-bottom: .5ex;\n padding: 5px 0px 5px 20px;\n font-size: large;\n color: purple;\n background: #BBBBCC;\n}\n\n.tablesubsubtitle {\n width: 100%;\n margin-top: 1ex;\n margin-bottom: .5ex;\n padding: 5px 0px 5px 20px;\n font-size: medium;\n color: white;\n background: #BBBBCC;\n}\n\n.name-list {\nfont-family: monospace;\nmargin-left: 40px;\nmargin-bottom: 2ex;\nline-height: 140%;\n}\n\n.description {\nmargin-left: 40px;\nmargin-bottom: 2ex;\nline-height: 140%;\n}\n\n.methodtitle {\nfont-size: medium;\ntext_decoration: none;\npadding: 3px 3px 3px 20px;\ncolor: #0000AA;\n}\n\n.column-title {\nfont-size: medium;\nfont-weight: bold;\ntext_decoration: none;\npadding: 3px 3px 3px 20px;\ncolor: #3333CC;\n}\n\n.variable-name {\nfont-family: monospace;\nfont-size: medium;\ntext_decoration: none;\npadding: 3px 3px 3px 20px;\ncolor: #0000AA;\n}\n\n.row-name {\nfont-size: medium;\nfont-weight: medium;\nfont-family: monospace;\ntext_decoration: none;\npadding: 3px 3px 3px 20px;\n}\n\n.paramsig {\n font-size: small;\n}\n\n.srcbut { float: right }\n\n"
BODY =
"<html><head>\n<title><%= values[\"title\"] %></title>\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=<%= values[\"charset\"] %>\">\n<link rel=\"stylesheet\" href=\"<%= values[\"style_url\"] %>\" type=\"text/css\" media=\"screen\" />\n<script type=\"text/javascript\" language=\"JavaScript\">\n<!--\nfunction popCode(url) {\n  parent.frames.source.location = url\n}\n//-->\n</script>\n</head>\n<body bgcolor=\"#BBBBBB\">\n\n<%= template_include %>  <!-- banner header -->\n\n<% if values[\"diagram\"] then %>\n<table width=\"100%\"><tr><td align=\"center\">\n<%= values[\"diagram\"] %>\n</td></tr></table>\n<% end %>\n\n<% if values[\"description\"] then %>\n<div class=\"description\"><%= values[\"description\"] %></div>\n<% end %>\n\n<% if values[\"requires\"] then %>\n<table cellpadding=\"5\" width=\"100%\">\n<tr><td class=\"tablesubtitle\">Required files</td></tr>\n</table><br />\n<div class=\"name-list\">\n<% values[\"requires\"].each do |requires| %>\n<%= href requires[\"aref\"], requires[\"name\"] %>\n<% end # values[\"requires\"] %>\n<% end %>\n</div>\n\n<% if values[\"sections\"] then %>\n<% values[\"sections\"].each do |sections| %>\n<% if sections[\"method_list\"] then %>\n<% sections[\"method_list\"].each do |method_list| %>\n<% if method_list[\"methods\"] then %>\n<table cellpadding=\"5\" width=\"100%\">\n<tr><td class=\"tablesubtitle\">Subroutines and Functions</td></tr>\n</table><br />\n<div class=\"name-list\">\n<% method_list[\"methods\"].each do |methods| %>\n<a href=\"<%= methods[\"codeurl\"] %>\" target=\"source\"><%= methods[\"name\"] %></a>\n<% end # values[\"methods\"] %>\n</div>\n<% end %>\n<% end # values[\"method_list\"] %>\n<% end %>\n\n<% if sections[\"attributes\"] then %>\n<table cellpadding=\"5\" width=\"100%\">\n<tr><td class=\"tablesubtitle\">Arguments</td></tr>\n</table><br />\n<table cellspacing=\"5\">\n<% sections[\"attributes\"].each do |attributes| %>\n   <tr valign=\"top\">\n<% if attributes[\"rw\"] then %>\n     <td align=\"center\" class=\"attr-rw\">&nbsp;[<%= attributes[\"rw\"] %>]&nbsp;</td>\n<% end %>\n<% unless attributes[\"rw\"] then %>\n     <td></td>\n<% end %>\n     <td class=\"attr-name\"><%= attributes[\"name\"] %></td>\n     <td><%= attributes[\"a_desc\"] %></td>\n   </tr>\n<% end # values[\"attributes\"] %>\n</table>\n<% end %>\n<% end # values[\"sections\"] %>\n<% end %>\n\n<% if values[\"classlist\"] then %>\n<table cellpadding=\"5\" width=\"100%\">\n<tr><td class=\"tablesubtitle\">Modules</td></tr>\n</table><br />\n<%= values[\"classlist\"] %><br />\n<% end %>\n\n<%= template_include %>  <!-- method descriptions -->\n\n</body>\n</html>\n"
FILE_PAGE =
"<table width=\"100%\">\n <tr class=\"title-row\">\n <td><table width=\"100%\"><tr>\n <td class=\"big-title-font\" colspan=\"2\"><font size=\"-3\"><b>File</b><br /></font><%= values[\"short_name\"] %></td>\n <td align=\"right\"><table cellspacing=\"0\" cellpadding=\"2\">\n       <tr>\n         <td  class=\"small-title-font\">Path:</td>\n         <td class=\"small-title-font\"><%= values[\"full_path\"] %>\n<% if values[\"cvsurl\"] then %>\n    &nbsp;(<a href=\"<%= values[\"cvsurl\"] %>\"><acronym title=\"Concurrent Versioning System\">CVS</acronym></a>)\n<% end %>\n         </td>\n       </tr>\n       <tr>\n         <td class=\"small-title-font\">Modified:</td>\n         <td class=\"small-title-font\"><%= values[\"dtm_modified\"] %></td>\n       </tr>\n      </table>\n  </td></tr></table></td>\n</tr>\n</table><br />\n"
CLASS_PAGE =
"<table width=\"100%\" border=\"0\" cellspacing=\"0\">\n <tr class=\"title-row\">\n <td class=\"big-title-font\">\n <font size=\"-3\"><b><%= values[\"classmod\"] %></b><br /></font><%= values[\"full_name\"] %>\n </td>\n <td align=\"right\">\n <table cellspacing=\"0\" cellpadding=\"2\">\n   <tr valign=\"top\">\n    <td class=\"small-title-font\">In:</td>\n    <td class=\"small-title-font\">\n<% values[\"infiles\"].each do |infiles| %>\n<%= href infiles[\"full_path_url\"], infiles[\"full_path\"] %>\n<% if infiles[\"cvsurl\"] then %>\n&nbsp;(<a href=\"<%= infiles[\"cvsurl\"] %>\"><acronym title=\"Concurrent Versioning System\">CVS</acronym></a>)\n<% end %>\n<% end # values[\"infiles\"] %>\n    </td>\n   </tr>\n<% if values[\"parent\"] then %>\n   <tr>\n    <td class=\"small-title-font\">Parent:</td>\n    <td class=\"small-title-font\">\n<% if values[\"par_url\"] then %>\n      <a href=\"<%= values[\"par_url\"] %>\" class=\"cyan\">\n<% end %>\n<%= values[\"parent\"] %>\n<% if values[\"par_url\"] then %>\n       </a>\n<% end %>\n    </td>\n   </tr>\n<% end %>\n </table>\n</td>\n</tr>\n</table><br />\n"
METHOD_LIST =
"<% if values[\"includes\"] then %>\n<div class=\"tablesubsubtitle\">Uses</div><br />\n<div class=\"name-list\">\n<% values[\"includes\"].each do |includes| %>\n  <span class=\"method-name\"><%= href includes[\"aref\"], includes[\"name\"] %></span>\n<% end # values[\"includes\"] %>\n</div>\n<% end %>\n\n<% if values[\"sections\"] then %>\n<% values[\"sections\"].each do |sections| %>\n<% if sections[\"method_list\"] then %>\n<% sections[\"method_list\"].each do |method_list| %>\n<% if method_list[\"methods\"] then %>\n<table cellpadding=\"5\" width=\"100%\">\n<tr><td class=\"tablesubtitle\"><%= method_list[\"type\"] %> <%= method_list[\"category\"] %> methods</td></tr>\n</table>\n<% method_list[\"methods\"].each do |methods| %>\n<table width=\"100%\" cellspacing=\"0\" cellpadding=\"5\" border=\"0\">\n<tr><td class=\"methodtitle\">\n<a name=\"<%= methods[\"aref\"] %>\">\n<b><%= methods[\"name\"] %></b><%= methods[\"params\"] %>\n<% if methods[\"codeurl\"] then %>\n<a href=\"<%= methods[\"codeurl\"] %>\" target=\"source\" class=\"srclink\">src</a>\n<% end %>\n</a></td></tr>\n</table>\n<% if method_list[\"m_desc\"] then %>\n<div class=\"description\">\n<%= method_list[\"m_desc\"] %>\n</div>\n<% end %>\n<% end # method_list[\"methods\"] %>\n<% end %>\n<% end # sections[\"method_list\"] %>\n<% end %>\n<% end # values[\"sections\"] %>\n<% end %>\n"
SRC_PAGE =
"<html>\n<head><title><%= values[\"title\"] %></title>\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=<%= values[\"charset\"] %>\">\n<style type=\"text/css\">\n.kw { color: #3333FF; font-weight: bold }\n.cmt { color: green; font-style: italic }\n.str { color: #662222; font-style: italic }\n.re  { color: #662222; }\n.ruby-comment    { color: green; font-style: italic }\n.ruby-constant   { color: #4433aa; font-weight: bold; }\n.ruby-identifier { color: #222222;  }\n.ruby-ivar       { color: #2233dd; }\n.ruby-keyword    { color: #3333FF; font-weight: bold }\n.ruby-node       { color: #777777; }\n.ruby-operator   { color: #111111;  }\n.ruby-regexp     { color: #662222; }\n.ruby-value      { color: #662222; font-style: italic }\n</style>\n</head>\n<body bgcolor=\"#BBBBBB\">\n<pre><%= values[\"code\"] %></pre>\n</body>\n</html>\n"
FR_INDEX_BODY =
%{
<%= template_include %>
}
FILE_INDEX =
"<html>\n<head>\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=<%= values[\"charset\"] %>\">\n<style type=\"text/css\">\n<!--\nbody {\nbackground-color: #bbbbbb;\n   font-family: \#{FONTS};\n     font-size: 11px;\n    font-style: normal;\n   line-height: 14px;\n         color: #000040;\n}\ndiv.banner {\nbackground: #bbbbcc;\ncolor:      white;\npadding: 1;\nmargin: 0;\nfont-size: 90%;\nfont-weight: bold;\nline-height: 1.1;\ntext-align: center;\nwidth: 100%;\n}\n\n-->\n</style>\n<base target=\"docwin\">\n</head>\n<body>\n<div class=\"banner\"><%= values[\"list_title\"] %></div>\n<% values[\"entries\"].each do |entries| %>\n<a href=\"<%= entries[\"href\"] %>\"><%= entries[\"name\"] %></a><br />\n<% end # values[\"entries\"] %>\n</body></html>\n"
CLASS_INDEX =
FILE_INDEX
METHOD_INDEX =
FILE_INDEX
INDEX =
"<html>\n<head>\n<title><%= values[\"title\"] %></title>\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=<%= values[\"charset\"] %>\">\n</head>\n\n<frameset cols=\"20%,*\">\n  <frameset rows=\"15%,35%,50%\">\n      <frame src=\"fr_file_index.html\"   title=\"Files\" name=\"Files\">\n      <frame src=\"fr_class_index.html\"  name=\"Modules\">\n      <frame src=\"fr_method_index.html\" name=\"Subroutines and Functions\">\n  </frameset>\n  <frameset rows=\"80%,20%\">\n    <frame  src=\"<%= values[\"initial_page\"] %>\" name=\"docwin\">\n    <frame  src=\"blank.html\" name=\"source\">\n  </frameset>\n  <noframes>\n        <body bgcolor=\"#BBBBBB\">\n          Click <a href=\"html/index.html\">here</a> for a non-frames\n          version of this page.\n        </body>\n  </noframes>\n</frameset>\n\n</html>\n"
BLANK =

Blank page to use as a target

%{
<html><body bgcolor="#BBBBBB"></body></html>
}

Instance Method Summary collapse

Instance Method Details

#write_extra_pagesObject



408
409
410
411
# File 'lib/rdoc/generator/html/hefss.rb', line 408

def write_extra_pages
  template = TemplatePage.new(BLANK)
  File.open("blank.html", "w") { |f| template.write_html_on(f, {}) }
end