An open API service indexing awesome lists of open source software.

https://github.com/pharmaverse/rtflite

Lightweight RTF composer for Python. Specializes in precise formatting of production-quality tables and figures.
https://github.com/pharmaverse/rtflite

clinical-trials ectd pharmaverse reporting rtf

Last synced: 11 days ago
JSON representation

Lightweight RTF composer for Python. Specializes in precise formatting of production-quality tables and figures.

Awesome Lists containing this project

README

          

# rtflite

[![PyPI version](https://img.shields.io/pypi/v/rtflite)](https://pypi.org/project/rtflite/)
![Python versions](https://img.shields.io/pypi/pyversions/rtflite)
[![pharmaverse rtflite badge](http://pharmaverse.org/shields/rtflite.svg)](https://pharmaverse.org)
[![CI tests](https://github.com/pharmaverse/rtflite/actions/workflows/ci-tests.yml/badge.svg)](https://github.com/pharmaverse/rtflite/actions/workflows/ci-tests.yml)
[![Mypy check](https://github.com/pharmaverse/rtflite/actions/workflows/mypy.yml/badge.svg)](https://github.com/pharmaverse/rtflite/actions/workflows/mypy.yml)
[![Ruff check](https://github.com/pharmaverse/rtflite/actions/workflows/ruff-check.yml/badge.svg)](https://github.com/pharmaverse/rtflite/actions/workflows/ruff-check.yml)
[![Documentation](https://github.com/pharmaverse/rtflite/actions/workflows/docs.yml/badge.svg)](https://pharmaverse.github.io/rtflite/)
![License](https://img.shields.io/pypi/l/rtflite)

Lightweight RTF composer for Python.

Specializes in precise formatting of production-quality tables and figures. Inspired by [r2rtf](https://merck.github.io/r2rtf/).

## Installation

You can install rtflite from PyPI:

```bash
pip install rtflite
```

Or install the development version from GitHub:

```bash
git clone https://github.com/pharmaverse/rtflite.git
cd rtflite
python3 -m pip install -e .
```

### Optional dependencies - DOCX support

Some features in rtflite require additional dependencies.
To install rtflite with DOCX assembly support:

```bash
pip install rtflite[docx]
```

To add rtflite as a dependency with DOCX support for projects using uv:

```bash
uv add rtflite --extra docx
```

For rtflite developers, sync all optional dependencies with:

```bash
uv sync --all-extras
```

### Optional dependencies - LibreOffice

rtflite can convert RTF documents to PDF and DOCX using LibreOffice.
To enable this feature, install LibreOffice (free and open source, MPL license).

See the [converter setup
guide](https://pharmaverse.github.io/rtflite/articles/converter-setup/)
for detailed instructions.

## Contributing

We welcome contributions to rtflite. Please read the rtflite
[Contributing Guidelines](https://pharmaverse.github.io/rtflite/contributing/)
to get started.

All interactions within rtflite repositories and issue trackers should adhere to
the rtflite [Contributor Code of Conduct](https://github.com/pharmaverse/rtflite/blob/main/CODE_OF_CONDUCT.md).

## License

This project is licensed under the terms of the MIT license.