texmath-0.8.3: Conversion between formats used to represent mathematics.

Safe Haskell | None
Language | Haskell2010

Text.TeXMath.Unicode.ToUnicode

Description

Function for replacing strings of characters with their respective mathvariant and vice versa.

Synopsis

- fromUnicodeChar :: Char -> Maybe (TextType, Char)
- toUnicodeChar :: (TextType, Char) -> Maybe Char
- fromUnicode :: TextType -> String -> String
- toUnicode :: TextType -> String -> String

# Documentation

fromUnicodeChar :: Char -> Maybe (TextType, Char)

The inverse of `toUnicodeChar`: returns the corresponding unstyled character and `TextType` of a unicode character.

toUnicodeChar :: (TextType, Char) -> Maybe Char

fromUnicode :: TextType -> String -> String

Inverse of `toUnicode`.

toUnicode :: TextType -> String -> String

Replace characters with their corresponding mathvariant unicode character. MathML has a mathvariant attribute which is unimplemented in Firefox (see here) Therefore, we may want to translate mathscr, etc to unicode symbols directly.