Sha256: 463e34264244d57d01231b660965175d50300ff9c2703017825b6c7e357d035f

Contents?: true

Size: 738 Bytes

Versions: 4

Compression:

Stored size: 738 Bytes

Contents

module Plurimath
  module Math
    module Symbols
      class Tilde < Symbol
        INPUT = {
          unicodemath: [["~"]],
          asciimath: [["~"]],
          mathml: ["~"],
          latex: [["~"]],
          omml: ["~"],
          html: ["~"],
        }.freeze

        # output methods
        def to_latex
          "\\tilde"
        end

        def to_asciimath
          "tilde"
        end

        def to_unicodemath
          Utility.html_entity_to_unicode("&#x7e;")
        end

        def to_mathml_without_math_tag(_)
          ox_element("mi") << "&#x7e;"
        end

        def to_omml_without_math_tag(_)
          "&#x7e;"
        end

        def to_html
          "~"
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
plurimath-0.8.14 lib/plurimath/math/symbols/tilde.rb
plurimath-0.8.13 lib/plurimath/math/symbols/tilde.rb
plurimath-0.8.12 lib/plurimath/math/symbols/tilde.rb
plurimath-0.8.11 lib/plurimath/math/symbols/tilde.rb