issue225:latex
Différences
Ci-dessous, les différences entre deux révisions de la page.
| Les deux révisions précédentesRévision précédente | |||
| issue225:latex [2026/02/02 08:43] – d52fr | issue225:latex [2026/02/02 09:15] (Version actuelle) – d52fr | ||
|---|---|---|---|
| Ligne 4: | Ligne 4: | ||
| Selecting pages for printing before the PDF is compiled means steps in the compiling process that rely on page numbers will be affected. Tables of contents, indices, cross-references, | Selecting pages for printing before the PDF is compiled means steps in the compiling process that rely on page numbers will be affected. Tables of contents, indices, cross-references, | ||
| + | |||
| + | Un mois de plus s'est écoulé et un nouveau numéro de FCM a été publié. Cette fois-ci, je vais me pencher sur quelques-uns des nombreux paquets du thème « P » sur ctan.org. Il existe une quarantaine de thèmes différents commençant par « P », je n'ai donc eu aucun mal à en trouver quelques-uns qui conviennent et qui me semblent utiles à certains d' | ||
| + | |||
| + | Dans le thème « Sélection de pages », trois paquets permettent de contrôler les pages qui seront utilisées dans le document final. Le paquet pagesel permet d' | ||
| + | |||
| + | Sélectionner les pages à imprimer avant la compilation du PDF a un impact sur les étapes de la compilation qui dépendent des numéros de page. Tables des matières, index, références croisées, notes de bas de page, notes de fin, etc., seront tous affectés. | ||
| + | |||
| **Page section tools could be useful to hide information from viewers of the final document. For example, a teacher might find it useful to put all the questions for a test on odd-numbered pages and all the correct answers on even-numbered pages. | **Page section tools could be useful to hide information from viewers of the final document. For example, a teacher might find it useful to put all the questions for a test on odd-numbered pages and all the correct answers on even-numbered pages. | ||
| Ligne 10: | Ligne 17: | ||
| There are twelve packages that will allow text to be typed in parallel columns. These are useful in scholarly publications for translations or for adding commentary to text. The paracol package by Nakashima and Kurtz has 315 pages of documentation plus a 64-page user manual. The documentation is written using the package. One column is English and the other is the Latex document used to generate the English. If nothing else, this is quite a feat of writing. I suppose it could be argued the actual documentation is only half of 315 pages. However I find it very helpful if the documentation shows both the Latex code and the result of that code.** | There are twelve packages that will allow text to be typed in parallel columns. These are useful in scholarly publications for translations or for adding commentary to text. The paracol package by Nakashima and Kurtz has 315 pages of documentation plus a 64-page user manual. The documentation is written using the package. One column is English and the other is the Latex document used to generate the English. If nothing else, this is quite a feat of writing. I suppose it could be argued the actual documentation is only half of 315 pages. However I find it very helpful if the documentation shows both the Latex code and the result of that code.** | ||
| + | |||
| + | Les outils de pagination peuvent s' | ||
| + | |||
| + | Il existe deux autres paquets de sélection de pages : selectp et selectpage. Tous deux ont été mis en ligne sur CTAN en 1987. Je vous suggère d' | ||
| + | |||
| + | Douze paquets permettent de saisir du texte en colonnes parallèles. Ils sont utiles dans les publications scientifiques pour les traductions ou l' | ||
| + | |||
| **The way to get started is to put usepackage{paracol} in the preamble. Then start the document and start with the command begin{paracol}{2} to generate two columns. (It is just as easy to set up and use more than two columns.) The command to move from one column to another is switchcolumn. Switchcolumn can also have a number as an option in brackets. If no number is indicated, then the next input will be placed in the column that is next. For example, starting in the left column, the switchcolumn command automatically moves the next input from left column to right column. If currently in the right column, then the next input goes into the left column. | **The way to get started is to put usepackage{paracol} in the preamble. Then start the document and start with the command begin{paracol}{2} to generate two columns. (It is just as easy to set up and use more than two columns.) The command to move from one column to another is switchcolumn. Switchcolumn can also have a number as an option in brackets. If no number is indicated, then the next input will be placed in the column that is next. For example, starting in the left column, the switchcolumn command automatically moves the next input from left column to right column. If currently in the right column, then the next input goes into the left column. | ||
| Ligne 16: | Ligne 30: | ||
| Graphics, tables and other features may be incorporated into the switchcolumn environment. These features are set up as floats in Latex. You may need a few iterations in order to understand how to use them in a column environment, | Graphics, tables and other features may be incorporated into the switchcolumn environment. These features are set up as floats in Latex. You may need a few iterations in order to understand how to use them in a column environment, | ||
| + | |||
| + | Pour commencer, insérez « usepackage{paracol} » dans le préambule. Ensuite, ouvrez le document et commencez par la commande « begin{paracol}{2} » pour générer deux colonnes. (Il est tout aussi simple de configurer et d' | ||
| + | |||
| + | La commande « switchcolumn » suivie d'un astérisque (*) synchronisera les colonnes, en adaptant la longueur du texte à la colonne la plus longue du bloc d' | ||
| + | |||
| + | Des graphiques, des tableaux et d' | ||
| + | |||
| **The paracol package is intended to be used by academics. Many packages in Latex do not have serious intentions. For example, the shapepar package is designed to bring some levity to documents. It allows the user to typeset text to a particular shape instead of a standard paragraph with flush left, ragged right and left indent. The example shows the first paragraph in a circle. There are other possible shapes and other possible options. The shapepar package can show a shape with a cutout in it. The thirteen-page document is somewhat long on technical details, and somewhat short on practical use. There are two examples of the creative use of shapepar but no code to go with them. A close reading of the documentation plus some (many?) practice documents would help a user understand how to use shapepar effectively. This package is obviously not meant for pages of technical or educational documents. It would be fun for invitations, | **The paracol package is intended to be used by academics. Many packages in Latex do not have serious intentions. For example, the shapepar package is designed to bring some levity to documents. It allows the user to typeset text to a particular shape instead of a standard paragraph with flush left, ragged right and left indent. The example shows the first paragraph in a circle. There are other possible shapes and other possible options. The shapepar package can show a shape with a cutout in it. The thirteen-page document is somewhat long on technical details, and somewhat short on practical use. There are two examples of the creative use of shapepar but no code to go with them. A close reading of the documentation plus some (many?) practice documents would help a user understand how to use shapepar effectively. This package is obviously not meant for pages of technical or educational documents. It would be fun for invitations, | ||
| Returning to educational packages, would you like to be able to add illustrations of atoms to your chemistry and physics homework? The bohr package adds the ability to draw Bohr diagrams to Latex documents. You may remember Bohr diagrams show atoms in “solar system” configurations with a central nucleus surrounded by electrons going around it like planets around the sun. The current version is limited to elements up to atomic number 112. (Atomic numbers, i.e. elements, are currently at 118.)** | Returning to educational packages, would you like to be able to add illustrations of atoms to your chemistry and physics homework? The bohr package adds the ability to draw Bohr diagrams to Latex documents. You may remember Bohr diagrams show atoms in “solar system” configurations with a central nucleus surrounded by electrons going around it like planets around the sun. The current version is limited to elements up to atomic number 112. (Atomic numbers, i.e. elements, are currently at 118.)** | ||
| + | |||
| + | Le paquet paracol est destiné aux universitaires. De nombreux paquets LaTeX ont une vocation plus ludique. Par exemple, le paquet shapepar est conçu pour apporter une touche d' | ||
| + | |||
| + | Pour en revenir aux paquets pédagogiques, | ||
| + | |||
| **The syntax is very simple. usepackage(bohr) in the preamble and then bohr{atomic number}{atomic name}. The six-page documentation gives several other options to control the appearance of each model. The package is not limited to atoms. It can draw ions which will show the distribution of electrical charge in a compound. Important Note: The user has to supply appropriate correct values, the package does not have a database with these values.. | **The syntax is very simple. usepackage(bohr) in the preamble and then bohr{atomic number}{atomic name}. The six-page documentation gives several other options to control the appearance of each model. The package is not limited to atoms. It can draw ions which will show the distribution of electrical charge in a compound. Important Note: The user has to supply appropriate correct values, the package does not have a database with these values.. | ||
| Ligne 26: | Ligne 52: | ||
| Presentation packages are also in the P topic. Tex/Latex is not restricted to PDFs which resemble books and journals. Tex/Latex can generate PDFs which resemble presentation files. The main package for this kind of work is called “beamer”. There are more that seventy packages available which either work with beamer or which attempt to make similar documents. If you need to generate slide shows but have no wish to use a commercial package, I suggest you experiment with Latex Beamer.** | Presentation packages are also in the P topic. Tex/Latex is not restricted to PDFs which resemble books and journals. Tex/Latex can generate PDFs which resemble presentation files. The main package for this kind of work is called “beamer”. There are more that seventy packages available which either work with beamer or which attempt to make similar documents. If you need to generate slide shows but have no wish to use a commercial package, I suggest you experiment with Latex Beamer.** | ||
| + | |||
| + | La syntaxe est très simple : « usepackage(bohr) » dans le préambule, puis « bohr{numéro atomique}{nom atomique} ». La documentation de six pages propose plusieurs autres options pour contrôler l' | ||
| + | |||
| + | Comme vous pouvez l' | ||
| + | |||
| + | Les paquets de présentation font également partie du sujet P. TeX/LaTeX ne se limite pas aux PDF ressemblant à des livres et des revues. TeX/LaTeX peut générer des PDF ressemblant à des fichiers de présentation. Le paquet principal pour ce type de travail s' | ||
| + | |||
| **Beamer is a document class like article and book. The class was last updated in 2025 August. All (or almost all) of the packages discussed in these columns will work in beamer files. There is no need to learn a new set of commands simply because the document class is now a presentation. Because beamer files are Tex/Latex files, converting from a presentation to a text document, or vice versa, is easy. The final output of a beamer document is a PDF file which can be shown on-screen, uploaded to a web site, or given directly to participants. Documentation for beamer is extensive: 234 pages. In addition to the documentation available at CTAN, there are many other sources of information and guidance for beamer. | **Beamer is a document class like article and book. The class was last updated in 2025 August. All (or almost all) of the packages discussed in these columns will work in beamer files. There is no need to learn a new set of commands simply because the document class is now a presentation. Because beamer files are Tex/Latex files, converting from a presentation to a text document, or vice versa, is easy. The final output of a beamer document is a PDF file which can be shown on-screen, uploaded to a web site, or given directly to participants. Documentation for beamer is extensive: 234 pages. In addition to the documentation available at CTAN, there are many other sources of information and guidance for beamer. | ||
| Ligne 32: | Ligne 65: | ||
| Next issue I am going to explore modifying an existing package. As I said in a previous issue I am not happy with the default formatting for the jwjournal package, so I am going to manipulate it in order to get a journal environment I like.** | Next issue I am going to explore modifying an existing package. As I said in a previous issue I am not happy with the default formatting for the jwjournal package, so I am going to manipulate it in order to get a journal environment I like.** | ||
| + | |||
| + | Beamer est une classe de document, au même titre que article ou book. Sa dernière mise à jour date d' | ||
| + | |||
| + | J' | ||
| + | |||
| + | Dans le prochain article, j' | ||
issue225/latex.txt · Dernière modification : 2026/02/02 09:15 de d52fr
