Class: YARD::Templates::Helpers::Markup::RDocMarkupToHtml

Inherits:
Object
  • Object
show all
Defined in:
lib/yard/templates/helpers/markup/rdoc_markup.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#from_pathObject

Returns the value of attribute from_path.



68
69
70
# File 'lib/yard/templates/helpers/markup/rdoc_markup.rb', line 68

def from_path
  @from_path
end

Instance Method Details

#accept_paragraph(*args) ⇒ Object



75
76
77
78
79
80
# File 'lib/yard/templates/helpers/markup/rdoc_markup.rb', line 75

def accept_paragraph(*args)
  par = args.last
  text = par.respond_to?(:txt) ? par.txt : par.text
  @hyperlink = !!(text =~ /\{(https?:|mailto:|link:|www\.)/)
  super
end

Disable auto-link of URLs



71
72
73
# File 'lib/yard/templates/helpers/markup/rdoc_markup.rb', line 71

def handle_special_HYPERLINK(special)
  @hyperlink ? special.text : super
end