accept_heading(heading)
public
Adds heading to the output. The headings greater than 6 are
trimmed to level 6.
# File lib/rdoc/markup/to_html.rb, line 276
def accept_heading heading
level = [6, heading.level].min
label = heading.label @code_object
@res << if @options.output_decoration
"\n<h#{level} id=\"#{label}\">"
else
"\n<h#{level}>"
end
@res << to_html(heading.text)
unless @options.pipe then
@res << "<span><a href=\"##{label}\">¶</a>"
@res << " <a href=\"#top\">↑</a></span>"
end
@res << "</h#{level}>\n"
end