Download the PHP package dskripchenko/php-pdf-fonts-liberation without Composer

On this page you can find all versions of the php package dskripchenko/php-pdf-fonts-liberation. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package php-pdf-fonts-liberation

dskripchenko/php-pdf-fonts-liberation

Liberation font family bundle for dskripchenko/php-pdf — ships 12 TTFs (Sans / Serif / Mono × Regular / Bold / Italic / Bold Italic) and a ready-to-use FontProvider implementation.

🌐 English · 中文

Tests Packagist Total Downloads


Why a separate package

dskripchenko/php-pdf is MIT-licensed. The Liberation fonts ship under the SIL Open Font License (OFL) 1.1, which is permissive and GPL-compatible but distinct from MIT (different naming rules for derivatives, different redistribution clauses). Keeping fonts in a separate package:

What's bundled

Liberation Fonts 2.1.5 (latest stable), 12 files in assets/fonts/:

Family Variants
LiberationSans Regular, Bold, Italic, BoldItalic
LiberationSerif Regular, Bold, Italic, BoldItalic
LiberationMono Regular, Bold, Italic, BoldItalic

The Liberation family is metric-compatible with Microsoft's proprietary fonts — text laid out for Arial / Times New Roman / Courier New will render with the same line wrapping using the Liberation equivalent, so DOCX-input → PDF and HTML-templates → PDF workflows produce identical pagination.

Glyph coverage: full Latin (Western and Eastern European), Cyrillic, Greek, Hebrew, Arabic, and Devanagari basics.

Installation

PHP 8.2+. No native extensions required.

Usage

Microsoft name aliasing

LiberationFontProvider resolves common proprietary names to their metric-compatible Liberation equivalent automatically:

Requested name Resolved to
Arial LiberationSans
Arial-Bold LiberationSans-Bold
Times New Roman LiberationSerif
Times New Roman-Italic LiberationSerif-Italic
Courier New LiberationMono

A template that says font-family: "Times New Roman" works out of the box.

Combining with system or custom fonts

Use Dskripchenko\PhpPdf\Font\ChainedFontProvider to stack providers so Liberation acts as a fallback for missing glyphs:

License

This package mixes two licenses:

Zone License
src/ (PHP wrapper) MIT — see LICENSE
assets/fonts/ TTFs SIL OFL 1.1 — see OFL.txt

Both are permissive, GPL-compatible, and allow commercial use.

Attribution

Liberation Fonts © Red Hat, Inc., Pavel Hlaváč, and others. Upstream: https://github.com/liberationfonts/liberation-fonts


All versions of php-pdf-fonts-liberation with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
dskripchenko/php-pdf Version ^1.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package dskripchenko/php-pdf-fonts-liberation contains the following files

Loading the files please wait ...