view vendor/gems/coderay-0.9.7/lib/coderay/encoders/yaml.rb @ 503:5d608412b003 feature_212

Pull out font name specifications from stylesheets and serve differently to different platforms (falling back to our usual web fonts). Fixes #212
author Chris Cannam <chris.cannam@soundsoftware.ac.uk>
date Thu, 14 Jul 2011 10:14:03 +0100
parents 0579821a129a
children
line wrap: on
line source
module CodeRay
module Encoders

  # = YAML Encoder
  #
  # Slow.
  class YAML < Encoder

    register_for :yaml

    FILE_EXTENSION = 'yaml'

  protected
    def compile tokens, options
      require 'yaml'
      @out = tokens.to_a.to_yaml
    end

  end

end
end