markdown2 :: MdParagraph :: defaultinit
# A paragraph block
class MdParagraph
super MdBlock
# Is this paragraph in a list?
fun is_in_list: Bool do
var parent = self.parent
return parent != null and parent.parent isa MdListBlock
end
# Is this paragraph in a tight list?
fun is_in_tight_list: Bool do
var parent = self.parent
if parent == null then return false
var gramps = parent.parent
return gramps isa MdListBlock and gramps.is_tight
end
end
lib/markdown2/markdown_ast.nit:334,1--351,3