Skip to content

Releases: pharmaverse/rtflite

rtflite 1.0.0

07 Aug 20:32
b53b64e
Compare
Choose a tag to compare

This major release marks rtflite as production-ready for table, listing, and figure generation in RTF format. It introduces advanced pagination features, enhanced group handling, complete color support, and significant architectural improvements for better maintainability and performance.

New features

  • Advanced pagination features

    • Added the subline_by parameter for creating paragraph headers before each page group.
    • Enhanced group_by functionality with hierarchical value suppression within groups.
    • Implemented page context restoration for multi-page tables with group_by.
  • Enhanced color system

    • Complete 657-color support with full r2rtf R package compatibility.
  • Text conversion improvements

    • Text conversion (LaTeX to Unicode) enabled by default for all components.
    • Better handling of special characters and symbols.
    • Enhanced validation for text conversion operations.
  • Table formatting

    • Added the as_table parameter for RTFFootnote and RTFSource components.
    • Auto-inheritance of col_rel_width from rtf_body to rtf_column_header.
    • Improved handling of table borders and footnote placement.

Architecture improvements

  • Service-oriented architecture

    • Introduced dedicated service layer for complex operations.
    • Implemented strategy pattern for encoding (SinglePageStrategy, PaginatedStrategy).
    • Created RTFEncodingEngine for strategy orchestration.
  • Code organization

    • Consolidated constants and eliminated magic numbers throughout the codebase.
    • Method decomposition and improved input validation.
    • Cleaner public interfaces with thorough error handling.

Dependency changes

  • Removed numpy and pandas as hard dependencies.
  • Moved pyarrow to development dependencies.
  • Now uses narwhals for DataFrame abstraction.
  • Prefer polars as the primary DataFrame interface.

Documentation

  • Added vignette-style articles to document the new features.
  • Reorganized API reference for better user experience.
  • Renamed documentation files to use hyphens consistently.
  • Updated all examples to use modern best practices.
  • Fixed Polars DataOrientationWarning in documentation examples.

Testing

  • Added single-page RTF tests with fixtures generated by r2rtf.
  • Added extensive multi-page tests for the as_table feature.

rtflite 0.1.3

05 Apr 00:00
5f9978f
Compare
Choose a tag to compare

Documentation

  • Add contributing guidelines to make it easy for onboarding new developers to the recommended development workflow (#25).
  • Update README.md to add hyperlink to the R package r2rtf (#24).

Maintenance

  • Remove the strict version requirement for the devlopment dependency mkdocs-autorefs (#21).

rtflite 0.1.2

24 Feb 02:08
1a248bf
Compare
Choose a tag to compare

Maintenance

  • Manage project with uv (#19).
  • Update the logo image generation workflow to use web fonts (#18).

rtflite 0.1.1

01 Feb 02:51
e4c3e79
Compare
Choose a tag to compare

Documentation

  • Use absolute URL to replace relative path for logo image in README.md, for proper rendering on PyPI (#16).

rtflite 0.1.0

29 Jan 17:00
573c841
Compare
Choose a tag to compare

New features

  • Introduced core RTF document components, such as RTFDocument, RTFPage, RTFTitle, RTFColumnHeader, and RTFBody. These classes establish the foundation for composing structured RTF documents with a text encoding pipeline. Use Pydantic for data validation.
  • Implemented string width calculation using Pillow with metric-compatible fonts. This will be incorporated in the pagination and layout algorithms in future releases.
  • Implemented a LibreOffice-based document converter for RTF to PDF conversion with automatic LibreOffice detection mechanisms under Linux, macOS, and Windows.

Documentation

  • Added an article on creating baseline characteristics tables.
  • Integrated code coverage reports via pytest-cov into the documentation site.