issue187: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édenteProchaine révision | Révision précédente | ||
issue187:latex [2022/11/27 16:58] – d52fr | issue187:latex [2022/11/29 18:39] (Version actuelle) – andre_domenech | ||
---|---|---|---|
Ligne 8: | Ligne 8: | ||
Headers and footers contain information that is usually independent of the body, the text of the document. For example, in a magazine, like Full Circle Magazine, the title of the magazine and the date of publication is the same no matter what the article is about.** | Headers and footers contain information that is usually independent of the body, the text of the document. For example, in a magazine, like Full Circle Magazine, the title of the magazine and the date of publication is the same no matter what the article is about.** | ||
+ | |||
+ | Cette fois-ci, dans notre tour des nombreuses fonctionnalités de TeX/LaTeX, je vais explorer les en-têtes et les pieds de page. Il est important que vous sachiez clairement ce que ces deux mots signifient. Les gens confondent souvent les en-têtes avec les titres et les pieds de page avec les notes de bas de page. | ||
+ | |||
+ | Les en-têtes sont de petits bouts de texte qui apparaissent en haut, à la tête, de chaque page. | ||
+ | |||
+ | Les notes de bas de page sont de petits bouts de texte qui apparaissent en bas de chaque page. | ||
+ | |||
+ | Les en-têtes sont souvent une forme abrégée du titre de l' | ||
+ | |||
+ | Les en-têtes et les pieds de page contiennent des informations qui sont généralement indépendantes du corps et du texte du document. Par exemple, dans un magazine, comme Full Circle Magazine, le titre du magazine et la date de publication sont les mêmes, quel que soit le sujet de l' | ||
+ | |||
**Headings are short bits of text that are almost always set in larger sized type than the rest of the document. The text of a heading should be related to the body text that follows it. Footnotes used to be used for bibliographic references. That practice has been replaced in many publications by the use of endnotes or in-text citations. (Millions of students around the world are thankful for this change.) Footnotes are directly related to the body of the document, either pointing to external sources or describing alternative explanations to something in the body. We will look at footnotes and endnotes another time. | **Headings are short bits of text that are almost always set in larger sized type than the rest of the document. The text of a heading should be related to the body text that follows it. Footnotes used to be used for bibliographic references. That practice has been replaced in many publications by the use of endnotes or in-text citations. (Millions of students around the world are thankful for this change.) Footnotes are directly related to the body of the document, either pointing to external sources or describing alternative explanations to something in the body. We will look at footnotes and endnotes another time. | ||
Headers and footers are published outside the ordinary margins of the page. For example, in LibreOffice I set top and bottom margins of my documents to 2.5cm. If I use a header and/or footer, it will appear within that 2.5cm of space either at the top or bottom of the page. A piece of paper that is standard North American letter size is 27.94cm on its long dimension and 21.59cm on its short dimension. If I print in Portrait mode my text will appear in the 22.94cm in the middle of each page, with 2.5cm reserved both at the top and the bottom of each sheet. If I print in Landscape mode the same 2.5cm is reserved top and bottom so the text will appear in the central 16.59cm.** | Headers and footers are published outside the ordinary margins of the page. For example, in LibreOffice I set top and bottom margins of my documents to 2.5cm. If I use a header and/or footer, it will appear within that 2.5cm of space either at the top or bottom of the page. A piece of paper that is standard North American letter size is 27.94cm on its long dimension and 21.59cm on its short dimension. If I print in Portrait mode my text will appear in the 22.94cm in the middle of each page, with 2.5cm reserved both at the top and the bottom of each sheet. If I print in Landscape mode the same 2.5cm is reserved top and bottom so the text will appear in the central 16.59cm.** | ||
+ | |||
+ | Les en-têtes sont de courts morceaux de texte qui sont presque toujours présentés en caractères plus grands que le reste du document. Le texte d'un en-tête doit être lié au corps du texte qui le suit. Les notes de bas de page étaient autrefois utilisées pour les références bibliographiques. Cette pratique a été remplacée dans de nombreuses publications par l' | ||
+ | |||
+ | Les en-têtes et les pieds de page sont publiés en dehors des marges ordinaires de la page. Par exemple, dans LibreOffice, | ||
+ | |||
**That is in LibreOffice. What about in Tex/Latex documents? The space allocated to headers and footers in Latex documents is determined when the document type is set. Each document type has specific formatting which includes margins, font size, and many other settings. Those settings can be modified using various packages as we have seen before in this series. Those settings can also be modified by editing the settings directly in the default packages for articles, books, etc. Until you get a lot of experience with Latex, it is best to use one or more of the existing packages to get your documents to look how you want them. Remember many journals and other publications have developed their own "style sheets" | **That is in LibreOffice. What about in Tex/Latex documents? The space allocated to headers and footers in Latex documents is determined when the document type is set. Each document type has specific formatting which includes margins, font size, and many other settings. Those settings can be modified using various packages as we have seen before in this series. Those settings can also be modified by editing the settings directly in the default packages for articles, books, etc. Until you get a lot of experience with Latex, it is best to use one or more of the existing packages to get your documents to look how you want them. Remember many journals and other publications have developed their own "style sheets" | ||
Ligne 28: | Ligne 44: | ||
\pagestyle{fancy}** | \pagestyle{fancy}** | ||
+ | |||
+ | C'est le cas dans LibreOffice. Qu'en est-il dans les documents TeX/LaTeX ? L' | ||
+ | |||
+ | Avant de commencer à examiner les possibilités des en-têtes et des pieds de page, il y a deux ajouts à faire au préambule d'un document. fancyhdr doit être inclus et l' | ||
+ | |||
+ | \documentclass[letterpaper, | ||
+ | |||
+ | %preamble | ||
+ | |||
+ | \title{FCM 187 - Headers and Footers} | ||
+ | |||
+ | \date{2022 November} | ||
+ | |||
+ | \usepackage{graphicx, | ||
+ | |||
+ | \pagestyle{fancy} | ||
+ | |||
**Important Warning: During my testing for this article I discovered that the instructions in the documentation did not always give the results described in the documentation. Test various options before using this package in your documents, particularly your organization’s documents. | **Important Warning: During my testing for this article I discovered that the instructions in the documentation did not always give the results described in the documentation. Test various options before using this package in your documents, particularly your organization’s documents. | ||
Ligne 42: | Ligne 75: | ||
Upper or lower case letters can be used. The order of the letters does not seem to be significant.** | Upper or lower case letters can be used. The order of the letters does not seem to be significant.** | ||
+ | |||
+ | Avertissement important : Lors de mes tests pour cet article, j'ai découvert que les instructions de la documentation ne donnaient pas toujours les résultats décrits dans la documentation. Testez diverses options avant d' | ||
+ | |||
+ | Comme d' | ||
+ | |||
+ | \fancyhead[positions]{header} | ||
+ | |||
+ | \fancyfoot[positions]{footer} | ||
+ | |||
+ | \fancyhf[positions]{output} | ||
+ | |||
+ | Comme vous l'avez probablement deviné, [positions] fait référence à l' | ||
+ | |||
+ | Les lettres majuscules ou minuscules peuvent être utilisées. L' | ||
+ | |||
**I discovered adding commas between the position options changes the locations of headers and footers. For example \fancyhead[OR]{FCM 187} puts FCM 187 as header on the right side of every page (except page 1). \fancyhead[O, | **I discovered adding commas between the position options changes the locations of headers and footers. For example \fancyhead[OR]{FCM 187} puts FCM 187 as header on the right side of every page (except page 1). \fancyhead[O, | ||
Ligne 50: | Ligne 98: | ||
There is a 39-page manual that comes with the fancyheader macro set. I suggest you read it carefully and experiment if you wish to explore other possibilities.** | There is a 39-page manual that comes with the fancyheader macro set. I suggest you read it carefully and experiment if you wish to explore other possibilities.** | ||
+ | |||
+ | J'ai découvert que l' | ||
+ | |||
+ | En revanche, [lo] place un en-tête sur le côté gauche des pages impaires, ce qui correspond à ce que dit le manuel. Enfin, [l,o] place le même en-tête dans les trois positions. | ||
+ | |||
+ | Tous ces tests ont été effectués avec la classe \documentclass{article}. Lorsque je suis passé à \documentclass{book}, | ||
+ | |||
+ | Un manuel de 39 pages est fourni avec le jeu de macros fancyheader. Je vous suggère de le lire attentivement et de faire des tests si vous souhaitez explorer d' | ||
+ | |||
**There are many other commands available that can be used for various options with headers and footers. \fancyheadoffset, | **There are many other commands available that can be used for various options with headers and footers. \fancyheadoffset, | ||
Ligne 62: | Ligne 119: | ||
using whatever width (thickness) is desirable.** | using whatever width (thickness) is desirable.** | ||
+ | |||
+ | De nombreuses autres commandes sont disponibles et peuvent être utilisées pour diverses options avec les en-têtes et les pieds de page. \fancyheadoffset, | ||
+ | |||
+ | Une largeur d' | ||
+ | |||
+ | \renewcommand{\headrulewidth}{2pt} | ||
+ | |||
+ | ou | ||
+ | |||
+ | | ||
+ | |||
+ | en utilisant la largeur (l' | ||
**There are other options to eliminate headers and footers, to have separate headers and footers for different sections, for pages that are purposefully left blank or that contain only a table or graphic. There are other options as well. If you are interested, read the documentation that comes with fancyhdr. | **There are other options to eliminate headers and footers, to have separate headers and footers for different sections, for pages that are purposefully left blank or that contain only a table or graphic. There are other options as well. If you are interested, read the documentation that comes with fancyhdr. | ||
Again I say – experiment with the choices, do not assume the documentation explains or describes every case. This is a very useful tool and will let you make headers and footers the way you want them, if you learn how to use it.** | Again I say – experiment with the choices, do not assume the documentation explains or describes every case. This is a very useful tool and will let you make headers and footers the way you want them, if you learn how to use it.** | ||
+ | |||
+ | D' | ||
+ | |||
+ | Encore une fois, je le dis, faites des essais avec différents choix, ne supposez pas que la documentation explique ou décrit tous les cas. C'est un outil très utile qui vous permettra de créer des en-têtes et des pieds de page comme vous le souhaitez, si vous apprenez à l' | ||
issue187/latex.1669564715.txt.gz · Dernière modification : 2022/11/27 16:58 de d52fr