In Files

  • rdoc/generator/texinfo.rb

Files

Class/Module Index [+]

Quicksearch

RDoc::Generator::TexinfoTemplate

Basically just a wrapper around ERB. Should probably use RDoc::TemplatePage instead

Constants

BASE_DIR

Public Class Methods

new(values, file = 'texinfo.erb') click to toggle source
 
               # File rdoc/generator/texinfo.rb, line 51
def initialize(values, file = 'texinfo.erb')
  @v, @file = [values, file]
end
            

Public Instance Methods

href(location, text) click to toggle source
 
               # File rdoc/generator/texinfo.rb, line 64
def href(location, text)
  text # TODO: how does texinfo do hyperlinks?
end
            
method_prefix(section) click to toggle source

TODO: this is probably implemented elsewhere?

 
               # File rdoc/generator/texinfo.rb, line 73
def method_prefix(section)
  { 'Class' => '.',
    'Module' => '::',
    'Instance' => '#',
  }[section['category']]
end
            
render() click to toggle source

Go!

 
               # File rdoc/generator/texinfo.rb, line 60
def render
  ERB.new(template).result binding
end
            
target(name, text) click to toggle source
 
               # File rdoc/generator/texinfo.rb, line 68
def target(name, text)
  text # TODO: how do hyperlink targets work?
end
            
template() click to toggle source
 
               # File rdoc/generator/texinfo.rb, line 55
def template
  ::File.read(::File.join(BASE_DIR, 'texinfo', @file))
end