Sha256: 715da339a77c9525248c4007a5a0af143623e0ac98957c481d7d79a6a7a7a6a3

Contents?: true

Size: 561 Bytes

Versions: 91

Compression:

Stored size: 561 Bytes

Contents

# encoding=utf-8
require 'polytexnic/literal'
require 'polytexnic/code_inclusion'
require 'polytexnic/preprocessors/html'
require 'polytexnic/preprocessors/latex'
require 'polytexnic/preprocessors/polytex'

module Polytexnic
  module Preprocessor
    include Literal
    include Html
    include Latex
    include Polytex

    # Preprocesses the input based on output format.
    def preprocess(format)
      case format
      when :html    then to_xml
      when :latex   then to_processed_latex
      when :polytex then to_polytex
      end
    end
  end
end

Version data entries

91 entries across 91 versions & 1 rubygems

Version Path
polytexnic-1.2.1 lib/polytexnic/preprocessor.rb
polytexnic-1.2.0 lib/polytexnic/preprocessor.rb
polytexnic-1.1.14 lib/polytexnic/preprocessor.rb
polytexnic-1.1.11 lib/polytexnic/preprocessor.rb
polytexnic-1.1.10 lib/polytexnic/preprocessor.rb
polytexnic-1.1.9 lib/polytexnic/preprocessor.rb
polytexnic-1.1.8 lib/polytexnic/preprocessor.rb
polytexnic-1.1.7 lib/polytexnic/preprocessor.rb
polytexnic-1.1.6 lib/polytexnic/preprocessor.rb
polytexnic-1.1.5 lib/polytexnic/preprocessor.rb
polytexnic-1.1.4 lib/polytexnic/preprocessor.rb
polytexnic-1.1.3 lib/polytexnic/preprocessor.rb
polytexnic-1.1.2 lib/polytexnic/preprocessor.rb
polytexnic-1.1.1 lib/polytexnic/preprocessor.rb
polytexnic-1.1.0 lib/polytexnic/preprocessor.rb
polytexnic-1.1.beta2 lib/polytexnic/preprocessor.rb
polytexnic-1.0.4 lib/polytexnic/preprocessor.rb
polytexnic-1.0.3 lib/polytexnic/preprocessor.rb
polytexnic-1.1.beta1 lib/polytexnic/preprocessor.rb
polytexnic-1.0.2 lib/polytexnic/preprocessor.rb