{"id":13514950,"url":"https://github.com/LeonStaufer/fluttex","last_synced_at":"2025-03-31T04:36:06.944Z","repository":{"id":56830675,"uuid":"252140319","full_name":"LeonStaufer/fluttex","owner":"LeonStaufer","description":" Customizable Flutter plugin that renders TeX equations blazingly fast! ","archived":false,"fork":false,"pushed_at":"2020-05-12T11:15:03.000Z","size":235,"stargazers_count":1,"open_issues_count":5,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-11-16T07:01:08.204Z","etag":null,"topics":["equations","flutter","flutter-plugin","katex","latex","renderer"],"latest_commit_sha":null,"homepage":"","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LeonStaufer.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-04-01T10:14:47.000Z","updated_at":"2023-12-20T13:50:29.000Z","dependencies_parsed_at":"2022-09-09T18:01:21.185Z","dependency_job_id":null,"html_url":"https://github.com/LeonStaufer/fluttex","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeonStaufer%2Ffluttex","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeonStaufer%2Ffluttex/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeonStaufer%2Ffluttex/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeonStaufer%2Ffluttex/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LeonStaufer","download_url":"https://codeload.github.com/LeonStaufer/fluttex/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246418658,"owners_count":20773934,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["equations","flutter","flutter-plugin","katex","latex","renderer"],"created_at":"2024-08-01T05:01:04.316Z","updated_at":"2025-03-31T04:36:06.269Z","avatar_url":"https://github.com/LeonStaufer.png","language":"Dart","readme":"\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/LeonStaufer/fluttex\"\u003e\n    \u003cimg src=\"https://raw.githubusercontent.com/LeonStaufer/fluttex/master/assets/logo.png\" alt=\"Logo for fluttex\" width=\"953\" height=\"272\" /\u003e\n  \u003c/a\u003e\n\n  \u003cp align=\"center\"\u003e\n    Customizable Flutter plugin that renders TeX equations blazingly fast!\n    \u003cbr /\u003e\n    \u003cbr /\u003e\n    \u003ca href='https://pub.dev/packages/fluttex'\u003e\u003cimg alt=\"pub.dev fluttex\" src=\"https://img.shields.io/pub/v/fluttex\" /\u003e\u003c/a\u003e\n    \u003ca href=\"https://github.com/LeonStaufer/fluttex/issues/new\"\u003e\u003cimg alt=\"GitHub issues\" src=\"https://img.shields.io/github/issues/LeonStaufer/fluttex\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://github.com/LeonStaufer/fluttex\"\u003e\u003cimg alt=\"BSD 3-Clause License\" src=\"https://img.shields.io/github/license/LeonStaufer/fluttex\"\u003e\u003c/a\u003e\n    \u003cbr /\u003e\n  \u003c/p\u003e\n\u003c/p\u003e\n\n## Table of Contents\n\n* [About](#about)\n  * [Built With](#built-with)\n* [Getting Started](#getting-started)\n  * [Installation](#installation)\n  * [Usage](#usage)\n* [Configuration](#configuration)\n* [Roadmap](#roadmap)\n* [Contributing](#contributing)\n* [License](#license)\n* [Contact](#contact)\n\n\n\n## About\n\n\u003cimg alt=\"Screenshot of the TeX Tools Example App\" src=\"https://raw.githubusercontent.com/LeonStaufer/fluttex/master/assets/screenshot.jpg\" width=\"400\" /\u003e\n\n**Fluttex** is a customizable Flutter plugin that renders TeX equations blazingly fast.\n\n\n### Built With\n\nThis project provides an efficient Widget that renders TeX equations using [KaTeX][katex]. Fluttex is built on [TeX Tools][textools], a TeX library for Android that uses WebViews as a wrapper for KaTeX. As such, it would not have been possible without the great work put into the KaTeX typesetting library for the web. \n\n## Getting Started\n\n### Installation\n\nRefer to the [installation guide](https://pub.dev/packages/fluttex#-installing-tab-) on pub.dev\n\n### Usage\n\nAdd the widget `MathViewStatic` to your build method. Take a look at the [configuration section](#configuration) to see which parameters you can pass.\n```dart\nvar MathView = new MathViewStatic(\n    tex: \"\\\\int_{-\\\\infty}^\\\\infty \\\\hat f(\\\\xi)\\\\,e^{2 \\\\pi i \\\\xi x} \\\\,d\\\\xi \\\\\\\\\",\n);\n```\n\nThe above is an example of a `MathView` that only has the `tex` parameter. Make note that all backslashes have to be escaped.\n\nIt is also possible to change the TeX parameter programmatically later on. Create a `MathViewStatic` as usual and add the `onMathViewCreated` callback.\n```dart\nvar MathView = new MathViewStatic(\n    onMathViewCreated: (controller) {\n        _mathViewController = controller;\n    },\n);\n```\n\nLater on, you can use the `MathViewController` to render new TeX strings.\n```dart\n_mathViewController.render(\"\\\\ce{\\$K = \\\\frac{[\\ce{Hg^2+}][\\\\ce{Hg}]}{[\\\\ce{Hg2^2+}]}\\$}\");\n```\n\nFor more detailed overview of the example, please refer to the [example directory](https://github.com/LeonStaufer/fluttex/tree/master/example).\n\n\n## Configuration\n\n#### MathView\n\nYou can change the following properties of the MathView.\n\n| Key            | Description                                                  | Type                                              | Default |\n| -------------- | ------------------------------------------------------------ | ------- | ------- |\n| `tex`  | A string of TeX that should be rendered | `String` | `null` |\n| `displayMode`  | \"If `true` the math will be rendered in display mode, which will put the math in display style (so `\\int` and `\\sum` are large, for example), and will center the math on the page on its own line. If `false` the math will be rendered in inline mode.\" | `boolean` | `false` |\n| `leqno`        | \"If `true`, display math has `\\tag`s rendered on the left instead of the right, like `\\usepackage[leqno]{amsmath}` in LaTeX.\" | `boolean` | `false` |\n| `fleqno`       | \"If `true`, display math renders flush left, like `\\documentclass[fleqn]` in LaTeX.\" | `boolean` | `false` |\n| `throwOnError` | \"If `true` (the default), KaTeX will throw a `ParseError` when it encounters an unsupported command or invalid LaTeX. If `false`, KaTeX will render unsupported commands as text, and render invalid  LaTeX as its source code with hover text giving the error, in the color  given by `errorColor`.\" | `boolean` | `false` |\n| `color`        | The color of the TeX rendered in the MathView. | `Color` | `black` |\n| `colorBackground` | The background color of the MathView. | `Color` | `white` |\n| `colorError`   | A color that determines the color that unsupported commands and invalid LaTeX are rendered in when `throwOnError` is set to `false`. | `Color` | `#c00`  |\n| `fontSize`   | The font size of the rendered TeX string. | `Integer` | `16`  |\n\n\u003e Descriptions are partially quoted from the [KaTeX Docs][katex-docs].\n\n\n\n\u003c!-- ROADMAP --\u003e\n\n## Roadmap\n\nHere's a list of additions that are planned for the future:\n\n1. Support for iOS\n2. Support for Flutter Web\n3. Interactive MathView\n4. MathInput, that checks the TeX input for correctness and offers typing support\n\nSee the [open issues][issues] for a list of proposed features (and known issues).\n\n\n\n\u003c!-- CONTRIBUTING --\u003e\n## Contributing\n\nContributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are **greatly appreciated**.\n\n1. Fork the Project\n2. Create your Feature Branch (`git checkout -b feature/AmazingFeature`)\n3. Commit your Changes (`git commit -m 'Add some AmazingFeature'`)\n4. Push to the Branch (`git push origin feature/AmazingFeature`)\n5. Open a Pull Request\n\n\n\n\u003c!-- LICENSE --\u003e\n## License\n\nDistributed under the BSD 3-Clause License. See `LICENSE` for more information.\n\n\n\n\u003c!-- CONTACT --\u003e\n## Contact\n\nIf you have any questions, feel free to contact [Leon Staufer][email].\n\nProject Link: [https://github.com/LeonStaufer/fluttex][project]\n\n## Disclaimer\n\n\u003e This plugin has been developed independently from and is not endorsed by Google. Flutter, and the Flutter logo are registered trademarks owned by the Google.\n\n\n\u003c!-- MARKDOWN LINKS \u0026 IMAGES --\u003e\n[product-screenshot]: assets/screenshot.jpg\n[project]: https://github.com/LeonStaufer/fluttex\n[issues]: https://github.com/LeonStaufer/fluttex/issues\n[email]: mailto:leon@staufer.me\n[katex]: https://katex.org/\n[katex-docs]: https://katex.org/docs/options.html\n[textools]: https://github.com/LeonStaufer/TeXTools\n","funding_links":[],"categories":["Dart"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FLeonStaufer%2Ffluttex","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FLeonStaufer%2Ffluttex","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FLeonStaufer%2Ffluttex/lists"}