Latest 0.2.5
Homepage https://github.com/TeamSlader/iOSLaTeX
License MIT
Platforms ios 9.0
Frameworks WebKit
Authors

CI Status
Version
License
Platform

iOSLaTeX provides a LaTeXRenderer which loads a minified version of MathJax in a WkWebView to render LaTeX into native UIImage objects.

Usage

LaTeXImageView is a subclass of UIImageView which uses a LaTeXRenderer object instance to render LaTeX text. It can be added programatically or through the Storyboard. Simply set the latex property on the object and it will handle the rest. You can also use render(_ laTeX:, completion:) .

LaTeXRenderer provides an easy to use render(_ laTeX:, completion:) function which can be used to render LaTeX. Note that LaTeXRenderer needs to be initialized with a parent view present in the view hierarchy else LaTeX rendering will be slow or timeout.

If you have multiple LaTeXImageView objects in one controller (e.g. in a table view), you can declare a global LaTeXRenderer for that controller and inject it into the LaTeXImageView objects.

See example project for example code

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Installation

iOSLaTeX is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod 'iOSLaTeX'

Author

shujew, [email protected]

License

iOSLaTeX is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "iOSLaTeX",
    "version": "0.2.5",
    "summary": "iOS LaTeX Renderer written in Swift 3.2",
    "description": "iOSLaTeX provides a LaTeXRenderer which loads a minified version of MathJax in a WkWebView to render LaTeX into native UIImage objects",
    "homepage": "https://github.com/TeamSlader/iOSLaTeX",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "shujew": "[email protected]"
    },
    "source": {
        "git": "https://github.com/TeamSlader/iOSLaTeX.git",
        "tag": "0.2.5"
    },
    "platforms": {
        "ios": "9.0"
    },
    "source_files": "iOSLaTeX/Classes/**/*",
    "resources": [
        "iOSLaTeX/External/mathjax",
        "iOSLaTeX/Assets/*"
    ],
    "frameworks": "WebKit",
    "swift_version": "3.2"
}

Pin It on Pinterest

Share This