Skip to main content

TeXSmith fragment that drops the HEIG-VD logo on the first page of a document.

Project description

TeXSmith Fragment - HEIG-VD Logo

A TeXSmith fragment that drops the HEIG-VD letterhead logo on the first page of a document.

Install

uv add texsmith-fragment-heig-logo
# or
pip install texsmith-fragment-heig-logo

The package registers a ts-heiglogo fragment via the texsmith.fragments entry-point group, so TeXSmith picks it up automatically — no path configuration needed.

Usage

In your document's YAML front matter (or in texsmith.yaml), append the fragment to the rendering pipeline:

fragments:
  append:
    - ts-heiglogo
heiglogo:
  color: false   # set to true for the red HEIG-VD logo

The logo is positioned 1 cm from the top-left of the page on every page of the document.

Attributes

Attribute Default Description
heiglogo.color false Render the logo in HEIG-VD red (e1251b) instead of black.

Requirements

  • TeXSmith ≥ 0.3.0
  • A LaTeX engine with xelatex or lualatex (the bundled heiglogo.sty uses fontspec and refuses pdflatex).
  • The TeX Gyre Heros font family (already present in standard TeX Live distributions).

How it works

The package ships three files under src/texsmith_fragment_heig_logo/fragment/:

  • fragment.toml — declares the fragment to TeXSmith and exposes the heiglogo_color attribute.
  • heiglogo.sty — the docstrip-generated LaTeX package.
  • ts-heiglogo.jinja.tex — a one-line Jinja template that calls \AddToShipoutPictureBG*{\logo[...]}.

The package's __init__.py exports a FRAGMENT_PATH constant. The pyproject.toml declares it as the entry point:

[project.entry-points."texsmith.fragments"]
ts-heiglogo = "texsmith_fragment_heig_logo:FRAGMENT_PATH"

When TeXSmith starts, its FragmentRegistry._discover_entry_points() scans the texsmith.fragments group, loads each entry, and registers the fragment directory as if it were built-in.

Regenerating heiglogo.sty from upstream

heiglogo.sty is a generated artefact; the canonical sources live at HEIG-VD/logos as a .dtx file. To refresh the bundled copy:

git clone https://github.com/HEIG-VD/logos
cd logos/heig-vd/latex
latex heiglogo.dtx
cp heiglogo.sty <this-repo>/src/texsmith_fragment_heig_logo/fragment/heiglogo.sty

Bump the package version and commit.

Licence

  • The wrapper code (Python module, manifest, Jinja template, build configuration) is released under the MIT license — see LICENSE.
  • The bundled heiglogo.sty file is distributed under the LaTeX Project Public License (LPPL) 1.3c or later — see LICENSE-LPPL and the upstream repository.

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

texsmith_fragment_heig_logo-0.0.1.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

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

texsmith_fragment_heig_logo-0.0.1-py3-none-any.whl (8.3 kB view details)

Uploaded Python 3

File details

Details for the file texsmith_fragment_heig_logo-0.0.1.tar.gz.

File metadata

File hashes

Hashes for texsmith_fragment_heig_logo-0.0.1.tar.gz
Algorithm Hash digest
SHA256 24748b8c846745b07955ff3d9d1df199211c2d63b6fb95d2de0de558c6143edb
MD5 2ce47b5888e232a60c01fd0f8450e69a
BLAKE2b-256 fdcb94a4d90d2662c935d1a77dd69be737d51998bc47d8094bb7e5251f144a5e

See more details on using hashes here.

Provenance

The following attestation bundles were made for texsmith_fragment_heig_logo-0.0.1.tar.gz:

Publisher: ci.yml on yves-chevallier/texsmith-fragment-heig-logo

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

File details

Details for the file texsmith_fragment_heig_logo-0.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for texsmith_fragment_heig_logo-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e58e837f2cb1bd51b8068212d7349575a854a5fbc12b647c1eeda3fdc3df9d76
MD5 5e2449fc32e92f3dfd07f86668123a5b
BLAKE2b-256 040cbf23e2909e675521212f266645984c848d3d77efbea9ccd860bbca37fbe2

See more details on using hashes here.

Provenance

The following attestation bundles were made for texsmith_fragment_heig_logo-0.0.1-py3-none-any.whl:

Publisher: ci.yml on yves-chevallier/texsmith-fragment-heig-logo

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