yard 0.8.3 → 0.8.4

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of yard might be problematic. Click here for more details.

Files changed (64) hide show
  1. data/ChangeLog +197 -38
  2. data/LICENSE +1 -1
  3. data/README.md +15 -4
  4. data/docs/GettingStarted.md +6 -6
  5. data/docs/WhatsNew.md +5 -0
  6. data/docs/images/code-objects-class-diagram.png +0 -0
  7. data/docs/images/handlers-class-diagram.png +0 -0
  8. data/docs/images/overview-class-diagram.png +0 -0
  9. data/docs/images/parser-class-diagram.png +0 -0
  10. data/docs/images/tags-class-diagram.png +0 -0
  11. data/lib/yard/autoload.rb +2 -0
  12. data/lib/yard/cli/graph.rb +3 -2
  13. data/lib/yard/cli/server.rb +3 -0
  14. data/lib/yard/cli/yardoc.rb +1 -0
  15. data/lib/yard/code_objects/base.rb +60 -30
  16. data/lib/yard/code_objects/extra_file_object.rb +1 -1
  17. data/lib/yard/code_objects/proxy.rb +1 -0
  18. data/lib/yard/docstring.rb +36 -2
  19. data/lib/yard/docstring_parser.rb +25 -2
  20. data/lib/yard/handlers/base.rb +18 -2
  21. data/lib/yard/handlers/c/handler_methods.rb +1 -1
  22. data/lib/yard/handlers/processor.rb +3 -0
  23. data/lib/yard/handlers/ruby/class_handler.rb +1 -2
  24. data/lib/yard/handlers/ruby/dsl_handler_methods.rb +7 -1
  25. data/lib/yard/handlers/ruby/exception_handler.rb +2 -2
  26. data/lib/yard/handlers/ruby/legacy/class_handler.rb +4 -3
  27. data/lib/yard/handlers/ruby/legacy/exception_handler.rb +2 -2
  28. data/lib/yard/handlers/ruby/legacy/method_handler.rb +4 -4
  29. data/lib/yard/handlers/ruby/legacy/yield_handler.rb +4 -4
  30. data/lib/yard/handlers/ruby/method_handler.rb +6 -6
  31. data/lib/yard/handlers/ruby/struct_handler_methods.rb +4 -4
  32. data/lib/yard/handlers/ruby/yield_handler.rb +4 -4
  33. data/lib/yard/i18n/locale.rb +16 -0
  34. data/lib/yard/parser/ruby/legacy/statement_list.rb +3 -0
  35. data/lib/yard/parser/ruby/ruby_parser.rb +9 -4
  36. data/lib/yard/rubygems/doc_manager.rb +16 -7
  37. data/lib/yard/server/templates/default/fulldoc/html/images/processing.gif +0 -0
  38. data/lib/yard/tags/directives.rb +3 -2
  39. data/lib/yard/tags/overload_tag.rb +1 -1
  40. data/lib/yard/templates/helpers/html_helper.rb +5 -2
  41. data/lib/yard/templates/helpers/html_syntax_highlight_helper.rb +3 -3
  42. data/lib/yard/version.rb +1 -1
  43. data/spec/cli/server_spec.rb +18 -0
  44. data/spec/code_objects/base_spec.rb +32 -1
  45. data/spec/handlers/base_spec.rb +9 -0
  46. data/spec/handlers/dsl_handler_spec.rb +12 -1
  47. data/spec/handlers/examples/dsl_handler_001.rb.txt +16 -1
  48. data/spec/handlers/examples/visibility_handler_001.rb.txt +5 -0
  49. data/spec/handlers/method_handler_spec.rb +3 -3
  50. data/spec/handlers/processor_spec.rb +12 -1
  51. data/spec/handlers/visibility_handler_spec.rb +5 -0
  52. data/spec/parser/ruby/ruby_parser_spec.rb +13 -0
  53. data/spec/parser/source_parser_spec.rb +38 -1
  54. data/spec/server/doc_server_helper_spec.rb +2 -0
  55. data/spec/tags/directives_spec.rb +8 -1
  56. data/spec/tags/overload_tag_spec.rb +1 -1
  57. data/spec/templates/helpers/html_helper_spec.rb +25 -5
  58. data/templates/default/class/setup.rb +1 -1
  59. data/templates/default/module/html/box_info.erb +1 -1
  60. data/templates/default/tags/html/example.erb +1 -1
  61. data/templates/default/tags/setup.rb +1 -1
  62. data/templates/guide/fulldoc/html/css/style.css +12 -5
  63. data/templates/guide/layout/html/layout.erb +4 -4
  64. metadata +3 -3
@@ -5,7 +5,7 @@
5
5
  <% unless tag.name.empty? %>
6
6
  <p class="example_title"><%= htmlify_line(tag.name) %></p>
7
7
  <% end %>
8
- <pre class="example code"><%= html_syntax_highlight(tag.text) %></pre>
8
+ <pre class="example code"><code><%= html_syntax_highlight(tag.text) %></code></pre>
9
9
  <% end %>
10
10
  </div>
11
11
  <% end %>
@@ -7,7 +7,7 @@ end
7
7
 
8
8
  def return
9
9
  if object.type == :method
