lib/rdoc/ri/display.rb in rdoc-2.2.0 vs lib/rdoc/ri/display.rb in rdoc-2.2.1
- old
+ new
@@ -84,25 +84,23 @@
@formatter.display_heading("Constants:", 2, "")
constants = klass.constants.sort_by { |constant| constant.name }
constants.each do |constant|
+ @formatter.wrap "#{constant.name} = #{constant.value}"
if constant.comment then
- @formatter.wrap "#{constant.name}:"
-
@formatter.indent do
@formatter.display_flow constant.comment
end
else
- @formatter.wrap constant.name
+ @formatter.break_to_newline
end
end
end
unless klass.attributes.empty? then
@formatter.blankline
-
@formatter.display_heading 'Attributes:', 2, ''
attributes = klass.attributes.sort_by { |attribute| attribute.name }
attributes.each do |attribute|
@@ -111,9 +109,10 @@
@formatter.indent do
@formatter.display_flow attribute.comment
end
else
@formatter.wrap "#{attribute.name} (#{attribute.rw})"
+ @formatter.break_to_newline
end
end
end
return display_class_method_list(klass)