lib/annlat/annlat.rb
##
# Used at the server side only
Used at the server side only
Used at the server side only
def to_html
    objects = @objects.each_with_index.map do |arr, external_index |
      arr.each_with_index.map do |obj, index|
        tag = @tags[external_index][index]
        case tag
          when 'String', 'Image'
            obj
          when 'Latex'
            ' \(' + obj + '\) '
          else
            obj.to_s
        end
      end
    end
    AnnLat.new(objects, @tags, @options)
  end
def to_html objects = @objects . each_with_index . map do | arr , external_index | arr . each_with_index . map do | obj , index | tag = @tags [ external_index ] [ index ] case tag when 'String' , 'Image' obj when 'Latex' ' \(' + obj + '\) ' else obj . to_s end end end AnnLat . new ( objects , @tags , @options ) end
Used at the server side only
Used at the server side only