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 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:
    - 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.
  • 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"]
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.2.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.2-py3-none-any.whl (8.3 kB view details)

Uploaded Python 3

File details

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

File metadata

File hashes

Hashes for texsmith_fragment_heig_logo-0.0.2.tar.gz
Algorithm Hash digest
SHA256 306e9c8f99f590df25b4404511bf5a6a65f4ee4079afe5bb91154dfebaed6735
MD5 e3e47703a0986906ec2948534d61e1dd
BLAKE2b-256 aa896784794f78b4804796d5eb6530209b7a932bd4fcc5bb8332d0ad0b4d8a3b

See more details on using hashes here.

Provenance

The following attestation bundles were made for texsmith_fragment_heig_logo-0.0.2.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.2-py3-none-any.whl.

File metadata

File hashes

Hashes for texsmith_fragment_heig_logo-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 1c798af96c40bf3516736df177633a073f697ad7d2d53d99b221271f83bd3d93
MD5 ebfff75cdb2a45c664f695ef5e44cda0
BLAKE2b-256 46e62b2701b40233a339f618ebacdc7d2fda7b9ca5387ef42dec06564972d5bb

See more details on using hashes here.

Provenance

The following attestation bundles were made for texsmith_fragment_heig_logo-0.0.2-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