Skip to main content

LCG Framework

Tests

LCG is a Python framework for content abstraction and generic document processing. Documents are constructed as a hierarchy of Python objects. LCG defines standard content elements (paragraphs, sections, lists, formatted text, etc.) and advanced constructs (multimedia, mathematics, interactive widgets), and supports extensibility through third-party content elements. Content can be exported to multiple formats (HTML, PDF, Braille, IMS, EPUB, etc.) and imported from various source formats (text markup, internal serialization, etc.).

LCG is primarily intended for software developers who need to programmatically build structured documents or import them from different sources and export them to multiple formats. Documents can contain generic content elements (defined by LCG) or custom elements (defined by the developer). LCG can also be used directly by end-users to process documents written in a simple, human-readable source format into various target formats (such as HTML or PDF).

Key Features

  • Separation of content and presentation: Keeps structure and formatting independent.
  • Multimedia and interactive content: Supports rich, dynamic elements.
  • Accessibility: Designed for users of assistive technologies.
  • Extensibility: Easily define new content elements or customize output for existing elements.
  • Standards compliance: Adheres to relevant standards, notably W3C specs.
  • Internationalization: Supports multiple language variants in one document and mixed-language content.

License

LCG is Free Software, distributed under the terms of the GNU General Public License v2 (GPLv2). See the COPYING file for details.

History

LCG stands for Learning Content Generator. It was initially developed to generate online e-learning material for the Eurochance project.

Changelog

For a history of changes in each version, see the changelog.

Installation

LCG is a pure Python library running on Python 2.7 or Python 3.5 or later and may be installed by pip install lcg-framework[all].

When using PDF output, you additionally need the following system packages:

  • Fontconfig (Debian/Ubuntu package fontconfig)
  • Freefont (Debian/Ubuntu package fonts-freefont-ttf or ttf-freefont)

Usage

LCG comes with a command line tool which can be run directly using python -m lcg.make to build and export documents into different output formats. Run with --help to find out how to use it.

LCG is also used as a content abstraction layer in the Wiking web application development framework and for document construction and as a print backend in Pytis information systems development framework.

Documentation

The documentation is published at cerha.github.io/lcg.

Its source is also included in the package. To generate the HTML version locally, run make doc from the package root directory.

Metadata

Release files for lcg-framework 0.8.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for lcg-framework 0.8.2
File Size Uploaded Provenance Actions
lcg_framework-0.8.2.tar.gz 21.5 MB Without provenance Details for lcg_framework-0.8.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for lcg-framework 0.8.2
File Interpreter ABI Platform Actions
lcg_framework-0.8.2-py2.py3-none-any.whl Python 3, Python 2 none any Details for lcg_framework-0.8.2-py2.py3-none-any.whl

Total release size: 32.5 MB

Release files / lcg_framework-0.8.2.tar.gz

Download URL lcg_framework-0.8.2.tar.gz
Size 21.5 MB
Tags Source
SHA-256 checksum
How to use checksums
f0392f2dc7f25f3d80b66baaf339208d771da17b1c1b1d4187ab4e407a79c32b
BLAKE2b-256 checksum
How to use checksums
57d7316feb876fe4bfa775890bc3e507fe05e6b3922bddbe4c6b1bc59be989c8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.10.12

Release files / lcg_framework-0.8.2-py2.py3-none-any.whl

Download URL lcg_framework-0.8.2-py2.py3-none-any.whl
Size 11.0 MB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
c35e7f72a559720662054671ce913197597a7a81fe25b7d10611efd1b548c741
BLAKE2b-256 checksum
How to use checksums
5927336a1b2559d1a220d2073699da30e20fee1e1f942ab36f58285dccba0676
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.10.12

Security for lcg-framework 0.8.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page