Class: Jekyll::Tags::HighlightBlock

Inherits:
Liquid::Block
  • Object
show all
Defined in:
lib/jekyll-enhanced-codeblocks/start_line_formatter_patch.rb

Instance Method Summary collapse

Instance Method Details

#table_formatter(formatter) ⇒ Object



7
8
9
10
11
12
13
14
15
16
17
# File 'lib/jekyll-enhanced-codeblocks/start_line_formatter_patch.rb', line 7

def table_formatter(formatter)
  options = {
    :css_class    => "highlight",
    :gutter_class => "gutter",
    :code_class   => "code"
  }
  if @highlight_options[:start_line]
    options[:start_line] = @highlight_options[:start_line].to_i
  end
  Rouge::Formatters::HTMLTable.new(formatter, options)
end