blob: 7180729f75474b2c777e795f853a8c017b84c944 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
##
# A Paragraph of text
class RDoc::Markup::Paragraph < RDoc::Markup::Raw
##
# Calls #accept_paragraph on +visitor+
def accept visitor
visitor.accept_paragraph self
end
##
# Joins the raw paragraph text and converts inline HardBreaks to the
# +hard_break+ text.
def text hard_break = ''
@parts.map do |part|
if RDoc::Markup::HardBreak === part then
hard_break
else
part
end
end.join
end
end
|