Skip to main content

Python library for defining and styling Excel table ranges as objects, built on top of openpyxl.

Project description

ExcelTableKit

PyPI version Python versions License: MIT CI PyPI downloads

A declarative abstraction layer over openpyxl that simplifies styling Excel tables in .xlsx files. Define cell ranges as table objects and apply colors, fonts, borders, and alignment without touching PatternFill, Border, Side, or any other low-level openpyxl construct directly.

Installation

pip install exceltablekit

Requirements: Python >= 3.10

Quick start

Python

from exceltablekit.excel import ExcelManager, ExcelStyle

excel = ExcelManager("report.xlsx")
excel.set_table("A1", "D10")
excel.define_header(rows=1)

styles = ExcelStyle(excel)
styles.set_background("E8F4FD")
styles.set_font(type="Arial", size=11)
styles.set_alignment(horizontal="center", vertical="center")
styles.set_border()

styles.set_header_background("1F4E79")
styles.set_header_font(bold=True, hex_color="FFFFFFFF")
styles.set_header_border()
styles.auto_fit_columns()

CLI

# Apply default styling to a table range
exceltablekit style report.xlsx --start A1 --end D10 --header-rows 1

# Custom colors and border style
exceltablekit style report.xlsx --start A1 --end D10 \
  --bg "E8F4FD" --header-bg "1F4E79" --border-style thin

# Show installed versions
exceltablekit info

Documentation

Full API reference and guides at exceltablekit.readthedocs.io (coming soon).

License

MIT — Angyee Marin

Project details


Download files

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

Source Distribution

exceltablekit-2.0.0.tar.gz (14.4 kB view details)

Uploaded Source

Built Distribution

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

exceltablekit-2.0.0-py3-none-any.whl (16.5 kB view details)

Uploaded Python 3

File details

Details for the file exceltablekit-2.0.0.tar.gz.

File metadata

  • Download URL: exceltablekit-2.0.0.tar.gz
  • Upload date:
  • Size: 14.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for exceltablekit-2.0.0.tar.gz
Algorithm Hash digest
SHA256 483cc47b1cfed6d46c9b3c235ec19e43f3b2d70ce643a108fc19f342b0bad10b
MD5 1071cfbc3b76b49ade2951f355462344
BLAKE2b-256 809ce3b34417f15d8cb30509803dd6a024732c94c175d34cd2d3b60b35461c13

See more details on using hashes here.

Provenance

The following attestation bundles were made for exceltablekit-2.0.0.tar.gz:

Publisher: publish.yml on xanv754/ExcelTableKit

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file exceltablekit-2.0.0-py3-none-any.whl.

File metadata

  • Download URL: exceltablekit-2.0.0-py3-none-any.whl
  • Upload date:
  • Size: 16.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for exceltablekit-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b5ab1227f72323f5eda6771d986948c69e7364322da133d0925432e36f621771
MD5 67de7439131990b1f995d3fdd114a192
BLAKE2b-256 05f422c5b961fab9d81cc8da46f1129fa0b20dd59aea6816ff12c4eeaf7f46b4

See more details on using hashes here.

Provenance

The following attestation bundles were made for exceltablekit-2.0.0-py3-none-any.whl:

Publisher: publish.yml on xanv754/ExcelTableKit

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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