# Signes de logique et d’ensembles par une police des symboles

> Un manuel de logique dans des polices sans ∀, ∈ ni ℵ : symbolFont désigne Noto Sans Math, qui dessine ces signes et le grec sur le canevas et dans le PDF.

- Version HTML: https://postext.dev/fr/cookbook/symbol-font-for-logic
- Recette Nº 185 · Caractères et texte · Niveau 2 (Intermédiaire) · Sorties: Canvas, PDF
- Genres: Manuels scolaires
- Nécessite postext ≥ 1.73.0, postext-pdf ≥ 1.73.0 · testée avec 1.73.0, postext-pdf 1.73.0 le 2026-11-10
- Pages: [1](https://postext.dev/cookbook/symbol-font-for-logic/en/p01.webp?v=20f21fc7), [2](https://postext.dev/cookbook/symbol-font-for-logic/en/p02.webp?v=20f21fc7), [3](https://postext.dev/cookbook/symbol-font-for-logic/en/p03.webp?v=20f21fc7), [4](https://postext.dev/cookbook/symbol-font-for-logic/en/p04.webp?v=20f21fc7)
- PDF: https://postext.dev/cookbook/symbol-font-for-logic/en/symbol-font-for-logic.pdf?v=20f21fc7
- Ouvrir dans le Sandbox: https://postext.dev/fr/sandbox#recipe=symbol-font-for-logic&lang=en (.postext: https://postext.dev/cookbook/symbol-font-for-logic/en/symbol-font-for-logic.postext)
- Dernière mise à jour: 2026-11-10
- Autres langues: [en](https://postext.dev/en/cookbook/symbol-font-for-logic.md), [es](https://postext.dev/es/cookbook/symbol-font-for-logic.md), [ca](https://postext.dev/ca/cookbook/symbol-font-for-logic.md), [de](https://postext.dev/de/cookbook/symbol-font-for-logic.md), [it](https://postext.dev/it/cookbook/symbol-font-for-logic.md), [pt](https://postext.dev/pt/cookbook/symbol-font-for-logic.md), [zh](https://postext.dev/zh/cookbook/symbol-font-for-logic.md), [ja](https://postext.dev/ja/cookbook/symbol-font-for-logic.md), [ar](https://postext.dev/ar/cookbook/symbol-font-for-logic.md)

## En bref

Un court chapitre qui apprend à lire les signes de la logique et de la théorie des ensembles. Les polices du livre n’ont pas ces signes : une seconde police les fournit, à l’écran et dans le PDF imprimé.

## Ce que vous allez composer

Le premier chapitre d’un petit manuel de logique, sur une page de 155 × 235 mm : un bandeau grenat où les signes du chapitre sont composés en grand, puis quatre sections qui lisent à voix haute ∀, ∃, ∈, ∪, ∅ et ℵ, avec les formules dans le texte courant et détachées entre les paragraphes. Le livre est composé en Crimson Pro, ses titres en Cormorant Garamond et ses étiquettes en IBM Plex Sans Condensed. Aucune des trois n’a ∀, ∈ ni de lettre grecque dans les fichiers que sert Fontsource. Un seul réglage, `symbolFont`, place Noto Sans Math derrière chacune : tous les signes viennent de la même police dans le texte, les titres, les titres courants et les cellules des tableaux, et le PDF les imprime tous.

**Cette recette répond à:**

- Comment imprimer les signes de logique (∀, ∈, ℵ) et le grec que ma police n’a pas, sans cases vides ?

## La réponse courte

```js
// script.js, lignes 34–47
// None of the three faces has ∀, ∈, ℵ or Greek. config.symbolFont (below) lists Noto Sans
// Math after every family the document names: what a face lacks is drawn from it, at the
// face's size and colour, in the canvas, the PDF, the HTML and the EPUB.
const SYMBOLS = 'Noto Sans Math';
// Fontsource serves Noto Sans Math whole in its "latin" file, and the kit would declare
// that file for the Latin range only. The screen and the PDF take it here with no range,
// so every glyph in it can be used.
const symbolFile = async () =>
  `${await fontsourceAt('noto-sans-math')}files/noto-sans-math-latin-400-normal.woff2`;
const resolve = async (family, ...face) =>
  (family === SYMBOLS ? [{ source: await symbolFile() }] : fontsourceResolver(family, ...face));
const pdfFonts = async (family, ...face) => (family !== SYMBOLS
  ? fontsourceProvider(family, ...face)
  : decompressWoff2(new Uint8Array(await (await fetch(await symbolFile())).arrayBuffer())));
```

## Ingrédients

**Enseigne**

- [Police des symboles](https://postext.dev/fr/docs/configuration-fonts-colors-viewers.md#police-des-symboles): symbolFont désigne une famille qui dessine les caractères absents des polices du document (signes de logique et d’ensembles, grec, flèches) sur le canevas, dans le PDF, le HTML et l’EPUB, au lieu d’une police du système ou d’une case vide.
- [Polices intégrées au PDF](https://postext.dev/fr/docs/configuration-pdf-output.md#pourquoi-un-fournisseur-de-polices): Un fournisseur de polices remet à renderToPdf les octets TrueType statiques de chaque caractère mesuré par la mise en page, si bien que le PDF compose exactement les mêmes lignes.

**Utilise aussi**

- [Les polices avant la mise en page](https://postext.dev/fr/docs/configuration-programmatic-usage.md#charger-les-polices-avant-la-mise-en-page)
- [Exposants et indices](https://postext.dev/fr/docs/document-format-inline.md#mise-en-forme-en-ligne)
- [Styles de paragraphe](https://postext.dev/fr/docs/configuration-styles.md#styles-de-paragraphe)
- [Tableaux à partir de données](https://postext.dev/fr/docs/document-format-resources.md#insertion-en-bloc-facultative-placement-explicite-dans-le-texte)
- [Style de tableau](https://postext.dev/fr/docs/configuration-resources.md#style-de-tableau)
- [Ouvertures composées](https://postext.dev/fr/docs/configuration-headings.md#étendue-et-maquette-avancée)
- [Attributs de titre](https://postext.dev/fr/docs/document-format.md#attributs-de-titre)
- [Titres courants et folios](https://postext.dev/fr/docs/configuration-headers-footers.md#en-têtes-et-pieds-de-page)
- [Marges en miroir](https://postext.dev/fr/docs/configuration-page-layout.md#marges-en-miroir)
- [Palette de couleurs sémantique](https://postext.dev/fr/docs/configuration-fonts-colors-viewers.md#palette-de-couleurs)
- [Export PDF](https://postext.dev/fr/docs/configuration-pdf-output.md#générer-des-pdf)
- [Des figures exactement ici](https://postext.dev/fr/docs/document-format-resources.md#insertion-en-bloc-facultative-placement-explicite-dans-le-texte)
- [Figure et Tableau dans votre langue](https://postext.dev/fr/docs/configuration-resources.md#types-de-ressources)
- [Titres courants selon le rôle de la page](https://postext.dev/fr/docs/configuration-headers-footers.md#éléments-de-texte)
- [Types de ressource personnalisés](https://postext.dev/fr/docs/configuration-resources.md#types-de-ressources)

**La configuration en un coup d’œil**

- [`bodyText`](https://postext.dev/fr/docs/configuration-text.md#texte-courant), [`captionStyle`](https://postext.dev/fr/docs/configuration-resources.md#style-de-légende), [`colorPalette`](https://postext.dev/fr/docs/configuration-fonts-colors-viewers.md#palette-de-couleurs), [`footer`](https://postext.dev/fr/docs/configuration-headers-footers.md#en-têtes-et-pieds-de-page), [`header`](https://postext.dev/fr/docs/configuration-headers-footers.md#en-têtes-et-pieds-de-page), [`headings`](https://postext.dev/fr/docs/configuration-headings.md#titres), [`layout`](https://postext.dev/fr/docs/configuration-page-layout.md#mise-en-page), [`locale`](https://postext.dev/fr/docs/configuration-language.md#césure), [`page`](https://postext.dev/fr/docs/configuration-page-layout.md#page), [`paragraphStyles`](https://postext.dev/fr/docs/configuration-styles.md#styles-de-paragraphe), [`resourceTypes`](https://postext.dev/fr/docs/configuration-resources.md#types-de-ressources), [`symbolFont`](https://postext.dev/fr/docs/configuration-fonts-colors-viewers.md#police-des-symboles), [`tableStyle`](https://postext.dev/fr/docs/configuration-resources.md#style-de-tableau)

**API**

- [`buildDocumentWithFonts`](https://postext.dev/fr/docs/configuration-programmatic-usage.md#charger-les-polices-avant-la-mise-en-page), [`decompressWoff2`](https://postext.dev/fr/docs/configuration-pdf-output.md#fournisseur-de-polices-dans-le-navigateur-fontsource--woff2), [`defaultResourceTypes`](https://postext.dev/fr/docs/configuration-resources.md#types-de-ressources), `formatWarning`, [`parseTSV`](https://postext.dev/fr/docs/document-format-resources.md#insertion-en-bloc-facultative-placement-explicite-dans-le-texte), [`renderPageToCanvas`](https://postext.dev/fr/docs/configuration-programmatic-usage.md#rendre-une-page-en-bitmap), [`renderToPdf`](https://postext.dev/fr/docs/configuration-pdf-output.md#générer-des-pdf)

**Caractères**

- Crimson Pro (OFL-1.1), Cormorant Garamond (OFL-1.1), IBM Plex Sans Condensed (OFL-1.1), Noto Sans Math (OFL-1.1)

## Préparation

### 1 · Une police des symboles derrière toutes les autres

Le code de cette étape est la réponse courte, plus haut. `symbolFont: 'Noto Sans Math'` ([police des symboles](https://postext.dev/fr/docs/configuration-fonts-colors-viewers.md#police-des-symboles)) place cette famille derrière toutes celles que nomme la configuration : un caractère absent de la police est dessiné en Noto Sans Math, au corps et dans la couleur de la police, et le reste de la ligne garde la sienne. Fontsource sert Noto Sans Math entière dans son fichier `latin`, soit 3 033 caractères, mais le kit déclare ce fichier pour la seule plage latine, et le navigateur ne lui demanderait pas ∀. Le `resolve` et le `pdfFonts` de la recette transmettent le même fichier sans plage, à l’écran et à `renderToPdf`. Seuls les caractères manquants changent de police : Crimson Pro a ¬, la négation du texte reste donc en Crimson Pro.

### 2 · Une première composition sans elle montre ce qui manque

```js
// script.js, lignes 243–250
// Each paragraph that sets a character its face lacks is a glyphFallbackAt warning with its
// page; with no symbol font it names no family that draws them, and the PDF would print
// empty boxes. The pages shown are the second build's.
const fonts = { ...kitFonts(FONTS), resolve }; // the kit's resolver, with the symbol file
const bare = await buildDocumentWithFonts({ markdown, resources }, { ...config, symbolFont: '' },
  fonts);
console.info((bare.contentWarnings ?? []).filter((w) => w.kind === 'glyphFallbackAt')
  .map(formatWarning).join('\n'));
```

La première composition laisse `symbolFont` vide et affiche ses avertissements `glyphFallbackAt`, un par paragraphe, titre ou tableau qui contient des caractères sans glyphe dans sa police, avec la page et les caractères. L’édition anglaise en compte dix-huit : quatorze paragraphes en Crimson Pro, trois titres en Cormorant Garamond et la ligne d’en-tête du tableau 1.1 en IBM Plex Sans Condensed gras. Sans famille pour les dessiner, le canevas prend les signes dans une police du système du lecteur et le PDF imprime une case vide pour chacun. La seconde composition, avec la police des symboles, est celle qu’on voit sur la page ; ses avertissements nomment `"Noto Sans Math"` comme la famille qui les dessine.

### 3 · Les signes de l’ouverture sont du texte

```js
// script.js, lignes 51–67
const BAND = 78; // mm from the trim to the foot of the band
const onBand = { color: col('paper'), align: 'left' };
const below = (id, y, width) => ({ anchor: { to: `#${id}`, edge: 'below' }, offset: { y: mm(y) },
  size: { width: mm(width) } });
const opener = { enabled: true, minHeight: mm(BAND - TOP + 2), slot: { elements: [
  { kind: 'box', id: 'band', style: { backgroundColor: col('accent') },
    placement: { anchor: { to: 'bleed', edge: 'top-left' }, size: { height: mm(BAND) } } },
  { kind: 'text', id: 'kicker', content: '{attr.kicker}', ...onBand, fontFamily: LABEL,
    fontWeight: 600, fontSize: pt(8.5), letterSpacing: pt(1.8), textTransform: 'uppercase',
    placement: { anchor: { to: 'container', edge: 'top-left' }, offset: { y: mm(2) } } },
  { kind: 'text', id: 'title', content: '{titleText}', ...onBand, fontFamily: DISPLAY,
    fontWeight: 600, fontSize: pt(38), lineHeight: 1.02, placement: below('kicker', 3, 110) },
  // The signs are text in Cormorant Garamond, which has none of them: Noto Sans Math draws
  // every one, at 30 pt, in the band's white.
  { kind: 'text', id: 'signs', content: '{attr.signs}', ...onBand, fontFamily: DISPLAY,
    fontSize: pt(30), lineHeight: 1, letterSpacing: pt(9), placement: below('title', 7, 114) },
] } };
```

La ligne de sept signes sous le titre est un texte de maquette en Cormorant Garamond à 30 pt, nourri par l’attribut `signs` du titre. Cormorant Garamond n’en a aucun : les sept viennent de la police des symboles, dans le blanc du bandeau. Une approche de 9 pt les répartit sur la justification.

### 4 · Cellules et titres courants prennent la même police

```js
// script.js, lignes 212–230
const [T, F] = t({ en: ['T', 'F'], es: ['V', 'F'] });
const connectives = [['¬*p*', (p) => !p], ['*p* ∧ *q*', (p, q) => p && q],
  ['*p* ∨ *q*', (p, q) => p || q], ['*p* → *q*', (p, q) => !p || q],
  ['*p* ↔ *q*', (p, q) => p === q]];
const cell = (content, isHeader = false) => ({ content, align: 'center', isHeader });
const truth = [[true, true], [true, false], [false, true], [false, false]].map(([p, q]) =>
  [p, q, ...connectives.map(([, f]) => f(p, q))].map((v) => cell(v ? T : F)));
const table = (id, rows, columnWidths, caption, position) => ({ id, typeId: 'table',
  kind: 'table', caption, createdAt: 0, updatedAt: 0, placement: { position },
  table: { model: { headerRowCount: 1, columnWidths, rows } } });
const resources = [
  table('truth', [['*p*', '*q*', ...connectives.map(([s]) => s)].map((s) => cell(s, true)),
    ...truth],
    [1, 1, 1.3, 1.6, 1.6, 1.6, 1.6], t({ en: 'The five connectives, row by row.',
      es: 'Las cinco conectivas, fila a fila.' }), 'top'), // to the head of a page
  table('signs', parseTSV(signs.trim()).rows.map((row, r) => row.map(({ content }, c) => ({
    content, align: c === 0 ? 'center' : 'left', isHeader: r === 0 }))), [0.8, 2.1, 5.3],
  t({ en: 'Where the signs come from.', es: 'De dónde vienen los signos.' }), 'here'),
];
```

La table de vérité est construite à partir des connecteurs eux-mêmes : l’en-tête de chaque colonne est la formule, et chaque cellule ce que la formule donne pour cette ligne. Les cellules d’en-tête sont en IBM Plex Sans Condensed gras italique et celles du corps en Crimson Pro ; la police des symboles sert les deux. Son unique style romain dessine pour toutes les graisses et toutes les pentes : le ∧ de l’en-tête en gras et le ∈ d’une formule en italique sont le même signe droit. Le titre courant de la belle page imprime la section en cours, `{firstMark.h2}`, et *SETS: ∈, ∪, ∩ AND ∅*, page 3, prend lui aussi ses signes dans Noto Sans Math.

![Page 3: Sets: ∈, ∪, ∩ and ∅.](https://postext.dev/cookbook/symbol-font-for-logic/en/p03.webp?v=20f21fc7)

*Page 3 : les formules d’ensembles, en Crimson Pro italique, tous les signes venant de Noto Sans Math.*

## La recette complète

Un seul fichier, composé à partir du dossier de la recette avec le texte d’exemple et le kit commun des Recettes déjà inclus ; il construit sa propre page. Pour l’exécuter, placez-le dans un `<script type="module">` d’une page vide ou collez-le dans le panneau JS d’un nouveau pen CodePen (en tant que module). Il importe postext depuis esm.sh : il n’y a rien à installer ni à compiler.

- Dossier de la recette: https://github.com/drnachio/postext/tree/main/cookbook/symbol-font-for-logic

### script.js

```js
// ═══ Postext Cookbook · Nº 185 · Logic signs from a symbol font ═════════════════════
// https://postext.dev/en/cookbook/symbol-font-for-logic
// Code: MIT · Text: original (CC BY 4.0) · Pictures: none
// Fonts: Crimson Pro, Cormorant Garamond, IBM Plex, Noto Sans Math (OFL) · Needs postext ≥ 1.73.0
// A primer of logical notation set in faces that have no ∀, no ∈, no ℵ and no Greek:
// symbolFont names Noto Sans Math, which draws those characters on the canvas and in the PDF.
import {
  buildDocumentWithFonts, renderPageToCanvas, defaultResourceTypes, parseTSV, formatWarning,
} from 'https://esm.sh/postext';
import { renderToPdf, decompressWoff2 } from 'https://esm.sh/postext-pdf';

const LANG = 'en'; // @lang: the language of the sample document ('en' | 'es')
const RECIPE = 'symbol-font-for-logic';

// ─── 1 · Design ─────────────────────────────────────────────────────────────
const palette = {
  ink: '#1f1c22', // text: a cool near-black
  accent: '#7b2a3b', // claret: the opener band, labels, the table heads
  tint: '#f4ece9', // the even rows of the truth table
  rule: '#c3b4b2', // hairlines
  muted: '#6a6064', // running heads, the colophon
  paper: '#ffffff',
};
const col = (id) => ({ hex: palette[id], model: 'hex', paletteId: id });
const colorPalette = [
  ...Object.entries(palette).map(([id, hex]) => ({ id, name: id, value: { hex, model: 'hex' } })),
  { id: 'main-color', name: 'accent (defaults)', value: { hex: palette.accent, model: 'hex' } },
];
const TEXT = 'Crimson Pro', DISPLAY = 'Cormorant Garamond', LABEL = 'IBM Plex Sans Condensed';
const TRIM = [155, 235], INNER = 20, OUTER = 21, TOP = 23; // mm: a trade-size primer
const LEAD = 15; // pt: the body leading

// #region answer: one symbol font behind every face, on the canvas and in the PDF
// None of the three faces has ∀, ∈, ℵ or Greek. config.symbolFont (below) lists Noto Sans
// Math after every family the document names: what a face lacks is drawn from it, at the
// face's size and colour, in the canvas, the PDF, the HTML and the EPUB.
const SYMBOLS = 'Noto Sans Math';
// Fontsource serves Noto Sans Math whole in its "latin" file, and the kit would declare
// that file for the Latin range only. The screen and the PDF take it here with no range,
// so every glyph in it can be used.
const symbolFile = async () =>
  `${await fontsourceAt('noto-sans-math')}files/noto-sans-math-latin-400-normal.woff2`;
const resolve = async (family, ...face) =>
  (family === SYMBOLS ? [{ source: await symbolFile() }] : fontsourceResolver(family, ...face));
const pdfFonts = async (family, ...face) => (family !== SYMBOLS
  ? fontsourceProvider(family, ...face)
  : decompressWoff2(new Uint8Array(await (await fetch(await symbolFile())).arrayBuffer())));
// #endregion

// #region opener: a claret band with the chapter's signs set large
const BAND = 78; // mm from the trim to the foot of the band
const onBand = { color: col('paper'), align: 'left' };
const below = (id, y, width) => ({ anchor: { to: `#${id}`, edge: 'below' }, offset: { y: mm(y) },
  size: { width: mm(width) } });
const opener = { enabled: true, minHeight: mm(BAND - TOP + 2), slot: { elements: [
  { kind: 'box', id: 'band', style: { backgroundColor: col('accent') },
    placement: { anchor: { to: 'bleed', edge: 'top-left' }, size: { height: mm(BAND) } } },
  { kind: 'text', id: 'kicker', content: '{attr.kicker}', ...onBand, fontFamily: LABEL,
    fontWeight: 600, fontSize: pt(8.5), letterSpacing: pt(1.8), textTransform: 'uppercase',
    placement: { anchor: { to: 'container', edge: 'top-left' }, offset: { y: mm(2) } } },
  { kind: 'text', id: 'title', content: '{titleText}', ...onBand, fontFamily: DISPLAY,
    fontWeight: 600, fontSize: pt(38), lineHeight: 1.02, placement: below('kicker', 3, 110) },
  // The signs are text in Cormorant Garamond, which has none of them: Noto Sans Math draws
  // every one, at 30 pt, in the band's white.
  { kind: 'text', id: 'signs', content: '{attr.signs}', ...onBand, fontFamily: DISPLAY,
    fontSize: pt(30), lineHeight: 1, letterSpacing: pt(9), placement: below('title', 7, 114) },
] } };
// #endregion

// #region running-heads: the book on the verso, the section on the recto
const head = (id, content, parity, edge, x, extra = {}) => ({
  kind: 'text', id, content, parity, pages: 'body', fontFamily: LABEL, fontSize: pt(7.5),
  fontWeight: 500, letterSpacing: pt(1.2), textTransform: 'uppercase', color: col('muted'),
  placement: { anchor: { to: 'page', edge }, offset: { x: mm(x), y: mm(13) } }, ...extra });
const folio = { fontWeight: 600, color: col('ink') };
const header = { elements: [
  head('verso-folio', '{pageNumber}', 'even', 'top-left', OUTER, folio),
  head('verso-title', '{title}', 'even', 'top-left', OUTER + 8),
  // A section title such as "Quantifiers: ∀ and ∃" takes its signs from the symbol font too.
  head('recto-title', '{firstMark.h2}', 'odd', 'top-right', -(OUTER + 8)),
  head('recto-folio', '{pageNumber}', 'odd', 'top-right', -OUTER, folio),
] };
const footer = { elements: [head('drop-folio', '{pageNumber}', 'all', 'top', 0, {
  ...folio, pages: 'opener',
  placement: { anchor: { to: 'container', edge: 'top' }, offset: { y: mm(9) } } })] };
// #endregion

const config = {
  locale: t({ en: 'en-us', es: 'es' }),
  symbolFont: SYMBOLS,
  resourceTypes: defaultResourceTypes(LANG),
  colorPalette,
  page: { sizePreset: 'custom', width: mm(TRIM[0]), height: mm(TRIM[1]), dpi: 150,
    margins: { top: mm(TOP), bottom: mm(22), left: mm(INNER), right: mm(OUTER), mirror: true } },
  layout: { layoutType: 'single' },
  bodyText: {
    fontFamily: TEXT, fontSize: pt(11), lineHeight: pt(LEAD), color: col('ink'),
    boldColor: col('ink'), italicColor: col('ink'), referenceColor: col('ink'),
    textAlign: 'justify', firstLineIndent: mm(4.5), indentAfterHeading: false,
    hyphenation: { enabled: true }, optimalLineBreaking: true,
    avoidWidows: true, avoidOrphans: true, avoidRunts: true,
  },
  headings: { fontFamily: DISPLAY, color: col('ink'), fontWeight: 600,
    levels: [
      { level: 1, fontSize: pt(38), breakBefore: { parity: 'odd' }, advancedDesign: opener,
        marginBottom: pt(0) },
      { level: 2, fontSize: pt(16), lineHeight: pt(LEAD * 1.2), color: col('accent'),
        marginTop: pt(LEAD), marginBottom: pt(LEAD * 0.3) },
    ] },
  paragraphStyles: [
    // Displayed formulas: centred, in the text face, a size up; the signs still come from
    // the symbol font, the italic variables from Crimson Pro.
    { id: 'formula', fontSize: pt(12), lineHeight: pt(LEAD * 1.2), textAlign: 'center',
      firstLineIndent: pt(0), hyphenation: { enabled: false } },
    { id: 'colophon', fontFamily: LABEL, fontSize: pt(7.5), lineHeight: pt(10),
      color: col('muted'), textAlign: 'left', firstLineIndent: pt(0), marginTop: pt(LEAD) },
  ],
  tableStyle: { rules: 'horizontal', borderColor: col('rule'), borderWidth: pt(0.5),
    headerBackground: col('accent'), headerColor: col('paper'), headerBold: true,
    headerFontFamily: LABEL, headerFontSize: pt(8.5), bodyFontFamily: TEXT,
    bodyFontSize: pt(10), bodyColor: col('ink'), cellPadding: mm(1.1) },
  captionStyle: { fontFamily: LABEL, fontSize: pt(8), color: col('ink'), labelBold: true,
    labelColor: col('accent'), note: { color: col('muted') } },
  header,
  footer,
};

// ─── 2 · Content ────────────────────────────────────────────────────────────
const markdown = String.raw`---
title: "A Pocket Primer of Logic"
author: "Ignacio Ferro"
---

# Reading the Signs {kicker="A pocket primer of logic · Chapter 1" signs="∀ ∃ → ∈ ∪ ∅ ℵ"}

A page of logic looks like a page of algebra that has lost its numbers. Its letters stand for sentences, for objects and for collections of objects, and a dozen signs hold them together. Most of those signs are younger than the telephone: Giuseppe Peano printed the first of the modern ones in 1889, and Gerhard Gentzen added the last of the common ones in 1935. This chapter reads them one at a time, in the order a first course meets them, and gives each its name in words, so that any formula can be read aloud as a sentence.

## Sentences and connectives

A letter such as *p* or *q* stands for a whole sentence that is either true or false: *it is raining*, *the train is late*. Five signs build longer sentences out of shorter ones. ¬*p* reads “not *p*” and is true exactly when *p* is false. *p* ∧ *q*, “*p* and *q*”, is true when both are. *p* ∨ *q*, “*p* or *q*”, is true when at least one is; the sign is a stylised *v*, for the Latin *vel*, the “or” that allows both. *p* → *q*, “if *p* then *q*”, is false in one case only, when *p* is true and *q* is false. *p* ↔ *q*, “*p* if and only if *q*”, is true when the two sides agree.

Table 1.1 sets the five side by side. Each row is one way the world could be, and each column is one sentence, read off from the two letters on the left.

::resource{id="truth"}

The table settles questions that intuition gets wrong. The third and fourth rows show that *p* → *q* is true whenever *p* is false, whatever *q* says: a promise whose condition was never met has not been broken. The table also proves De Morgan’s laws, which turn the negation of an “or” into an “and” of negations, and the other way round:

:::paragraphs{style="formula"}
¬(*p* ∨ *q*) ↔ (¬*p* ∧ ¬*q*) \
¬(*p* ∧ *q*) ↔ (¬*p* ∨ ¬*q*)
:::

## Quantifiers: ∀ and ∃

Sentence letters cannot see inside a sentence. *All humans are mortal* and *Socrates is human* share no letter, and yet together they give *Socrates is mortal*. Predicate logic splits a sentence into a predicate and the things it is said of: *Hx* for “*x* is human”, *Mx* for “*x* is mortal”, *s* for Socrates. Two quantifiers then say how many things a predicate holds of. ∀*x*, “for every *x*”, is an A turned upside down; ∃*x*, “there is an *x*”, is an E turned back to front.

:::paragraphs{style="formula"}
∀*x* (*Hx* → *Mx*) \
*Hs* → *Ms*
:::

The first line is the major premise of the oldest syllogism in the textbooks, and the second is what it says of Socrates in particular. The two quantifiers are tied together by negation. To deny that everything has a property is to say that something lacks it, and to deny that something has it is to say that everything lacks it:

:::paragraphs{style="formula"}
¬∀*x* φ ↔ ∃*x* ¬φ \
¬∃*x* φ ↔ ∀*x* ¬φ
:::

The Greek letters φ and ψ are not part of the formula language. Each stands for any formula at all, so each line above is a pattern with infinitely many instances. Logicians keep the Greek alphabet for this talk about formulas and the Latin one for the formulas themselves. A capital gamma, Γ, usually names a set of premises, and Γ ⊢ φ says that φ can be derived from them.

## Sets: ∈, ∪, ∩ and ∅

A set is a collection taken as one object. *a* ∈ *A* says that *a* is a member of *A*, and *a* ∉ *A* that it is not. *A* ⊆ *B* says that every member of *A* is a member of *B*; *A* ⊂ *B* adds that *B* has some member more. With the connectives and the quantifiers, each of these comes down to a sentence about members:

:::paragraphs{style="formula"}
*A* ⊆ *B* ↔ ∀*x* (*x* ∈ *A* → *x* ∈ *B*) \
*x* ∈ *A* ∪ *B* ↔ (*x* ∈ *A* ∨ *x* ∈ *B*) \
*x* ∈ *A* ∩ *B* ↔ (*x* ∈ *A* ∧ *x* ∈ *B*)
:::

The union ∪ is built on the “or” and the intersection ∩ on the “and”, and the shapes keep the kinship in view: ∪ opens upward like ∨, ∩ downward like ∧. The empty set ∅ has no members, ∀*x* (*x* ∉ ∅), and it is a subset of every set *A*, because the condition of ∀*x* (*x* ∈ ∅ → *x* ∈ *A*) is never met.

Not every condition defines a set. In June 1902 Bertrand Russell wrote to Gottlob Frege about the collection of all sets that are not members of themselves. Call it *R*. If *R* ∈ *R*, then *R* fails its own condition, so *R* ∉ *R*; if *R* ∉ *R*, it meets the condition, so *R* ∈ *R*. Frege’s system allowed *R*, and with it *R* ∈ *R* ↔ *R* ∉ *R*, a contradiction. The set theories taught today do not let such a collection be a set.

## Counting the infinite: ℵ

Two sets have the same size when their members can be paired off one to one. The natural numbers, ℕ, and the even numbers pair off by sending each *n* to 2*n*, so an infinite set can be as large as a part of itself. Georg Cantor denoted the size of ℕ by ℵ~0~, aleph-null, from the first letter of the Hebrew alphabet, and showed in 1891 that the real numbers cannot be paired off with ℕ: any list of them leaves one out. There are therefore at least two infinite sizes, and his alephs ℵ~0~, ℵ~1~, ℵ~2~ name them in order.

## Where the signs come from

The signs in this chapter came into print one at a time, from different hands; Table 1.2 names who put each of them into general use.

::resource{id="signs"}

:::paragraphs{style="colophon"}
Set in Crimson Pro, Cormorant Garamond and IBM Plex Sans Condensed, with the signs from Noto Sans Math (SIL Open Font License) · Text: original, CC BY 4.0.
:::
`; // content.<lang>.md, inlined by the Cookbook
const signs = String.raw`Sign	Read as	Put into use by
∈	is a member of	Giuseppe Peano, *Arithmetices principia*, 1889, as ε, for Greek *esti*, “is”
∪ ∩	union, intersection	Peano, *Calcolo geometrico*, 1888
∃	there is	Peano, *Formulaire de mathématiques*, volume II, 1897
ℵ	aleph	Georg Cantor, *Mathematische Annalen*, 1895
∨	or	Whitehead and Russell, *Principia Mathematica*, 1910
→	if … then	Hilbert and Ackermann, *Grundzüge der theoretischen Logik*, 1928
¬	not	Arend Heyting, on intuitionistic logic, 1930
∀	for every	Gerhard Gentzen, *Mathematische Zeitschrift*, 1935
∅	the empty set	André Weil, for Nicolas Bourbaki, 1939
`; // TSV: sign, read as, made current by

// #region tables: the truth table from the connectives themselves, the signs from TSV
const [T, F] = t({ en: ['T', 'F'], es: ['V', 'F'] });
const connectives = [['¬*p*', (p) => !p], ['*p* ∧ *q*', (p, q) => p && q],
  ['*p* ∨ *q*', (p, q) => p || q], ['*p* → *q*', (p, q) => !p || q],
  ['*p* ↔ *q*', (p, q) => p === q]];
const cell = (content, isHeader = false) => ({ content, align: 'center', isHeader });
const truth = [[true, true], [true, false], [false, true], [false, false]].map(([p, q]) =>
  [p, q, ...connectives.map(([, f]) => f(p, q))].map((v) => cell(v ? T : F)));
const table = (id, rows, columnWidths, caption, position) => ({ id, typeId: 'table',
  kind: 'table', caption, createdAt: 0, updatedAt: 0, placement: { position },
  table: { model: { headerRowCount: 1, columnWidths, rows } } });
const resources = [
  table('truth', [['*p*', '*q*', ...connectives.map(([s]) => s)].map((s) => cell(s, true)),
    ...truth],
    [1, 1, 1.3, 1.6, 1.6, 1.6, 1.6], t({ en: 'The five connectives, row by row.',
      es: 'Las cinco conectivas, fila a fila.' }), 'top'), // to the head of a page
  table('signs', parseTSV(signs.trim()).rows.map((row, r) => row.map(({ content }, c) => ({
    content, align: c === 0 ? 'center' : 'left', isHeader: r === 0 }))), [0.8, 2.1, 5.3],
  t({ en: 'Where the signs come from.', es: 'De dónde vienen los signos.' }), 'here'),
];
// #endregion

// ─── 3 · Fonts ──────────────────────────────────────────────────────────────
const FONTS = {
  'Crimson Pro': ['400', '400i', '600'],
  'Cormorant Garamond': ['400', '600'], // 400: the line of signs, all of it from the symbol font
  'IBM Plex Sans Condensed': ['400', '500', '600', '700', '700i'],
  'Noto Sans Math': ['400'], // the symbol font: one upright regular for every face
};

// ─── 4 · Build & show ───────────────────────────────────────────────────────
// #region without: one build without the symbol font, to read what it reports
// Each paragraph that sets a character its face lacks is a glyphFallbackAt warning with its
// page; with no symbol font it names no family that draws them, and the PDF would print
// empty boxes. The pages shown are the second build's.
const fonts = { ...kitFonts(FONTS), resolve }; // the kit's resolver, with the symbol file
const bare = await buildDocumentWithFonts({ markdown, resources }, { ...config, symbolFont: '' },
  fonts);
console.info((bare.contentWarnings ?? []).filter((w) => w.kind === 'glyphFallbackAt')
  .map(formatWarning).join('\n'));
// #endregion
const doc = await buildDocumentWithFonts({ markdown, resources }, config, fonts);
showPages(doc, { title: t({ en: 'A pocket primer of logic', es: 'Cartilla de lógica' }) });
offerPdf(() => renderToPdf(doc, { fontProvider: pdfFonts }), `${RECIPE}.pdf`);

// ─── Kit ── helpers shared by every Cookbook recipe · postext.dev/cookbook ─────

// ─── Kit · core v1 ── the same in every recipe · postext.dev/cookbook
function mm(value) { return { value, unit: 'mm' }; }
function pt(value) { return { value, unit: 'pt' }; }
function em(value) { return { value, unit: 'em' }; }
/** The sample language's string: t({ en: 'Figure', es: 'Figura' }). */
function t(strings) { return strings[LANG] ?? Object.values(strings)[0]; }
/** A file in this recipe's assets folder, served from the Postext repo by jsDelivr. */
function asset(file) { return `https://cdn.jsdelivr.net/gh/drnachio/postext@main/cookbook/${RECIPE}/assets/${file}`; }

// ─── Kit · fonts v3 ── the same in every recipe · postext.dev/cookbook
// Postext loads the faces a config asks for before layout and asks the kit
// for Fontsource's files, the ones the PDF embeds too.

/** buildDocumentWithFonts' options: the resolver, and FONTS' faces loaded
 *  with the config's. FONTS = { 'Family Name': ['400', '400i', '700'] }. */
function kitFonts(FONTS = {}) {
  const faces = Object.entries(FONTS).flatMap(([family, specs]) => specs.map((spec) =>
    ({ family, weight: parseInt(spec, 10), style: spec.endsWith('i') ? 'italic' : 'normal' })));
  return { resolve: fontsourceResolver, faces };
}

/** A face's files with their ranges: latin, then latin-ext and greek when
 *  `text` needs them (kitSubsetsFor). Null for a face Fontsource lacks. */
async function fontsourceResolver(family, weight, style, { text = '' } = {}) {
  const id = fontsourceId(family);
  const meta = await fontsourceMeta(family);
  if (meta && !(await fontsourceWeights(family, style)).includes(weight)) return null;
  kitStatus('Loading fonts…');
  const at = await fontsourceAt(id);
  return ['latin', ...kitSubsetsFor(text, meta)].map((subset) => ({
    source: `${at}files/${id}-${subset}-${weight}-${style}.woff2`,
    unicodeRange: kitRanges()[subset],
  }));
}

/** Each file's unicode-range (a function: the kit runs after the pen's code). */
function kitRanges() {
  return {
    latin: 'U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,'
      + 'U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD',
    'latin-ext': 'U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,'
      + 'U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF',
    greek: 'U+0370-03FF',
  };
}

/** For the cjk, arabic and comics blocks: loads `faces` (as FONTS) for the
 *  sample `text`; `optional` skips a face Fontsource lacks. Files are added in
 *  the order asked, the last winning a shared character. Resolves to the count. */
async function loadFonts(faces, text = '', { optional = false } = {}) {
  kitStatus('Loading fonts…');
  const ranges = kitRanges();
  const jobs = [];
  for (const [family, specs] of Object.entries(faces)) {
    const id = fontsourceId(family);
    const todo = [...new Set(specs)].map((spec) => [parseInt(spec, 10), spec.endsWith('i') ? 'italic' : 'normal'])
      .filter(([weight, style]) => !hasFace(family, weight, style)); // before any await
    const at = fontsourceAt(id);
    const meta = optional || /[^\0-ÿ]/u.test(text) ? await fontsourceMeta(family) : null;
    const subsets = ['latin', ...kitSubsetsFor(text, meta)];
    for (const [weight, style] of todo) {
      if (optional && !(meta && (await fontsourceWeights(family, style)).includes(weight))) continue;
      for (const subset of subsets) {
        const url = `${await at}files/${id}-${subset}-${weight}-${style}.woff2`;
        const face = new FontFace(family, `url(${url}) format('woff2')`,
          { weight: String(weight), style, unicodeRange: ranges[subset] });
        jobs.push(face.load().catch(() => {
          if (subset === 'latin' && !optional) throw new Error(`Fontsource has no ${family} ${weight} ${style}`);
        }));
      }
    }
  }
  const ready = await Promise.all(jobs).catch((error) => { kitFail(error); throw error; });
  return ready.filter((face) => face && document.fonts.add(face)).length;
}

/** A loaded FontFace covers this face (fonts.check() says yes to any family). */
function hasFace(family, weight, style) {
  for (const face of document.fonts) {
    if (face.status !== 'loaded' || face.style !== style) continue;
    if (face.family.replace(/^["']|["']$/g, '') !== family) continue;
    const [low, high = low] = face.weight.split(' ').map(Number);
    if (weight >= low && weight <= high) return true;
  }
  return false;
}

/** The files beyond latin `text` needs that `meta`'s family ships. */
function kitSubsetsFor(text, meta) {
  return [[/[Ā-˿ᴀ-ᶿḀ-ỿ†ℓⱠ-Ɀ꜠-ꟿ]/u, 'latin-ext'], [/[Ͱ-Ͽ]/u, 'greek']]
    .filter(([re, x]) => re.test(text) && meta?.subsets?.includes(x)).map(([, x]) => x);
}

/** Fontsource's id for a family: 'Source Serif 4' → 'source-serif-4'. */
function fontsourceId(family) { return family.toLowerCase().replace(/\s+/g, '-'); }

/** A package's folder at the one version @5 names now (#766). */
function fontsourceAt(id, u = `https://cdn.jsdelivr.net/npm/@fontsource/${id}@`) {
  return (fontsourceAt.c ??= {})[id] ??= fetch(u + '5/package.json').then((r) => r.json())
    .then((p) => p.version || 5, () => 5).then((v) => `${u}${v}/`);
}

/** The family's Fontsource metadata (weights, styles, subsets), or null. */
function fontsourceMeta(family, id = fontsourceId(family)) {
  return (fontsourceMeta.c ??= {})[id] ??= fetch(`https://api.fontsource.org/v1/fonts/${id}`)
    .then((res) => (res.ok ? res.json() : null), () => null);
}

/** The weights the package ships in `style`: the API pairs none (no Libre
 *  Caslon 700 italic file), so italics are read from latin-italic.css. */
function fontsourceWeights(family, style, id = fontsourceId(family)) {
  return (fontsourceWeights.c ??= {})[id + style] ??= fontsourceMeta(family).then(async (m) => {
    if (!m?.styles.includes(style)) return m ? [] : [400, 700];
    const css = style === 'italic' ? await fetch(`${await fontsourceAt(id)}latin-italic.css`).then((r) => (r.ok ? r.text() : ''), () => '') : '';
    const w = [...css.matchAll(/weight: (\d+)/g)].map((x) => +x[1]);
    return w.length ? w : m.weights;
  });
}

// ─── Kit · viewer v2 ── the same in every recipe · postext.dev/cookbook
/** The pages as spreads on a dark desk, page 1 alone, then verso | recto,
 *  each painted when it scrolls near. Other options go to renderPageToCanvas. */
function showPages(docs, { title, width = 460, ...render } = {}) {
  const root = viewer(title);
  const pages = [docs].flat().flatMap((doc) =>
    doc.pages.map((page) => ({ doc, page, n: (doc.pageIndexOffset ?? 0) + page.index })));
  const spreads = [];
  let verso = null;
  for (const p of pages) {
    if (p.n % 2 === 1) { if (verso) spreads.push([verso, null]); verso = p; }
    else { spreads.push([verso, p]); verso = null; }
  }
  if (verso) spreads.push([verso, null]);
  const density = Math.min(window.devicePixelRatio || 1, 2);
  showPages.painter?.disconnect();
  const painter = new IntersectionObserver((entries) => {
    for (const { isIntersecting, target } of entries) {
      if (!isIntersecting) continue;
      painter.unobserve(target);
      const { doc, page } = target.postext;
      renderPageToCanvas(page, doc, target, { ...render, scale: (width * density) / page.width });
    }
  }, { rootMargin: '800px' });
  showPages.painter = painter;
  root.replaceChildren(...spreads.map((pair) => {
    const spread = document.createElement('div');
    spread.className = 'pt-spread';
    for (const p of pair) {
      const figure = document.createElement('figure');
      if (p) {
        const label = p.page.pageLabel || String(p.n + 1);
        const canvas = document.createElement('canvas');
        canvas.postext = p;
        canvas.style.aspectRatio = `${p.page.width} / ${p.page.height}`;
        canvas.setAttribute('role', 'img');
        canvas.setAttribute('aria-label', `Page ${label}`);
        const folio = document.createElement('figcaption');
        folio.textContent = label;
        figure.append(canvas, folio);
        painter.observe(canvas);
      } else figure.className = 'pt-blank';
      spread.append(figure);
    }
    return spread;
  }));
  kitStatus(`${pages.length} ${pages.length === 1 ? 'page' : 'pages'}`);
  document.documentElement.dataset.postext = 'ready';
  return pages.length;
}

/** The desk, the bar and the error reporting, created once. */
function viewer(title) {
  if (!document.getElementById('pt-kit')) {
    document.head.insertAdjacentHTML('beforeend', `<style id="pt-kit">
      :root { color-scheme: dark; }
      body { margin: 0; background: #0e1014; color: #b9bcc4; font: 13px/1.45 system-ui, sans-serif; }
      #pt-bar { position: sticky; top: 0; z-index: 1; display: flex; flex-wrap: wrap; align-items: center;
        gap: 6px 16px; padding: 10px 16px; background: rgb(14 16 20 / .92); backdrop-filter: blur(6px);
        border-bottom: 1px solid #23262d; }
      #pt-bar strong { color: #f4f1ea; font-weight: 600; }
      #pt-actions { display: flex; gap: 12px; margin-left: auto; }
      #pt-actions a, #pt-actions button { color: #d8a21a; font: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
      #pages { display: grid; justify-items: center; gap: 48px; padding: 32px 16px 72px; }
      .pt-spread { display: flex; }
      .pt-spread figure { margin: 0; width: min(460px, 44vw); }
      .pt-spread canvas { display: block; width: 100%; background: #fff;
        box-shadow: 0 1px 2px rgb(0 0 0 / .5), 0 22px 44px -16px rgb(0 0 0 / .8); }
      .pt-spread figure:first-child canvas { box-shadow: inset -14px 0 14px -14px rgb(0 0 0 / .18), 0 1px 2px rgb(0 0 0 / .5), 0 22px 44px -16px rgb(0 0 0 / .8); }
      .pt-spread figcaption { margin-top: 10px; text-align: center; font: 600 10px/1 system-ui, sans-serif;
        letter-spacing: .18em; text-transform: uppercase; color: #6c7079; }
      .pt-blank { visibility: hidden; }
      @media (max-width: 760px) {
        .pt-spread { flex-direction: column; gap: 32px; }
        .pt-spread figure { width: min(460px, 92vw); }
        .pt-blank { display: none; }
      }
    </style>`);
    document.body.insertAdjacentHTML('afterbegin',
      '<header id="pt-bar"><strong id="pt-title"></strong><span id="pt-status" role="status"></span><span id="pt-actions"></span></header>');
    document.getElementById('pt-title').textContent = document.title || 'Postext';
    addEventListener('error', (event) => kitFail(event.error ?? event.message));
    addEventListener('unhandledrejection', (event) => kitFail(event.reason));
  }
  if (title) document.getElementById('pt-title').textContent = title;
  return document.getElementById('pages')
    ?? document.body.appendChild(Object.assign(document.createElement('main'), { id: 'pages' }));
}

function kitStatus(text) {
  viewer();
  document.getElementById('pt-status').textContent = text;
}

function kitFail(error) {
  document.documentElement.dataset.postext = 'error';
  kitStatus(`Error: ${error?.message ?? error}`);
}

// ─── Kit · pdf v3 ── the same in every recipe that exports a PDF
/** The Fontsource files the screen used, as TrueType, with their range and
 *  place: the nearest weight the family ships in that style, upright with no italic;
 *  latin, then what its letters need (kitSubsetsFor). */
async function fontsourceProvider(family, weight, style, request) {
  const id = fontsourceId(family);
  const meta = await fontsourceMeta(family);
  const s = style === 'italic' && meta && !meta.styles.includes('italic') ? 'normal' : style;
  const shipped = meta ? await fontsourceWeights(family, s) : [];
  const weights = shipped.length ? shipped : [400, 700];
  const w = weights.reduce((a, b) => (Math.abs(b - weight) < Math.abs(a - weight) ? b : a));
  const text = String.fromCodePoint(...(request?.codePoints ?? []));
  const files = await Promise.all(['latin', ...kitSubsetsFor(text, meta)].map(async (subset, order) => {
    const res = await fetch(`${await fontsourceAt(id)}files/${id}-${subset}-${w}-${s}.woff2`);
    if (!res.ok) throw new Error(`Fontsource has no ${family} ${w} ${s} ${subset}`);
    return Object.assign(await decompressWoff2(new Uint8Array(await res.arrayBuffer())),
      { unicodeRange: kitRanges()[subset], order });
  }));
  return files.length === 1 ? files[0] : files;
}

/** A "Build the PDF" button; then "Open the PDF" (a new tab: CodePen's frame
 *  shows no PDFs) and a download link. */
function offerPdf(makePdf, filename) {
  viewer();
  const button = Object.assign(document.createElement('button'), { type: 'button', textContent: 'Build the PDF' });
  button.dataset.postextPdf = filename;
  button.addEventListener('click', async () => {
    button.disabled = true;
    button.textContent = 'Building the PDF…';
    try {
      const bytes = await makePdf();
      const url = URL.createObjectURL(new Blob([bytes], { type: 'application/pdf' }));
      const size = `${Math.max(1, Math.round(bytes.length / 1024))} KB`;
      button.replaceWith(
        Object.assign(document.createElement('a'), { href: url, target: '_blank', rel: 'noopener', textContent: 'Open the PDF ↗' }),
        Object.assign(document.createElement('a'), { href: url, download: filename, textContent: `Download ${filename} · ${size}` }));
    } catch (error) {
      button.disabled = false;
      button.textContent = 'Build the PDF';
      kitFail(error);
    }
  });
  document.getElementById('pt-actions').append(button);
}

// ─── /Kit ───────────────────────────────────────────────────────────────────────
```

## Variantes

### Supprimer la première composition

Une fois les avertissements lus, une seule composition suffit.

```diff
-const bare = await buildDocumentWithFonts({ markdown, resources }, { ...config, symbolFont: '' },
-  fonts);
-console.info((bare.contentWarnings ?? []).filter((w) => w.kind === 'glyphFallbackAt')
-  .map(formatWarning).join('\n'));
```

## Erreurs fréquentes

- **Avertissement de mise en page: Caractères absents de la police, ici** (`glyphFallbackAt`). Un paragraphe contient des caractères absents de la police de son texte : lettres et opérateurs mathématiques (∪, ℵ), grec dans une police latine, flèches (glyphFallback nomme la police, celui-ci le paragraphe). supplier est la famille qui les dessine, en général la symbolFont ; sans elle, le PDF les imprime comme des cases vides. Solution: Indiquez une symbolFont qui les contient (Noto Sans Math couvre presque toutes les mathématiques), ou choisissez une famille de texte qui les a. Si le caractère est faux (un aleph hébreu là où l’auteur voulait un complémentaire), corrigez le texte. ([Documentation](https://postext.dev/fr/docs/configuration-programmatic-usage.md#avertissements-dans-le-document))

- Une police dont les fichiers Fontsource comprennent le grec (Source Serif 4, Alegreya) compose elle-même φ et Γ, et le kit charge ce fichier quand le texte contient du grec : seuls les signes passent alors à la police des symboles. Crimson Pro n’a pas de fichier grec, son grec vient donc de Noto Sans Math.
- La police des symboles n’a qu’un style, romain et normal. Un titre en gras ou une formule en italique compose ses signes dans ce style, comme les imprime l’usage mathématique.

## Crédits

- Recette: Ignacio Ferro ([@drnachio](https://github.com/drnachio))
- Texte: The primer of logical notation, in English and Spanish: Ignacio Ferro, CC-BY-4.0
- Caractères: Crimson Pro (OFL-1.1), Cormorant Garamond (OFL-1.1), IBM Plex Sans Condensed (OFL-1.1), Noto Sans Math (OFL-1.1)
- Code: MIT · Contenu d’exemple: CC-BY-4.0

## Recettes liées

- [Nº 180 · Surlignages par couleur dans un livre de lectures](https://postext.dev/fr/cookbook/colour-coded-study-highlights.md): Un livre de lectures d’histoire dont les mots clés portent trois couleurs (vert pour les termes, ambre pour les dates, bleu pour les noms) tirées de markStyles. · Niveau 2 (Intermédiaire) · Manuels scolaires
- [Nº 077 · Noms propres et titres marqués, en colonnes et en lignes](https://postext.dev/fr/cookbook/proper-name-marks.md): Les Annales fondamentales de Xiang Yu avec :name et :book, composées sur une page reliée à droite puis en lignes : traits à gauche des noms, puis dessous. · Niveau 2 (Intermédiaire) · Manuels scolaires
- [Nº 122 · Le kanbun avec ses signes de lecture et sa lecture japonaise](https://postext.dev/fr/cookbook/kanbun-kundoku.md): Trois maximes des Entretiens et un quatrain Tang comme dans un manuel japonais : signes de retour et okurigana vermillon, lecture en kana sous chaque passage. · Niveau 2 (Intermédiaire) · Manuels scolaires
