Sha256: 5ad576d7f29abe3b4d5850a20238847f8eecaa1e448e93bf13101d21a2feca4f
Contents?: true
Size: 709 Bytes
Versions: 14
Compression:
Stored size: 709 Bytes
Contents
module Vedeu module Renderers # A renderer which returns the escape sequence for each character. # class EscapeSequence include Vedeu::RendererOptions # Returns a new instance of Vedeu::Renderers::EscapeSequence. # # @param options [Hash] def initialize(options = {}) @options = options || {} end # Render the output with the escape sequences escaped. # # @param output [Array<Array<Vedeu::Char>>] # @return [String] def render(output) @parsed ||= Array(output).flatten.map do |char| Esc.escape(char.to_s) + "\n" end.join end end # EscapeSequence end # Renderers end # Vedeu
Version data entries
14 entries across 14 versions & 1 rubygems