Skip to main content

LibreOffice Developer Tools

Project description

License Apache PyPI - Python Version PyPI - Wheel Github

OOO Development Tools (OooDev) is intended for programmers who want to learn and use the Python version of the LibreOffice API.

This allows Python to control and manipulate LibreOffice’s text, drawing, presentation, spreadsheet, and database applications, and a lot more (e.g. its spell checker, forms designer, and charting tools).

One of the aims is to develop utility code to help flatten the steep learning curve for the API. For example, The Lo class simplifies the steps needed to initialize the API (by creating a connection to a LibreOffice process), to open/create a document, save it, and close down LibreOffice.

Currently this project has been tested on LibreOffice in Windows and Linux (Ubuntu).

Advantages of Python

Macros are pieces of programming code that runs in office suites and helps automate routine tasks. Specifically, in LibreOffice API these codes can be written with so many programming languages thanks to the Universal Network Objects (UNO).

Since LibreOffice is multi-platform we can use our documents at different platforms like Mac, Windows, and Linux. So we need a cross-platform language to run our macros at different platforms.

Python has the advantage that it is cross-platform and can run inside the office environment as macros and outside office environment on the command line.

Python has a vast set libraries that can be used in a project, including Numpy and Numexpr which are excellent and powerful at numeric computation.

This makes Python and excellent choice with maximum flexibility.

Documentation

Read documentation

Installation

PIP

ooo-dev-tools PyPI

$ pip install ooo-dev-tools

Modules

Currently there are more than 4,000 classes in this framework.

Include modules:
  • Calc (Calc)

  • Write (Write)

  • Draw (LibreOffice Draw/Impress)

  • Forms (Support for building forms)

  • Dialogs (Build dialog forms)

  • GUI (Various GUI methods for manipulating LO Windows)

  • Lo (Various methods common to LO applications)

  • FileIO (File Input and Output for working with LO)

  • Format (Format Module — hundreds of classes — for Styling and modifying the many Documents and Sheets properties.)

  • Props (Various methods setting and getting the many properties of Office objects)

  • Info (Various method for getting information about LO applications)

  • Color (Various color utils)

  • DateUtil (Date Time utilities)

  • ImagesLo (Various methods for working with Images)

  • Props (Various methods for working with the many API properties)

  • Chart2 (charting)

  • Chart (charting)

  • Gallery (Methods for accessing and reporting on the Gallery)

  • Theme (Access to LibreOffice Theme Properties)

  • Units (Various unit methods and classes for passing different kinds of units in LibreOffice such as inches, millimeters, points, pixels.)

  • And more …

Future releases will add:
  • Base (LibreOffice Base)

  • Clip (clipboard support)

  • Mail (Mail service provider)

  • Print (Print service provider)

  • And more …

Inspiration

Much of this project is inspired by the work of Dr. Andrew Davison and the work on Java LibreOffice Programming

See LibreOffice Programming that aims to gradually explain this content in a python context.

Other

Figure 1: Calc Find and Replace Automation Example

Calc Find and Replace Automation

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ooo_dev_tools-0.9.4.tar.gz (1.6 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ooo_dev_tools-0.9.4-py3-none-any.whl (2.1 MB view details)

Uploaded Python 3

File details

Details for the file ooo_dev_tools-0.9.4.tar.gz.

File metadata

  • Download URL: ooo_dev_tools-0.9.4.tar.gz
  • Upload date:
  • Size: 1.6 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.2 CPython/3.9.7 Windows/10

File hashes

Hashes for ooo_dev_tools-0.9.4.tar.gz
Algorithm Hash digest
SHA256 134ef82e8a90754e36ee1acedecb26952fe67f9ec78617c9088a3e5b88565ce3
MD5 5fabef11855c2619bdaeb8b284793108
BLAKE2b-256 252fbf861cbc1f05bbf4621ee118e773f7671855c0298ebae29b9bc4a1ca9167

See more details on using hashes here.

File details

Details for the file ooo_dev_tools-0.9.4-py3-none-any.whl.

File metadata

  • Download URL: ooo_dev_tools-0.9.4-py3-none-any.whl
  • Upload date:
  • Size: 2.1 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.2 CPython/3.9.7 Windows/10

File hashes

Hashes for ooo_dev_tools-0.9.4-py3-none-any.whl
Algorithm Hash digest
SHA256 19935b684641aebab22f40fb8153994b41371a2e9f8067060caf9030b100630a
MD5 92e73382c81ef31a98c29d6773fb61c1
BLAKE2b-256 0c9c2bb4cf2fa66be668d085025f3a113c2fee0396d5333bfa3c918ba3a1709d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page