10
- return if object.name == :initialize && object.scope == :instance
10
+ return if object.constructor?
11
11
  return if object.tags(:return).size == 1 && object.tag(:return).types == ['void']
12
12
  end
13
13
  tag(:return)
@@ -2,6 +2,9 @@ body { color: #3e4349; font-family: Georgia, serif; font-size: 17px; margin: 0;
2
2
  h1, h2, h3, h4, h5, h6 { font-weight: normal; color: #000; font-family: Georgia, serif; }
3
3
  h1 { color: #040; }
4
4
  h2 { color: #060; }
5
+ h3 { color: #070; }
6
+ h4 { color: #080; }
7
+ h5 { color: #090; }
5
8
  #sidebar h2 { color: #2f2; }
6
9
  strong { color: #000; }
7
10
  .object_link, tt, code { font-family: 'Consolas', 'BitStream Vera Sans Mono', monospace; font-size: 14px; }
@@ -26,22 +29,26 @@ ul { list-style: square; }
26
29
  .docstring h1 { font-size: 1.2em; }
27
30
  .docstring h2 { font-size: 1.1em; }
28
31
  .docstring h3 { font-size: 1.1em; }
32
+ .docstring h4 { font-size: 1.0em; font-weight: bold; }
33
+ .docstring h5 { font-size: 1.0em; font-weight: bold; }
34
+ .docstring h6 { font-size: 1.0em; font-weight: bold; }
29
35
  #filecontents strong { font-weight: normal; color: #000; }
30
36
  .readonly { font-size: 0.75em; color: #888; vertical-align: super; }
31
37
  .rdoc-term { padding-right: 25px; font-weight: bold; }
32
38
  .rdoc-list p { margin: 0; padding: 0; margin-bottom: 4px; }
33
39
 
34
40
  #page { width: 940px; margin: 0px auto; }
35
- #top_nav { background: #8e0; padding: 4px 8px; }
41
+ #top_nav { background: #7d0; padding: 8px 12px; }
36
42
  #inner_nav { width: 940px; margin: 0px auto; }
37
43
  #inner_nav a { border: 0; text-decoration: none; color: #777; }
38
- #inner_nav a:hover { color: #eee; }
44
+ #inner_nav a:hover { color: #222; }
39
45
  #top_nav .links { display: block; float: right; }
40
46
  #content { margin-left: 30px; width: 660px; float: left; }
41
47
  #sidebar { float: left; width: 200px; float: left; padding: 18px 10px; padding-top: 0; }
42
48
  #sidebar h2 { font-weight: 100; color: #3e4349; font-size: 1.45em; }
43
- #sidebar ol { padding-left: 19px; margin-left: 0; list-style: square; }
44
- #sidebar a { color: #777; }
49
+ #sidebar ol { padding-left: 16px; margin-left: 0; list-style: square; }
50
+ #sidebar a { color: #468; text-decoration: none; }
51
+ #sidebar a:hover { color: #000; background: #8e0; padding: 4px; }
45
52
  #sidebar ol.top { padding-left: 0; margin-left: 0; list-style: none; }
46
53
  #sidebar a { font-size: 0.9em; }
47
54
  #footer { margin: 0 auto; width: 940px; text-align: center; margin-top: 30px; padding: 20px 0; color: #888; font-size: 0.8em; border-top: 1px dotted #bbb; }
@@ -49,7 +56,7 @@ ul { list-style: square; }
49
56
  #links strong { font-size: 0.95em; font-weight: normal; color: #000; }
50
57
 
51
58
  a { color: #268; text-decoration: none; }
52
- a:hover { color: #060; background: #8e0; }
59
+ a:hover { color: #6ae; }
53
60
 
54
61
  /* syntax highlighting */
55
62
  .source_code { display: none; padding: 3px 8px; border-left: 8px solid #ddd; margin-top: 5px; }
@@ -23,10 +23,10 @@
23
23
  <% if options.readme != options.file && options.title %>
24
24
  <span class="title"><strong><%= options.title %></strong>: <%= @page_title %></span>
25
25
  <small class="links">
26
- <% links = [link_file('index.html', 'top'),
27
- @prevfile ? link_file(@prevfile, 'prev') : nil,
28
- @nextfile ? link_file(@nextfile, 'next') : nil].compact %>
29
- (<%= links.join(", ") %>)
26
+ <% links = [@prevfile ? link_file(@prevfile, '&larr;') : nil,
27
+ link_file('index.html', '&uarr;'),
28
+ @nextfile ? link_file(@nextfile, '&rarr;') : nil].compact %>
29
+ <%= links.join(" ") %>
30
30
  </small>
31
31
  <% end %>
32
32
  </div>
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: yard
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.3
4
+ version: 0.8.4
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-10-15 00:00:00.000000000 Z
12
+ date: 2013-02-04 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: ! " YARD is a documentation generation tool for the Ruby programming
15
15
  language.\n It enables the user to generate consistent, usable documentation
@@ -588,7 +588,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
588
588
  version: '0'
589
589
  requirements: []
590
590
  rubyforge_project: yard
591
- rubygems_version: 1.8.16
591
+ rubygems_version: 1.8.23
592
592
  signing_key:
593
593
  specification_version: 3
594
594
  summary: Documentation tool for consistent and usable documentation in Ruby.