Debian Codegraph @

translations/manual/fr_CA/template_lang.po

raw
1 # SOME DESCRIPTIVE TITLE.
2 # Copyright (C) Kovid Goyal
3 # This file is distributed under the same license as the calibre package.
4 #
5 # Translators:
6 msgid ""
7 msgstr ""
8 "Project-Id-Version: calibre\n"
9 "Report-Msgid-Bugs-To: \n"
10 "POT-Creation-Date: 2026-02-17 16:44+0000\n"
11 "PO-Revision-Date: 2014-06-17 08:34+0000\n"
12 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13 "Language-Team: French (Canada) (http://app.transifex.com/calibre/calibre/language/fr_CA/)\n"
14 "MIME-Version: 1.0\n"
15 "Content-Type: text/plain; charset=UTF-8\n"
16 "Content-Transfer-Encoding: 8bit\n"
17 "Language: fr_CA\n"
18 "Plural-Forms: nplurals=3; plural=(n == 0 || n == 1) ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n"
19
20 #: ../../../__w/calibre/calibre/manual/template_lang.rst:4
21 msgid "The calibre template language"
22 msgstr "Le langage de modèle calibre"
23
24 #: ../../../__w/calibre/calibre/manual/template_lang.rst:6
25 msgid ""
26 "The calibre template language is a calibre-specific language used throughout"
27 " calibre for tasks such as specifying file paths, formatting values, and "
28 "computing the value for user-specified columns. Examples:"
29 msgstr "Le langage de modèle de calibre est un langage spécifique à calibre utilisé dans l'ensemble de calibre pour des tâches telles que la spécification des chemins de fichiers, le formatage des valeurs et le calcul de la valeur des colonnes spécifiées par l'utilisateur. Exemples :"
30
31 #: ../../../__w/calibre/calibre/manual/template_lang.rst:8
32 msgid ""
33 "Specify the folder structure and file names when saving files from the "
34 "calibre library to the disk or e-book reader."
35 msgstr "Spécifier la structure du dossier et les noms de fichiers lors de l'enregistrement des fichiers de la bibliothèque calibre sur le disque ou le lecteur de livres numériques."
36
37 #: ../../../__w/calibre/calibre/manual/template_lang.rst:9
38 msgid "Define rules for adding icons and colors to the calibre book list."
39 msgstr "Définir des règles pour l'ajout d'icônes et de couleurs à la liste de livres de calibre."
40
41 #: ../../../__w/calibre/calibre/manual/template_lang.rst:10
42 msgid "Define `virtual columns` that contain data from other columns."
43 msgstr "Définir les `colonnes virtuelles` qui contiennent des données provenant d'autres colonnes."
44
45 #: ../../../__w/calibre/calibre/manual/template_lang.rst:11
46 msgid "Advanced library searching."
47 msgstr "Recherche avancée dans la bibliothèque."
48
49 #: ../../../__w/calibre/calibre/manual/template_lang.rst:12
50 msgid "Advanced metadata search and replace."
51 msgstr "Recherche et remplacement avancé des métadonnées."
52
53 #: ../../../__w/calibre/calibre/manual/template_lang.rst:14
54 msgid ""
55 "The language is built around the notion of a `template`, which specifies "
56 "which book metadata to use, computations on that metadata, and how it is to "
57 "be formatted."
58 msgstr "Le langage est construit autour de la notion de `modèle`, qui spécifie les métadonnées du livre à utiliser, les calculs sur ces métadonnées, et la façon dont elles doivent être formatées."
59
60 #: ../../../__w/calibre/calibre/manual/template_lang.rst:17
61 msgid "Basic templates"
62 msgstr "Modèles de base"
63
64 #: ../../../__w/calibre/calibre/manual/template_lang.rst:19
65 msgid ""
66 "A basic template consists of one or more ``template expressions``. A "
67 "``template expression`` consists of text and names in curly brackets "
68 "(``{}``) that is replaced by the corresponding metadata from the book being "
69 "processed. For example, the default template in calibre used for saving "
70 "books to device has 4 ``template expressions``::"
71 msgstr ""
72
73 #: ../../../__w/calibre/calibre/manual/template_lang.rst:23
74 msgid "For the book \"The Foundation\" by \"Isaac Asimov\" the template will become::"
75 msgstr ""
76
77 #: ../../../__w/calibre/calibre/manual/template_lang.rst:27
78 msgid ""
79 "The slashes are not ``template expressions`` because they are not in between"
80 " ``{}``. Such text is left where it appears. For example, if the template "
81 "is::"
82 msgstr ""
83
84 #: ../../../__w/calibre/calibre/manual/template_lang.rst:31
85 msgid "then for \"The Foundation\" the template produces::"
86 msgstr "dès lors, pour \"The Foundation\", le modèle produit::"
87
88 #: ../../../__w/calibre/calibre/manual/template_lang.rst:35
89 msgid ""
90 "A ``template expression`` can access all the metadata available in calibre, "
91 "including custom columns (columns you create yourself), by using a column's "
92 "``lookup name``. To find the lookup name for a `column` (sometimes called "
93 "`fields`), hover your mouse over the column header in calibre's book list. "
94 "Lookup names for custom columns always begin with ``#``. For series type "
95 "columns there is an additional field named ``#lookup name_index`` that is "
96 "the series index for that book in the series. For example, if you have a "
97 "custom series column named ``#myseries``, there will also be a column named "
98 "``#myseries_index``. The standard series column's index is named "
99 "``series_index``."
100 msgstr "Une ``expression modèle`` peut accéder à toutes les métadonnées disponibles dans calibre, y compris les colonnes personnalisées (colonnes que vous créez vous-même), en utilisant le ``nom de recherche`` d'une `colonne`. Pour trouver le nom de recherche d'une `colonne` (parfois appelée `champs`), passez votre souris sur l'en-tête de la colonne dans la liste des livres de calibre. Les noms de recherche pour les colonnes personnalisées commencent toujours par ``#``. Pour les colonnes de type série, il y a un champ supplémentaire appelé ``#lookup name_index`` qui est l'index de la série pour ce livre dans la série. Par exemple, si vous avez une colonne de série personnalisée nommée ``#messéries``, il y aura également une colonne nommée ``#messéries_index``. L'index de la colonne de série standard est nommé ``series_index``."
101
102 #: ../../../__w/calibre/calibre/manual/template_lang.rst:37
103 msgid "In addition to the standard column based fields, you also can use:"
104 msgstr "En plus des champs standard basés sur des colonnes, vous pouvez également utiliser :"
105
106 #: ../../../__w/calibre/calibre/manual/template_lang.rst:39
107 msgid ""
108 "``{formats}`` - A list of formats available in the calibre library for a "
109 "book"
110 msgstr "``{formats}`` - Une liste des formats disponibles dans la bibliothèque calibre pour un livre"
111
112 #: ../../../__w/calibre/calibre/manual/template_lang.rst:40
113 msgid "``{identifiers:select(isbn)}`` - The ISBN of the book"
114 msgstr "``{identifiers:select(isbn)}`` - L'ISBN du livre"
115
116 #: ../../../__w/calibre/calibre/manual/template_lang.rst:42
117 msgid ""
118 "If the metadata for the field for a given book is not defined then the field"
119 " in the template is replaced by the empty string (``''``). For example, "
120 "consider the following template::"
121 msgstr "Si les métadonnées du champ pour un livre donné ne sont pas définies, le champ dans le modèle est remplacé par la chaîne vide (``''``). Par exemple, considérons le modèle suivant ::"
122
123 #: ../../../__w/calibre/calibre/manual/template_lang.rst:46
124 msgid ""
125 "If Asimov's book \"Second Foundation\" is in the series \"Foundation\" then "
126 "the template produces::"
127 msgstr "Si le livre d'Asimov \"Seconde Fondation\" fait partie de la série \"Fondation\", alors le modèle produit ::"
128
129 #: ../../../__w/calibre/calibre/manual/template_lang.rst:50
130 msgid ""
131 "If a series has not been entered for the book then the template produces::"
132 msgstr "Si aucune série n'a été saisie pour le livre, le modèle produit ::"
133
134 #: ../../../__w/calibre/calibre/manual/template_lang.rst:54
135 msgid ""
136 "The template processor automatically removes multiple slashes and leading or"
137 " trailing spaces."
138 msgstr "Le processeur de modèles supprime automatiquement les barres obliques multiples et les espaces avant ou arrière."
139
140 #: ../../../__w/calibre/calibre/manual/template_lang.rst:57
141 msgid "Advanced formatting"
142 msgstr "Mise en forme avancée"
143
144 #: ../../../__w/calibre/calibre/manual/template_lang.rst:59
145 msgid ""
146 "In addition to metadata substitution, templates can conditionally include "
147 "additional text and control how substituted data is formatted."
148 msgstr "Outre la substitution de métadonnées, les modèles peuvent inclure du texte supplémentaire de manière conditionnelle et contrôler le formatage des données substituées."
149
150 #: ../../../__w/calibre/calibre/manual/template_lang.rst:61
151 msgid "**Conditionally including text**"
152 msgstr "**Comprenant conditionnellement le texte**"
153
154 #: ../../../__w/calibre/calibre/manual/template_lang.rst:63
155 msgid ""
156 "Sometimes you want text to appear in the output only if a field is not "
157 "empty. A common case is ``series`` and ``series_index`` where you want "
158 "either nothing or the two values separated by a hyphen. calibre handles this"
159 " case using a special ``template expression`` syntax."
160 msgstr "Parfois, vous voulez que du texte n'apparaisse dans la sortie que si un champ n'est pas vide. Un cas courant est celui de ``series`` et ``series_index`` où vous voulez soit rien, soit les deux valeurs séparées par un trait d'union. calibre gère ce cas en utilisant une syntaxe spéciale de ``expression modèle``."
161
162 #: ../../../__w/calibre/calibre/manual/template_lang.rst:65
163 msgid ""
164 "For example and using the above Foundation example, assume you want the "
165 "template to produce `Foundation - 3 - Second Foundation`. This template "
166 "produces that output:"
167 msgstr "Par exemple, et en utilisant l'exemple de Fondation ci-dessus, supposons que vous voulez que le modèle produise `Fondation - 3 - Deuxième Fondation`. Ce modèle produit ce résultat :"
168
169 #: ../../../__w/calibre/calibre/manual/template_lang.rst:67
170 msgid "``{series} - {series_index} - {title}``"
171 msgstr "``{series} - {series_index} - {title}``"
172
173 #: ../../../__w/calibre/calibre/manual/template_lang.rst:69
174 msgid ""
175 "However, if a book has no series the template will produce `- - the title`, "
176 "which is probably not what you want. Generally, people want the result be "
177 "the title without the extraneous hyphens. You can accomplish this using the "
178 "following template syntax:"
179 msgstr "Cependant, si un livre n'a pas de série, le modèle produira `- - le titre`, ce qui n'est probablement pas ce que vous voulez. En général, les gens veulent que le résultat soit le titre sans les traits d'union superflus. Vous pouvez y parvenir en utilisant la syntaxe de modèle suivante :"
180
181 #: ../../../__w/calibre/calibre/manual/template_lang.rst:71
182 msgid "``{field:|prefix_text|suffix_text}``"
183 msgstr "``{field:|prefix_text|suffix_text}``"
184
185 #: ../../../__w/calibre/calibre/manual/template_lang.rst:73
186 msgid ""
187 "This ``template expression`` says that if ``field`` has the value `XXXX` "
188 "then the result will be `prefix_textXXXXXsuffix_text`. If ``field`` is empty"
189 " (has no value) then the result will be the empty string (nothing) because "
190 "the prefix and suffix are ignored. The prefix and suffix can contain blanks."
191 msgstr "Cette ``expression modèle`` indique que si ``champ`` a la valeur ``XXXX``, le résultat sera ``prefix_textXXXXXsuffix_text``. Si ``champ`` est vide (n'a pas de valeur) alors le résultat sera la chaîne vide (rien) car le préfixe et le suffixe sont ignorés. Le préfixe et le suffixe peuvent contenir des blancs."
192
193 #: ../../../__w/calibre/calibre/manual/template_lang.rst:75
194 msgid ""
195 "**Do not use subtemplates (`{ ... }`) or functions (see below) in the prefix"
196 " or the suffix.**"
197 msgstr "**Ne pas utiliser de sous-modèles (`{ ... }`) ou de fonctions (voir ci-dessous) dans le préfixe ou le suffixe.**"
198
199 #: ../../../__w/calibre/calibre/manual/template_lang.rst:77
200 msgid ""
201 "Using this syntax, we can solve the above no-series problem with the "
202 "template::"
203 msgstr "En utilisant cette syntaxe, nous pouvons résoudre le problème de non-série ci-dessus avec le modèle ::"
204
205 #: ../../../__w/calibre/calibre/manual/template_lang.rst:81
206 msgid ""
207 "The hyphens will be included only if the book has a series index, which it "
208 "has only if it has a series. Continuing the Foundation example again, the "
209 "template will produce `Foundation - 1 - Second Foundation`."
210 msgstr "Les traits d'union ne seront inclus que si le livre possède un index de série, ce qui n'est le cas que si le livre possède une série. Si l'on reprend l'exemple de Fondation, le modèle produira `Fondation - 1 - Deuxième Fondation`."
211
212 #: ../../../__w/calibre/calibre/manual/template_lang.rst:83
213 #: ../../../__w/calibre/calibre/manual/template_lang.rst:293
214 #: ../../../__w/calibre/calibre/manual/template_lang.rst:469
215 msgid "Notes:"
216 msgstr "Notes :"
217
218 #: ../../../__w/calibre/calibre/manual/template_lang.rst:85
219 msgid ""
220 "You must include the colon after the ``lookup name`` if you are using a "
221 "prefix or a suffix."
222 msgstr "Vous devez inclure les deux points après le ``nom de la recherche`` si vous utilisez un préfixe ou un suffixe."
223
224 #: ../../../__w/calibre/calibre/manual/template_lang.rst:86
225 msgid ""
226 "You must use either no or both ``|`` characters. Using one, as in ``{field:|"
227 " - }``, is not allowed."
228 msgstr ""
229
230 #: ../../../__w/calibre/calibre/manual/template_lang.rst:87
231 msgid ""
232 "It is OK to provide no text for either the prefix or the suffix, such as in "
233 "``{series:|| - }``. The template ``{title:||}`` is the same as ``{title}``."
234 msgstr "Il est possible de ne fournir aucun texte pour le préfixe ou le suffixe, comme dans ``{série:|| - }``. Le modèle ``{title:||}`` est le même que ``{title}``."
235
236 #: ../../../__w/calibre/calibre/manual/template_lang.rst:89
237 msgid "**Formatting**"
238 msgstr "**Formatage**"
239
240 #: ../../../__w/calibre/calibre/manual/template_lang.rst:91
241 msgid ""
242 "Suppose you want the ``series_index`` to be formatted as three digits with "
243 "leading zeros. This does the trick:"
244 msgstr "Supposons que vous vouliez que ``series_index`` soit formaté en trois chiffres avec des zéros en tête. Ceci fait l'affaire :"
245
246 #: ../../../__w/calibre/calibre/manual/template_lang.rst:93
247 msgid "``{series_index:0>3s}`` - Three digits with leading zeros"
248 msgstr "``{series_index:0>3s}`` - Trois chiffres avec des zéros en tête"
249
250 #: ../../../__w/calibre/calibre/manual/template_lang.rst:95
251 msgid "For trailing zeros, use:"
252 msgstr "Pour des zéros qui suivent, utilisez:"
253
254 #: ../../../__w/calibre/calibre/manual/template_lang.rst:97
255 msgid "``{series_index:0<3s}`` - Three digits with trailing zeros"
256 msgstr "``{series_index:0>3s}`` - Trois chiffres avec des zéros qui suivent"
257
258 #: ../../../__w/calibre/calibre/manual/template_lang.rst:99
259 msgid ""
260 "If you use series indices with fractional values, e.g., 1.1, you might want "
261 "the decimal points to line up. For example, you might want the indices 1 and"
262 " 2.5 to appear as 01.00 and 02.50 so that they will sort correctly on a "
263 "device that does lexical sorting. To do this, use:"
264 msgstr "Si vous utilisez des indices de série avec des valeurs fractionnées, par exemple 1.1, vous pouvez souhaiter que les points décimaux soient alignés. Par exemple, vous pouvez vouloir que les indices 1 et 2.5 apparaissent sous la forme 01.00 et 02.50 afin qu'ils soient triés correctement sur un périphérique qui effectue un tri lexical. Pour ce faire, utilisez :"
265
266 #: ../../../__w/calibre/calibre/manual/template_lang.rst:101
267 msgid ""
268 "``{series_index:0>5.2f}`` - Five characters consisting of two digits with "
269 "leading zeros, a decimal point, then 2 digits after the decimal point."
270 msgstr "``{series_index:0>5.2f}`` - Cinq caractères composés de deux chiffres avec des zéros en tête, un point décimal, puis deux chiffres après le point décimal."
271
272 #: ../../../__w/calibre/calibre/manual/template_lang.rst:103
273 msgid "If you want only the first two letters of the data, use:"
274 msgstr "Si vous ne voulez que les deux premières lettres de la donnée, utilisez :"
275
276 #: ../../../__w/calibre/calibre/manual/template_lang.rst:105
277 msgid ""
278 "``{author_sort:.2}`` - Only the first two letters of the author sort name"
279 msgstr "``{author_sort :.2}`` - Seulement les deux premières lettres du nom de tri de l'auteur"
280
281 #: ../../../__w/calibre/calibre/manual/template_lang.rst:107
282 msgid ""
283 "Much of the calibre template language formatting comes from Python. For more"
284 " details on the syntax of these advanced formatting operations see the "
285 "`Python documentation "
286 "<https://docs.python.org/3/library/string.html#formatstrings>`_."
287 msgstr "Une grande partie du formatage du langage de modèle de calibre provient de Python. Pour plus de détails sur la syntaxe de ces opérations de formatage avancées, voir la `documentation Python <https://docs.python.org/3/library/string.html#formatstrings>`"
288
289 #: ../../../__w/calibre/calibre/manual/template_lang.rst:111
290 msgid "Using templates to define custom columns"
291 msgstr "Utilisation de modèles pour définir des colonnes personnalisées"
292
293 #: ../../../__w/calibre/calibre/manual/template_lang.rst:113
294 msgid ""
295 "Templates can be used to display information that isn't in calibre metadata,"
296 " or to display metadata differently from calibre's normal format. For "
297 "example, you might want to show the ``ISBN``, a field that calibre does not "
298 "display. You can accomplish this creating a custom column with the type "
299 "`Column built from other columns` (hereafter called `composite columns`) and"
300 " providing a template to generate the displayed text. The column will "
301 "display the result of evaluating the template. For example, to display the "
302 "ISBN, create the column and enter ``{identifiers:select(isbn)}`` in the "
303 "template box. To display a column containing the values of two series custom"
304 " columns, separated by a comma, use ``{#series1:||,}{#series2}``."
305 msgstr "Les modèles peuvent être utilisés pour afficher des informations qui ne sont pas dans les métadonnées de calibre, ou pour afficher les métadonnées différemment du format normal de calibre. Par exemple, vous pourriez vouloir afficher le ``ISBN``, un champ que calibre n'affiche pas. Pour cela, vous pouvez créer une colonne personnalisée de type `Colonne construite à partir d'autres colonnes` (appelée ci-après `colonnes composites`) et fournir un modèle pour générer le texte affiché. La colonne affichera le résultat de l'évaluation du modèle. Par exemple, pour afficher l'ISBN, créez la colonne et entrez \"identifiers:select(isbn)}\" dans la champ du modèle. Pour afficher une colonne contenant les valeurs de deux colonnes personnalisées de séries, séparées par une virgule, utilisez ``{#series1:||,}{#series2}``."
306
307 #: ../../../__w/calibre/calibre/manual/template_lang.rst:115
308 msgid "Composite columns can use any template option, including formatting."
309 msgstr "Les colonnes composites peuvent utiliser n'importe quelle option modèle, y compris le formatage."
310
311 #: ../../../__w/calibre/calibre/manual/template_lang.rst:117
312 msgid ""
313 "Note: You cannot edit the data displayed in a composite column. Instead you "
314 "edit the source columns. If you edit a composite column, for example by "
315 "double-clicking it, calibre will open the template for editing, not the "
316 "underlying data."
317 msgstr "Remarque : Vous ne pouvez pas modifier les données affichées dans une colonne composite. Vous devez plutôt modifier les colonnes sources. Si vous modifiez une colonne composite, par exemple en double-cliquant dessus, calibre ouvrira le modèle à modifier, et non les données sous-jacentes."
318
319 #: ../../../__w/calibre/calibre/manual/template_lang.rst:121
320 msgid "Templates and plugboards"
321 msgstr "Modèles et tableaux de connexions"
322
323 #: ../../../__w/calibre/calibre/manual/template_lang.rst:123
324 msgid ""
325 "Plugboards are used for changing the metadata written into books during "
326 "send-to-device and save-to-disk operations. A plugboard permits you to "
327 "specify a template to provide the data to write into the book's metadata. "
328 "You can use plugboards to modify the following fields: authors, author_sort,"
329 " language, publisher, tags, title, title_sort. This feature helps people who"
330 " want to use different metadata in books on devices to solve sorting or "
331 "display issues."
332 msgstr "Les tableaux de connexions sont utilisés pour modifier les métadonnées écrites dans les livres pendant l'envoi à une liseuse et les opérations de sauvegarde sur le disque. Le tableau de connexion vous permet de spécifier pour un modèle de lecteur précis quelles données à insérer dans les métadonnées du livre. Vous pouvez utiliser les tableaux de connexions pour modifier les champs suivants : authors, author_sort, language, publisher, tags, title, title_sort. Cette fonctionnalité aide ceux qui veulent utiliser les différentes métadonnées des livres pour contrôler le tri ou l'affichage des livres sur leurs périphériques."
333
334 #: ../../../__w/calibre/calibre/manual/template_lang.rst:125
335 msgid ""
336 "When you create a plugboard, you specify the format and device for which the"
337 " plugboard is to be used. A special device is provided, ``save_to_disk``, "
338 "that is used when saving formats (as opposed to sending them to a device). "
339 "Once you have chosen the format and device, you choose the metadata fields "
340 "to change, providing templates to supply the new values. These templates are"
341 " `connected` to their destination fields, hence the name `plugboards`. You "
342 "can of course use composite columns in these templates."
343 msgstr "Lorsque vous créez un tableau de connexion, vous spécifiez le format et le périphérique pour lequel le tableau de connexion doit être utilisé. Un périphérique spécial est procuré, ``save_to_disk`` qui est utilisé lors de la sauvegarde de formats (en opposition à les envoyer vers le périphérique). Une fois que vous avez choisi le format et le périphérique, vous choisissez les champs de métadonnées à modifier, indiquez le modèle à appliquer pour fournir les nouvelles valeurs. Ces modèles sont `reliés` à leurs champs de destination, d'où le nom de `tableau de connexions`. Vous pouvez bien sûr utiliser des colonnes composites dans ces modèles."
344
345 #: ../../../__w/calibre/calibre/manual/template_lang.rst:127
346 msgid ""
347 "Plugboards are quite flexible and can be written in Single Function Mode, "
348 "Template Program Mode, General Program Mode, or Python Template mode."
349 msgstr ""
350
351 #: ../../../__w/calibre/calibre/manual/template_lang.rst:129
352 msgid ""
353 "When a plugboard might apply (Content server, save to disk, or send to "
354 "device), calibre searches the defined plugboards to choose the correct one "
355 "for the given format and device. For example, to find the appropriate "
356 "plugboard for an EPUB book being sent to an ANDROID device, calibre searches"
357 " the plugboards using the following search order:"
358 msgstr "Quand un tableau de connexion doit s'appliquer (Serveur de contenu, sauvegarde sur disque ou envoyer au périphérique), calibre recherche les tableau de connexions définis et celui qui est correct pour le format donné et le périphérique. Par exemple, pour trouver le tableau de connexion approprié pour un livre EPUB envoyé à un périphérique ANDROID, calibre recherche dans les tableaux de connexion dans l'ordre de recherche suivant :"
359
360 #: ../../../__w/calibre/calibre/manual/template_lang.rst:133
361 msgid ""
362 "a plugboard with an exact match on format and device, e.g., ``EPUB`` and "
363 "``ANDROID``"
364 msgstr "un tableau de connexion avec une correspondance exacte sur le format et le périphérique, par ex., ``EPUB`` et ``ANDROID``"
365
366 #: ../../../__w/calibre/calibre/manual/template_lang.rst:134
367 msgid ""
368 "a plugboard with an exact match on format and the special ``any device`` "
369 "choice, e.g., ``EPUB`` and ``any device``"
370 msgstr ""
371
372 #: ../../../__w/calibre/calibre/manual/template_lang.rst:135
373 msgid ""
374 "a plugboard with the special ``any format`` choice and an exact match on "
375 "device, e.g., ``any format`` and ``ANDROID``"
376 msgstr "un tableau de connexion avec le choix spécial ``n'importe quel format`` et une correspondance exacte sur le périphérique, par ex., ``n'importe quel format`` et ``ANDROID``"
377
378 #: ../../../__w/calibre/calibre/manual/template_lang.rst:136
379 msgid "a plugboard with ``any format`` and ``any device``"
380 msgstr ""
381
382 #: ../../../__w/calibre/calibre/manual/template_lang.rst:138
383 msgid ""
384 "The tags and authors fields have special treatment, because both of these "
385 "fields can hold more than one item. A book can have many tags and many "
386 "authors. When you specify that one of these two fields is to be changed, the"
387 " template's result is examined to see if more than one item is there. For "
388 "tags, the result is cut apart wherever calibre finds a comma. For example, "
389 "if the template produces the value ``Thriller, Horror``, then the result "
390 "will be two tags, ``Thriller`` and ``Horror``. There is no way to put a "
391 "comma in the middle of a tag."
392 msgstr "Les étiquettes et les champs auteur ont un traitement spécial, parce que ces deux champs peuvent contenir plusieurs données. Un livre peut avoir plusieurs étiquettes et plusieurs auteurs. Lorsque vous spécifiez que l'un de ces deux champs doit être modifié, le résultat du modèle est examiné pour voir s'il y a plus d'un élément dedans. Pour les étiquettes, le résultat est découpé partout où calibre trouve une virgule. Par exemple, si le modèle produit les valeurs ``Thriller, Horreur``, alors ke résultat sera deux étiquettes, ``Thriller`` et ``Horreur``. Il n'est pas possible de mettre une virgule au milieu d'une étiquette."
393
394 #: ../../../__w/calibre/calibre/manual/template_lang.rst:141
395 msgid ""
396 "The same thing happens for authors, but using a different character for the "
397 "cut, a `&` (ampersand) instead of a comma. For example, if the template "
398 "produces the value ``Blogs, Joe&Posts, Susan``, then the book will end up "
399 "with two authors, ``Blogs, Joe`` and ``Posts, Susan``. If the template "
400 "produces the value ``Blogs, Joe;Posts, Susan``, then the book will have one "
401 "author with a rather strange name."
402 msgstr "La même chose se produit pour les auteurs, mais en utilisant un caractère différent comme séparateur, le `&` (esperluette) au lieu d'une virgule. Par exemple, si le modèle produit la valeur ``Blogs, Joe&Posts, Susan``, alors le livre finira avec deux auteurs ``Blogs, Joe`` et ``Posts, Susan``. Si le modèle produit la valeur ``Blogs, Joe;Posts, Susan``, alors ce livre aura un auteur avec un nom assez étrange."
403
404 #: ../../../__w/calibre/calibre/manual/template_lang.rst:143
405 msgid ""
406 "Plugboards affect the metadata written into the book when it is saved to "
407 "disk or written to the device. Plugboards do not affect the metadata used by"
408 " ``save to disk`` and ``send to device`` to create the file names. Instead, "
409 "file names are constructed using the templates entered on the appropriate "
410 "preferences window."
411 msgstr ""
412
413 #: ../../../__w/calibre/calibre/manual/template_lang.rst:148
414 msgid "Using functions in templates - Single Function Mode"
415 msgstr "Utilisation des fonctions dans les modèles - Mode de fonctionnement unique"
416
417 #: ../../../__w/calibre/calibre/manual/template_lang.rst:150
418 msgid ""
419 "Suppose you want to display the value of a field in upper case when that "
420 "field is normally in title case. You can do this using `template functions`."
421 " For example, to display the title in upper case use the ``uppercase`` "
422 "function, as in ``{title:uppercase()}``. To display it in title case, use "
423 "``{title:titlecase()}``."
424 msgstr "Supposons que vous vouliez afficher la valeur d'un champ en casse majuscules alors que ce champ est normalement en casse titre. Vous pouvez le faire en utilisant les fonctions de modèle. Par exemple, pour afficher le titre en casse majuscules, utilisez la fonction ``uppercase``, comme dans ``{title:uppercase()}``. Pour l'afficher en casse titre, utilisez la fonction ``{title:titlecase()}``."
425
426 #: ../../../__w/calibre/calibre/manual/template_lang.rst:152
427 msgid ""
428 "Functions go into the format part of the template, after the ``:`` and "
429 "before the first ``|`` or the closing ``}`` if no prefix/suffix is used. If "
430 "you have both a format and a function reference, the function comes after a "
431 "second ``:``. Functions return the value of the column specified in the "
432 "template, suitably modified."
433 msgstr "Les fonctions sont placées dans la partie format du modèle, après le ``:`` et avant le premier ``|`` ou le ``}`` de fermeture si aucun préfixe/suffixe n'est utilisé. Si vous avez à la fois une référence de format et de fonction, la fonction vient après un deuxième ``:``. Les fonctions renvoient la valeur de la colonne spécifiée dans le modèle, convenablement modifiée."
434
435 #: ../../../__w/calibre/calibre/manual/template_lang.rst:154
436 msgid "The syntax for using functions is one of::"
437 msgstr "La syntaxe pour utiliser les fonctions est l'une des suivantes ::"
438
439 #: ../../../__w/calibre/calibre/manual/template_lang.rst:161
440 msgid ""
441 "Function names must always be followed by opening and closing parentheses. "
442 "Some functions require extra values (arguments), and these go inside the "
443 "parentheses. Arguments are separated by commas. Literal commas (commas as "
444 "text, not argument separators) must be preceded by a backslash (``\\``) . "
445 "The last (or only) argument cannot contain a textual closing parenthesis."
446 msgstr "Les noms de fonctions doivent toujours être suivis de parenthèses ouvrantes et fermantes. Certaines fonctions nécessitent des valeurs supplémentaires (arguments), qui sont placées à l'intérieur des parenthèses. Les arguments sont séparés par des virgules. Les virgules Littérales (les virgules en tant que texte, et non en tant que séparateurs d'arguments) doivent être précédées d'une barre oblique inversée (``\\``) . Le dernier (ou le seul) argument ne peut pas contenir de parenthèse fermante textuelle."
447
448 #: ../../../__w/calibre/calibre/manual/template_lang.rst:163
449 msgid ""
450 "Functions are evaluated before format specifications and the prefix/suffix. "
451 "See further down for an example of using both a format and a function."
452 msgstr "Les fonctions sont évaluées avant les spécifications de format et le préfixe/suffixe. Voir plus bas pour un exemple d'utilisation à la fois d'un format et d'une fonction."
453
454 #: ../../../__w/calibre/calibre/manual/template_lang.rst:165
455 msgid ""
456 "**Important**: If you have programming experience, please note that the "
457 "syntax in `Single Function Mode` is not what you expect. Strings are not "
458 "quoted and spaces are significant. All arguments are considered to be "
459 "constants; there are no expressions."
460 msgstr "**Important** : Si vous avez de l'expérience en programmation, veuillez noter que la syntaxe du `Mode Fonction Unique` n'est pas celle à laquelle vous vous attendez. Les chaînes de caractères ne sont pas citées et les espaces sont significatifs. Tous les arguments sont considérés comme des constantes ; il n'y a pas d'expressions."
461
462 #: ../../../__w/calibre/calibre/manual/template_lang.rst:167
463 msgid ""
464 "**Do not use subtemplates (`{ ... }`) as function arguments.** Instead, use "
465 ":ref:`Template Program Mode <template_mode>` and :ref:`General Program Mode "
466 "<general_mode>`."
467 msgstr "**N'utilisez pas les sous-modèles (`{ ... }`) comme arguments de fonction.** A la place, utilisez plutôt :ref:`Mode Programme Modèle` et :ref:`Mode Programme Général`."
468
469 #: ../../../__w/calibre/calibre/manual/template_lang.rst:169
470 msgid "Notes on calling functions in Single Function Mode:"
471 msgstr ""
472
473 #: ../../../__w/calibre/calibre/manual/template_lang.rst:171
474 msgid ""
475 "When functions are used in Single Function Mode, the first parameter, "
476 "``value``, is automatically replaced by the content of the field specified "
477 "in the template. For example, when the template ``{title:capitalize()}`` is "
478 "processed, the content of the ``title`` field is passed as the parameter "
479 "``value`` to the capitalize function."
480 msgstr ""
481
482 #: ../../../__w/calibre/calibre/manual/template_lang.rst:172
483 msgid ""
484 "In the function documentation, the notation ``[something]*`` means that "
485 "``something`` can be repeated zero or more times. The notation "
486 "``[something]+`` means that the ``something`` is repeated one or more times "
487 "(must exist at least one time)."
488 msgstr ""
489
490 #: ../../../__w/calibre/calibre/manual/template_lang.rst:173
491 msgid ""
492 "Some functions use regular expressions. In the template language regular "
493 "expression matching is case-insensitive."
494 msgstr ""
495
496 #: ../../../__w/calibre/calibre/manual/template_lang.rst:175
497 msgid ""
498 "Functions are documented in :ref:`template_functions_reference`. The "
499 "documentation tells you what arguments the functions require and what the "
500 "functions do. For example, here is the documentation of the "
501 ":ref:`ff_ifempty` function."
502 msgstr ""
503
504 #: ../../../__w/calibre/calibre/manual/template_lang.rst:179
505 msgid ""
506 "You see that the function requires two arguments, ``value`` and "
507 "``text_if_empty``. However, because we are using Single Function Mode, we "
508 "omit the ``value`` argument, passing only ``text_if_empty``. For example, "
509 "this template::"
510 msgstr ""
511
512 #: ../../../__w/calibre/calibre/manual/template_lang.rst:183
513 msgid ""
514 "shows the tags for a book, if any. If it has no tags then it shows `No tags "
515 "on this book`."
516 msgstr ""
517
518 #: ../../../__w/calibre/calibre/manual/template_lang.rst:185
519 msgid ""
520 "The following functions are usable in Single Function Mode because their "
521 "first parameter is ``value``."
522 msgstr ""
523
524 #: ../../../__w/calibre/calibre/manual/template_lang.rst:227
525 msgid "**Using functions and formatting in the same template**"
526 msgstr "**Utilisation des fonctions et du formatage dans le même modèle**"
527
528 #: ../../../__w/calibre/calibre/manual/template_lang.rst:229
529 msgid ""
530 "Suppose you have an integer custom column ``#myint`` that you want displayed"
531 " with leading zeros, as in ``003``. One way to do this is to use a format of"
532 " ``0>3s``. However, by default if a number (integer or float) equals zero "
533 "then the value is displayed as the empty string so zero values will produce "
534 "the empty string, not ``000``. If you want to see ``000`` values then you "
535 "use both the format string and the ``ifempty`` function to change the empty "
536 "value back to a zero. The template would be::"
537 msgstr "Supposons que vous ayez une colonne personnalisée de nombres entiers, ``##myint``, que vous voulez afficher avec des zéros en tête, comme dans ``003``. Une façon de le faire est d'utiliser le format ``0>3s``. Cependant, par défaut, si un nombre (entier ou flottant) est égal à zéro, la valeur est affichée sous la forme d'une chaîne vide, de sorte que les valeurs nulles produiront la chaîne vide, et non ``000``. Si vous voulez voir les valeurs ``000``, vous devez utiliser à la fois la chaîne de format et la fonction ``ifempty`` pour transformer la valeur vide en zéro. Le modèle serait ::"
538
539 #: ../../../__w/calibre/calibre/manual/template_lang.rst:233
540 msgid ""
541 "Note that you can use the prefix and suffix as well. If you want the number "
542 "to appear as ``[003]`` or ``[000]``, then use the template::"
543 msgstr "Notez que vous pouvez également utiliser le préfixe et le suffixe. Si vous voulez que le numéro apparaisse sous la forme ``[003]`` ou ``[000]``, utilisez alors le modèle ::"
544
545 #: ../../../__w/calibre/calibre/manual/template_lang.rst:240
546 msgid "General Program Mode"
547 msgstr "Mode Programme Général"
548
549 #: ../../../__w/calibre/calibre/manual/template_lang.rst:242
550 msgid ""
551 "`General Program Mode` (`GPM`) replaces `template expressions` with a "
552 "program written in the `template language`. The syntax of the language is "
553 "defined by the following grammar::"
554 msgstr "Le `Mode Programme Général` (`MPG`) remplace les `expressions modèles` par un programme écrit dans le `langage modèle`. La syntaxe de ce langage est définie par la grammaire suivante ::"
555
556 #: ../../../__w/calibre/calibre/manual/template_lang.rst:295
557 msgid ""
558 "a ``top_expression`` always has a value. The value of an ``expression_list``"
559 " is the value of the last ``top_expression`` in the list. For example, the "
560 "value of the expression list ``1;2;'foobar';3`` is ``3``."
561 msgstr "une ``top_expression`` a toujours une valeur. La valeur d'une ``expression_list`` est la valeur de la dernière ``top_expression`` Par exemple, la valeur de la liste d'expressions ``1;2;'foobar';3`` est ``3``."
562
563 #: ../../../__w/calibre/calibre/manual/template_lang.rst:296
564 msgid "In a logical context, any non-empty value is ``True``"
565 msgstr "Dans un contexte logique, toute valeur non vide est ``True``."
566
567 #: ../../../__w/calibre/calibre/manual/template_lang.rst:297
568 msgid "In a logical context, the empty value is ``False``"
569 msgstr "Dans un contexte logique, la valeur vide est ``False``."
570
571 #: ../../../__w/calibre/calibre/manual/template_lang.rst:298
572 msgid ""
573 "Strings and numbers can be used interchangeably. For example, ``10`` and "
574 "``'10'`` are the same thing."
575 msgstr "Les chaînes de caractères et les nombres peuvent être utilisés indifféremment. Par exemple, ``10`` et ``'10'`` sont la même chose."
576
577 #: ../../../__w/calibre/calibre/manual/template_lang.rst:299
578 msgid ""
579 "Comments are lines starting with a '#' character, possibly preceded by "
580 "blanks or tabs."
581 msgstr ""
582
583 #: ../../../__w/calibre/calibre/manual/template_lang.rst:301
584 msgid "**Operator precedence**"
585 msgstr "**Préséance de l'opérateur**"
586
587 #: ../../../__w/calibre/calibre/manual/template_lang.rst:303
588 msgid ""
589 "The operator precedence (order of evaluation) from highest (evaluated first)"
590 " to lowest (evaluated last) is:"
591 msgstr "L'ordre de préséance de l'opérateurs (ordre d'évaluation), du plus élevé (évalué en premier) au plus bas (évalué en dernier), est le suivant :"
592
593 #: ../../../__w/calibre/calibre/manual/template_lang.rst:305
594 msgid ""
595 "Function calls, constants, parenthesized expressions, statement expressions,"
596 " assignment expressions, field references."
597 msgstr "Appels de fonctions, constantes, expressions entre parenthèses, expressions d'instructions, expressions d'affectation, références de champs."
598
599 #: ../../../__w/calibre/calibre/manual/template_lang.rst:306
600 msgid ""
601 "Unary plus (``+``) and minus (``-``). These operators evaluate right to "
602 "left."
603 msgstr "Les opérateurs unaires plus (``+``) et moins (``-``). Ces opérateurs s'évaluent de droite à gauche."
604
605 #: ../../../__w/calibre/calibre/manual/template_lang.rst:308
606 msgid ""
607 "These and all the other arithmetic operators return integers if the "
608 "expression results in a fractional part equal to zero. For example, if an "
609 "expression returns ``3.0`` it is changed to ``3``."
610 msgstr "Ces opérateurs et tous les autres opérateurs arithmétiques renvoient des entiers si l'expression donne une partie fractionnaire égale à zéro. Par exemple, si une expression renvoie ``3.0``, elle est transformée en ``3``."
611
612 #: ../../../__w/calibre/calibre/manual/template_lang.rst:309
613 msgid ""
614 "Multiply (``*``) and divide (``/``). These operators are associative and "
615 "evaluate left to right. Use parentheses if you want to change the order of "
616 "evaluation."
617 msgstr "Multiplier (``*``) et diviser (``/``). Ces opérateurs sont associatifs et s'évaluent de gauche à droite. Utilisez les parenthèses si vous souhaitez modifier l'ordre d'évaluation."
618
619 #: ../../../__w/calibre/calibre/manual/template_lang.rst:310
620 msgid ""
621 "Add (``+``) and subtract (``-``). These operators are associative and "
622 "evaluate left to right."
623 msgstr "Additionner (``+``) et soustraire (``-``). Ces opérateurs sont associatifs et s'évaluent de gauche à droite."
624
625 #: ../../../__w/calibre/calibre/manual/template_lang.rst:311
626 msgid ""
627 "Numeric and string comparisons. These operators return ``'1'`` if the "
628 "comparison succeeds, otherwise the empty string (``''``). Comparisons are "
629 "not associative: ``a < b < c`` is a syntax error."
630 msgstr "Comparaisons de nombres et de chaînes de caractères. Ces opérateurs renvoient ``'1'`` si la comparaison réussit, sinon la chaîne vide (``''``). Les comparaisons ne sont pas associatives : ``a < b < c`` est une erreur de syntaxe."
631
632 #: ../../../__w/calibre/calibre/manual/template_lang.rst:312
633 msgid ""
634 "String concatenation (``&``). The ``&`` operator returns a string formed by "
635 "concatenating the left-hand and right-hand expressions. Example: ``'aaa' & "
636 "'bbb'`` returns ``'aaabbb'``. The operator is associative and evaluates left"
637 " to right."
638 msgstr "Concaténation de chaînes de caractères (``&``). L'opérateur ``&`` renvoie une chaîne de caractères formée par la concaténation des expressions de gauche et de droite. Exemple : \" 'aaa' & 'bbb'`` renvoie \" 'aaabbb'``. L'opérateur est associatif et s'évalue de gauche à droite."
639
640 #: ../../../__w/calibre/calibre/manual/template_lang.rst:313
641 msgid ""
642 "Unary logical not (``!``). This operator returns ``'1'`` if the expression "
643 "is False (evaluates to the empty string), otherwise ``''``."
644 msgstr "Unaire non logique (``!``). Cet opérateur renvoie ``'1'`` si l'expression est fausse (évaluée à la chaîne vide), sinon ``''``."
645
646 #: ../../../__w/calibre/calibre/manual/template_lang.rst:314
647 msgid ""
648 "Logical and (``&&``). This operator returns '1' if both the left-hand and "
649 "right-hand expressions are True, or the empty string ``''`` if either is "
650 "False. It is associative, evaluates left to right, and does `short-"
651 "circuiting <https://chortle.ccsu.edu/java5/Notes/chap40/ch40_2.html>`_."
652 msgstr "L'opérateur logique et (``&&``). Cet opérateur renvoie '1' si les deux expressions de gauche et de droite sont vraies, ou la chaîne vide ``''`` si l'une ou l'autre est fausse. Il est associatif, s'évalue de gauche à droite, et fait du `court-circuitage <https://chortle.ccsu.edu/java5/Notes/chap40/ch40_2.html>`_."
653
654 #: ../../../__w/calibre/calibre/manual/template_lang.rst:315
655 msgid ""
656 "Logical or (``||``). This operator returns ``'1'`` if either the left-hand "
657 "or right-hand expression is True, or ``''`` if both are False. It is "
658 "associative, evaluates left to right, and does `short-circuiting "
659 "<https://chortle.ccsu.edu/java5/Notes/chap40/ch40_2.html>`_. It is an "
660 "`inclusive or`, returning ``'1'`` if both the left- and right-hand "
661 "expressions are True."
662 msgstr "Logique ou (``||``). Cet opérateur renvoie ``'1'`` si l'expression de gauche ou de droite est vraie, ou ``''`` si les deux sont fausses. Il est associatif, s'évalue de gauche à droite, et fait du `court-circuitage <https://chortle.ccsu.edu/java5/Notes/chap40/ch40_2.html>`_. C'est un `or inclusif`, qui renvoie \"1\" si les deux expressions de gauche et de droite sont vraies."
663
664 #: ../../../__w/calibre/calibre/manual/template_lang.rst:317
665 msgid "**Field references**"
666 msgstr "**Références des champs**"
667
668 #: ../../../__w/calibre/calibre/manual/template_lang.rst:319
669 msgid ""
670 "A ``field_reference`` evaluates to the value of the metadata field named by "
671 "lookup name that follows the ``$`` or ``$$``. Using ``$`` is equivalent to "
672 "using the :ref:`ff_field` function. Using ``$$`` is equivalent to using the "
673 ":ref:`ff_raw_field` function. Examples::"
674 msgstr ""
675
676 #: ../../../__w/calibre/calibre/manual/template_lang.rst:326
677 msgid "**If expressions**"
678 msgstr "**Expressions if**"
679
680 #: ../../../__w/calibre/calibre/manual/template_lang.rst:328
681 msgid ""
682 "``If`` expressions first evaluate the ``condition``. If the ``condition`` is"
683 " True (a non-empty value) then the ``expression_list`` in the ``then`` "
684 "clause is evaluated. If it is False then if present the ``expression_list`` "
685 "in the ``elif`` or ``else`` clause is evaluated. The ``elif`` and ``else`` "
686 "parts are optional. The words ``if``, ``then``, ``elif``, ``else``, and "
687 "``fi`` are reserved; you cannot use them as identifier names. You can put "
688 "newlines and white space wherever they make sense. The ``condition`` is a "
689 "``top_expression`` not an ``expression_list``; semicolons are not allowed. "
690 "The ``expression_lists`` are semicolon-separated sequences of "
691 "``top_expressions``. An ``if`` expression returns the result of the last "
692 "``top_expression`` in the evaluated ``expression_list``, or the empty string"
693 " if no expression list was evaluated."
694 msgstr "Les expressions ``If`` évaluent d'abord la ``condition``. Si la ``condition`` est True (une valeur non vide), alors ``expression_list`` de la clause ``then`` est évaluée. Si elle est False, ``expression_list`` de la clause ``elif`` ou ``else`` est évaluée si elle est présente. Les parties ``if`` et ``else`` sont facultatives. Les mots ``if ``, ``then``, ``elif ``, ``else`` et ``fi`` sont réservés ; vous ne pouvez pas les utiliser comme noms d'identifiants. Vous pouvez mettre des retours à la ligne et des espaces partout où cela a un sens. La ``condition`` est une ``top_expression`` et non une ``expression_list`` ; les points-virgules ne sont pas autorisés. Les ``expression_list`` sont des séquences de ``top_expressions`` séparées par des points-virgules. Une expression ``if`` renvoie le résultat de la dernière ``top_expressions`` de la ``top_expression`` évaluée, ou la chaîne vide si aucune liste d'expression n'a été évaluée."
695
696 #: ../../../__w/calibre/calibre/manual/template_lang.rst:330
697 msgid "Examples::"
698 msgstr "Exemples::"
699
700 #: ../../../__w/calibre/calibre/manual/template_lang.rst:343
701 msgid "Nested ``if`` example::"
702 msgstr "Exemple de ``if`` imbriqué::"
703
704 #: ../../../__w/calibre/calibre/manual/template_lang.rst:356
705 msgid ""
706 "As said above, an ``if`` produces a value. This means that all the following"
707 " are equivalent::"
708 msgstr "Comme dit plus haut, un ``if`` produit une valeur. Cela signifie que tous les cas suivants sont équivalents ::"
709
710 #: ../../../__w/calibre/calibre/manual/template_lang.rst:362
711 msgid ""
712 "For example, this program returns the value of the ``series`` column if the "
713 "book has a series, otherwise the value of the ``title`` column::"
714 msgstr ""
715
716 #: ../../../__w/calibre/calibre/manual/template_lang.rst:366
717 msgid "**For expressions**"
718 msgstr "**Expressions for**"
719
720 #: ../../../__w/calibre/calibre/manual/template_lang.rst:368
721 msgid ""
722 "The ``for`` expression iterates over a list of values, processing them one "
723 "at a time. The ``list_expression`` must evaluate either to a metadata field "
724 "``lookup name`` e.g., ``tags`` or ``#genre``, or to a list of values. The "
725 ":ref:`ff_range` generates a list of numbers. If the result is a valid "
726 "``lookup name`` then the field's value is fetched and the separator "
727 "specified for that field type is used. If the result isn't a valid lookup "
728 "name then it is assumed to be a list of values. The list is assumed to be "
729 "separated by commas unless the optional keyword ``separator`` is supplied, "
730 "in which case the list values must be separated by the result of evaluating "
731 "the ``separator_expr``. A separator cannot be used if the list is generated "
732 "by ``range()``. Each value in the list is assigned to the specified variable"
733 " then the ``expression_list`` is evaluated. You can use ``break`` to jump "
734 "out of the loop, and ``continue`` to jump to the beginning of the loop for "
735 "the next iteration."
736 msgstr ""
737
738 #: ../../../__w/calibre/calibre/manual/template_lang.rst:370
739 msgid ""
740 "Example: This template removes the first hierarchical name for each value in"
741 " Genre (``#genre``), constructing a list with the new names::"
742 msgstr "Exemple : Ce modèle supprime le premier nom hiérarchique pour chaque valeur dans le genre (``#genre``), en construisant une liste avec les nouveaux noms ::"
743
744 #: ../../../__w/calibre/calibre/manual/template_lang.rst:380
745 msgid ""
746 "If the original Genre is `History.Military, Science Fiction.Alternate "
747 "History, ReadMe` then the template returns `Military, Alternate History, "
748 "ReadMe`. You could use this template in calibre's :guilabel:`Edit metadata "
749 "in bulk -> Search & replace` with :guilabel:`Search for` set to ``template``"
750 " to strip off the first level of the hierarchy and assign the resulting "
751 "value to Genre."
752 msgstr "Si le Genre original est `Histoire.Militaire, Science Fiction.Histoire alternative, Lisez-moi`, alors le modèle renvoie `Militaire, Histoire alternative, Lisez-moi`. Vous pouvez utiliser ce modèle dans le calibre :guilabel:`Modifier les métadonnées par lot -> Rechercher & remplacer` avec :guilabel:`Rechercher après` défini à ``modèe`` pour supprimer le premier niveau de la hiérarchie et attribuer la valeur résultante à Genre."
753
754 #: ../../../__w/calibre/calibre/manual/template_lang.rst:383
755 msgid ""
756 "Note: the last line in the template, ``new_tags``, isn't strictly necessary "
757 "in this case because ``for`` returns the value of the last top_expression in"
758 " the expression list. The value of an assignment is the value of its "
759 "expression, so the value of the ``for`` statement is what was assigned to "
760 "``new_tags``."
761 msgstr "Note : la dernière ligne du modèle, ``new_tags``, n'est pas strictement nécessaire dans ce cas car ``for`` renvoie la valeur de la dernière top_expression de la liste d'expressions. La valeur d'une affectation est la valeur de son expression, donc la valeur de l'instruction ``for`` est ce qui a été affecté à ``new_tags``."
762
763 #: ../../../__w/calibre/calibre/manual/template_lang.rst:385
764 msgid "**with expressions**"
765 msgstr ""
766
767 #: ../../../__w/calibre/calibre/manual/template_lang.rst:387
768 msgid "The ``with`` expression:"
769 msgstr ""
770
771 #: ../../../__w/calibre/calibre/manual/template_lang.rst:389
772 msgid ""
773 "changes the current book to the book with calibre book id (an integer) "
774 "produced by evaluating the ``top_expression``."
775 msgstr ""
776
777 #: ../../../__w/calibre/calibre/manual/template_lang.rst:390
778 msgid "runs the ``expression_list``."
779 msgstr ""
780
781 #: ../../../__w/calibre/calibre/manual/template_lang.rst:391
782 msgid "then resets the current book back to what it was."
783 msgstr ""
784
785 #: ../../../__w/calibre/calibre/manual/template_lang.rst:393
786 msgid ""
787 "The ``with`` expression returns the result of the last ``top_expression`` in"
788 " the evaluated ``expression_list``, or the empty string if no expression "
789 "list was evaluated."
790 msgstr ""
791
792 #: ../../../__w/calibre/calibre/manual/template_lang.rst:396
793 msgid ""
794 "For example, this template returns a list of the titles of each book "
795 "selected in the GUI::"
796 msgstr ""
797
798 #: ../../../__w/calibre/calibre/manual/template_lang.rst:408
799 msgid "**Return stmt**"
800 msgstr ""
801
802 #: ../../../__w/calibre/calibre/manual/template_lang.rst:410
803 msgid ""
804 "Return the value of the ``expression``. If executed in a function then it "
805 "returns the value of the expression to the caller. If executed in the "
806 "outermost context (the template) then it sets the value of the template to "
807 "the value of the expression and exits the template."
808 msgstr ""
809
810 #: ../../../__w/calibre/calibre/manual/template_lang.rst:412
811 msgid "**Function definition**"
812 msgstr "**Définition de la fonction**"
813
814 #: ../../../__w/calibre/calibre/manual/template_lang.rst:414
815 msgid ""
816 "If you have repeated code in a template then you can put that code into a "
817 "local function. The ``def`` keyword starts the definition. It is followed by"
818 " the function name, the argument list, then the code in the function. The "
819 "function definition ends with the ``fed`` keyword."
820 msgstr ""
821
822 #: ../../../__w/calibre/calibre/manual/template_lang.rst:416
823 msgid ""
824 "Arguments are positional. When a function is called the supplied arguments "
825 "are matched left to right against the defined parameters, with the value of "
826 "the argument assigned to the parameter. It is an error to provide more "
827 "arguments than defined parameters. Parameters can have default values, such "
828 "as ``a = 25``. If an argument is not supplied for that parameter then the "
829 "default value is used, otherwise the parameter is set to the empty string."
830 msgstr "Les arguments sont positionnels. Lorsqu'une fonction est appelée, les arguments fournis sont comparés de gauche à droite aux paramètres définis, la valeur de l'argument étant attribuée au paramètre. C'est une erreur de fournir plus d'arguments que de paramètres définis. Les paramètres peuvent avoir des valeurs par défaut, comme \"a = 25\". Si un argument n'est pas fourni pour ce paramètre, alors la valeur par défaut est utilisée, sinon le paramètre est défini par la chaîne vide."
831
832 #: ../../../__w/calibre/calibre/manual/template_lang.rst:418
833 msgid "The ``return`` statement can be used in a local function."
834 msgstr "L'instruction ``return`` peut être utilisée dans une fonction locale."
835
836 #: ../../../__w/calibre/calibre/manual/template_lang.rst:420
837 msgid "A function must be defined before it can be used."
838 msgstr "Une fonction doit être définie avant de pouvoir être utilisée."
839
840 #: ../../../__w/calibre/calibre/manual/template_lang.rst:422
841 msgid ""
842 "Example: This template computes an approximate duration in years, months, "
843 "and days from a number of days. The function ``to_plural()`` formats the "
844 "computed values. Note that the example also uses the ``&`` operator::"
845 msgstr "Exemple : Ce modèle calcule une durée approximative en années, mois et jours à partir d'un nombre de jours. La fonction ``to_plural()`` met en forme les valeurs calculées. Notez que l'exemple utilise également l'opérateur ``&``::"
846
847 #: ../../../__w/calibre/calibre/manual/template_lang.rst:437
848 msgid "**Relational operators**"
849 msgstr "**Opérateurs relationnels**"
850
851 #: ../../../__w/calibre/calibre/manual/template_lang.rst:439
852 msgid ""
853 "Relational operators return ``'1'`` if the comparison is true, otherwise the"
854 " empty string (``''``)."
855 msgstr ""
856
857 #: ../../../__w/calibre/calibre/manual/template_lang.rst:441
858 msgid ""
859 "There are two forms of relational operators: string comparisons and numeric "
860 "comparisons."
861 msgstr "Il existe deux formes d'opérateurs relationnels : les comparaisons de chaînes de caractères et les comparaisons numériques."
862
863 #: ../../../__w/calibre/calibre/manual/template_lang.rst:443
864 msgid ""
865 "String comparisons do case-insensitive string comparison using lexical "
866 "order. The supported string comparison operators are ``==``, ``!=``, ``<``, "
867 "``<=``, ``>``, ``>=``, ``in``, ``inlist``, and ``inlist_field``. For the "
868 "``in``, ``inlist``, and ``inlist_field`` operators, the result of the left "
869 "hand expression is interpreted as a regular expression pattern. They are "
870 "true if the value of left-hand regular expression matches the value of the "
871 "right hand expression. The regular expressions are case-insensitive."
872 msgstr ""
873
874 #: ../../../__w/calibre/calibre/manual/template_lang.rst:446
875 msgid ""
876 "The ``inlist`` operator is true if the left hand regular expression matches "
877 "any one of the items in the right hand list where the items in the list are "
878 "separated by commas. The ``inlist_field`` operator is true if the left hand "
879 "regular expression matches any of the items in the field (column) named by "
880 "the right hand expression, using the separator defined for the field. NB: "
881 "the ``inlist_field`` operator requires the right hand expression to evaluate"
882 " to a field name, while the ``inlist`` operator requires the right hand "
883 "expression to evaluate to a string containing a comma-separated list. "
884 "Because of this difference, ``inlist_field`` is substantially faster than "
885 "``inlist`` because no string conversions or list constructions are done."
886 msgstr ""
887
888 #: ../../../__w/calibre/calibre/manual/template_lang.rst:448
889 msgid ""
890 "The numeric comparison operators are ``==#``, ``!=#``, ``<#``, ``<=#``, "
891 "``>#``, ``>=#``. The left and right expressions must evaluate to numeric "
892 "values with two exceptions: both the string value \"None\" (undefined field)"
893 " and the empty string evaluate to the value zero."
894 msgstr "Les opérateurs de comparaison numérique sont ``==#``, ``!=#``, ``<#``, ``<=#``, ``>#``, ``>=#``. Les expressions de gauche et de droite doivent être évaluées par des valeurs numériques, à deux exceptions près : la chaîne de caractères \"None\" (champ indéfini) et la chaîne de caractères vide sont évaluées par la valeur zéro."
895
896 #: ../../../__w/calibre/calibre/manual/template_lang.rst:450
897 msgid "Examples:"
898 msgstr "Exemples : "
899
900 #: ../../../__w/calibre/calibre/manual/template_lang.rst:452
901 msgid ""
902 "``program: field('series') == 'foo'`` returns ``'1'`` if the book's series "
903 "is `foo`, otherwise ``''``."
904 msgstr ""
905
906 #: ../../../__w/calibre/calibre/manual/template_lang.rst:453
907 msgid ""
908 "``program: 'f.o' in field('series')`` returns ``'1'`` if the book's series "
909 "matches the regular expression ``f.o`` (e.g., `foo`, `Off Onyx`, etc.), "
910 "otherwise ``''``."
911 msgstr "``Program: 'f.o' in field('series')`` renvoie `'1'`` si la série du livre correspond à l'expression régulière ``f.o`` (par exemple, `foo`, `Off Onyx`, etc.), sinon ``''``."
912
913 #: ../../../__w/calibre/calibre/manual/template_lang.rst:454
914 msgid ""
915 "``program: 'science' inlist $#genre`` returns ``'1'`` if any of the values "
916 "retrieved from the book's genres match the regular expression ``science``, "
917 "e.g., `Science`, `History of Science`, `Science Fiction` etc., otherwise "
918 "``''``."
919 msgstr ""
920
921 #: ../../../__w/calibre/calibre/manual/template_lang.rst:455
922 msgid ""
923 "``program: '^science$' inlist $#genre`` returns ``'1'`` if any of the book's"
924 " genres exactly match the regular expression ``^science$``, e.g., `Science`,"
925 " otherwise ``''``. The genres `History of Science` and `Science Fiction` "
926 "don't match."
927 msgstr ""
928
929 #: ../../../__w/calibre/calibre/manual/template_lang.rst:456
930 msgid ""
931 "``program: 'asimov' inlist $authors`` returns ``'1'`` if any author matches "
932 "the regular expression ``asimov``, e.g., `Asimov, Isaac` or `Isaac Asimov`, "
933 "otherwise ``''``."
934 msgstr ""
935
936 #: ../../../__w/calibre/calibre/manual/template_lang.rst:457
937 msgid ""
938 "``program: 'asimov' inlist_field 'authors'`` returns ``'1'`` if any author "
939 "matches the regular expression ``asimov``, e.g., `Asimov, Isaac` or `Isaac "
940 "Asimov`, otherwise ``''``."
941 msgstr ""
942
943 #: ../../../__w/calibre/calibre/manual/template_lang.rst:458
944 msgid ""
945 "``program: 'asimov$' inlist_field 'authors'`` returns ``'1'`` if any author "
946 "matches the regular expression ``asimov$``, e.g., `Isaac Asimov`, otherwise "
947 "``''``. It doesn't match `Asimov, Isaac` because of the ``$`` anchor in the "
948 "regular expression."
949 msgstr ""
950
951 #: ../../../__w/calibre/calibre/manual/template_lang.rst:459
952 msgid ""
953 "``program: if field('series') != 'foo' then 'bar' else 'mumble' fi`` returns"
954 " ``'bar'`` if the book's series is not `foo`. Otherwise it returns "
955 "``'mumble'``."
956 msgstr ""
957
958 #: ../../../__w/calibre/calibre/manual/template_lang.rst:460
959 msgid ""
960 "``program: if field('series') == 'foo' || field('series') == '1632' then "
961 "'yes' else 'no' fi`` returns ``'yes'`` if series is either `foo` or `1632`, "
962 "otherwise ``'no'``."
963 msgstr ""
964
965 #: ../../../__w/calibre/calibre/manual/template_lang.rst:461
966 msgid ""
967 "``program: if '^(foo|1632)$' in field('series') then 'yes' else 'no' fi`` "
968 "returns ``'yes'`` if series is either `foo` or `1632`, otherwise ``'no'``."
969 msgstr ""
970
971 #: ../../../__w/calibre/calibre/manual/template_lang.rst:462
972 msgid ""
973 "``program: if 11 > 2 then 'yes' else 'no' fi`` returns ``'no'`` because the "
974 "``>`` operator does a lexical comparison."
975 msgstr "``program: if '11' > '2' then 'yes' else 'no' fi`` `renvoie ``'no'`` parce que l'opérateur ``>`` fait une comparaison lexicale."
976
977 #: ../../../__w/calibre/calibre/manual/template_lang.rst:463
978 msgid ""
979 "``program: if 11 ># 2 then 'yes' else 'no' fi`` returns ``'yes'`` because "
980 "the ``>#`` operator does a numeric comparison."
981 msgstr "``Program: if 11 ># 2 then 'yes' else 'no' fi`` renvoie ``'yes'`` parce que l'opérateur ``>#`` effectue une comparaison numérique."
982
983 #: ../../../__w/calibre/calibre/manual/template_lang.rst:465
984 msgid "**Functions in General Program Mode**"
985 msgstr ""
986
987 #: ../../../__w/calibre/calibre/manual/template_lang.rst:467
988 msgid ""
989 "See :ref:`template_functions_reference` for the list of functions built into"
990 " the template language."
991 msgstr ""
992
993 #: ../../../__w/calibre/calibre/manual/template_lang.rst:471
994 msgid ""
995 "As opposed to :ref:`Single Function Mode <single_mode>`, in General Program "
996 "Mode you must specify the first parameter ``value``."
997 msgstr ""
998
999 #: ../../../__w/calibre/calibre/manual/template_lang.rst:472
1000 msgid "All parameters are expression_lists (see the grammar above)."
1001 msgstr ""
1002
1003 #: ../../../__w/calibre/calibre/manual/template_lang.rst:477
1004 msgid "More complex programs in template expressions - Template Program Mode"
1005 msgstr "Programmes plus complexes dans les expressions modèles - Mode Programme de Modèles"
1006
1007 #: ../../../__w/calibre/calibre/manual/template_lang.rst:479
1008 msgid ""
1009 "`Template Program Mode` (`TPM`) is a blend of :ref:`General Program Mode "
1010 "<general_mode>` and :ref:`Single Function Mode <single_mode>`. `TPM` differs"
1011 " from Single Function Mode in that it permits writing template expressions "
1012 "that refer to other metadata fields, use nested functions, modify variables,"
1013 " and do arithmetic. It differs from `General Program Mode` in that the "
1014 "template is contained between ``{`` and ``}`` characters and doesn't begin "
1015 "with the word ``program:``. The program portion of the template is a General"
1016 " Program Mode expression list."
1017 msgstr "Le `Mode Programme de Modèle` (`MPM`) est un mélange du :ref:`Mode de Programme Général<general_mode>` et du :ref:`Mode Fonction Unique<single_mode>`. Le `MPM` diffère du Mode Fonction Unique en ce qu'il permet d'écrire des expressions de modèle qui font référence à d'autres champs de métadonnées, utilisent des fonctions imbriquées, modifient des variables et font de l'arithmétique. Il diffère du `Mode Programme Général` en ce que le modèle est contenu entre les caractères `{`` et ``}`` et ne commence pas par le mot ``program:``. La partie programme du modèle est une liste d'expressions du Mode Programme Général."
1018
1019 #: ../../../__w/calibre/calibre/manual/template_lang.rst:482
1020 msgid ""
1021 "Example: assume you want a template to show the series for a book if it has "
1022 "one, otherwise show the value of a custom field #genre. You cannot do this "
1023 "in the :ref:`Single Function Mode <single_mode>` because you cannot make "
1024 "reference to another metadata field within a template expression. In `TPM` "
1025 "you can, as the following expression demonstrates::"
1026 msgstr "Exemple : supposons que vous vouliez qu'un modèle affiche la série d'un livre s'il en a une, sinon la valeur d'un champ personnalisé #genre. Vous ne pouvez pas faire cela dans le mode :ref:`Mode Fonction Unique<single_mode>` car vous ne pouvez pas faire référence à un autre champ de métadonnées dans une expression de modèle. En `MPM`, vous le pouvez, comme le montre l'expression suivante ::"
1027
1028 #: ../../../__w/calibre/calibre/manual/template_lang.rst:487
1029 msgid "The example shows several things:"
1030 msgstr "L'exemple montre plusieurs choses :"
1031
1032 #: ../../../__w/calibre/calibre/manual/template_lang.rst:489
1033 msgid ""
1034 "`TPM` is used if the expression begins with ``:'`` and ends with ``'}``. "
1035 "Anything else is assumed to be in :ref:`Single Function Mode <single_mode>`."
1036 msgstr ""
1037
1038 #: ../../../__w/calibre/calibre/manual/template_lang.rst:491
1039 msgid ""
1040 "If the template contains a prefix and suffix, the expression ends with "
1041 "``'|`` where the ``|`` is the delimiter for the prefix. Example::"
1042 msgstr ""
1043
1044 #: ../../../__w/calibre/calibre/manual/template_lang.rst:495
1045 msgid ""
1046 "Functions must be given all their arguments. For example, the standard "
1047 "built-in functions must be given the initial parameter ``value``."
1048 msgstr ""
1049
1050 #: ../../../__w/calibre/calibre/manual/template_lang.rst:496
1051 msgid ""
1052 "The variable ``$`` is usable as the ``value`` argument and stands for the "
1053 "value of the field named in the template, ``series`` in this case."
1054 msgstr ""
1055
1056 #: ../../../__w/calibre/calibre/manual/template_lang.rst:497
1057 msgid "white space is ignored and can be used anywhere within the expression."
1058 msgstr "les espaces sont ignorés et peuvent être utlisés n'importe où dans l'expression."
1059
1060 #: ../../../__w/calibre/calibre/manual/template_lang.rst:498
1061 msgid ""
1062 "constant strings are enclosed in matching quotes, either ``'`` or ``\"``."
1063 msgstr "les chaînes constantes sont entre guillemets, soit ``'`` ou ``\"``."
1064
1065 #: ../../../__w/calibre/calibre/manual/template_lang.rst:500
1066 msgid ""
1067 "In `TPM`, using ``{`` and ``}`` characters in string literals can lead to "
1068 "errors or unexpected results because they confuse the template processor. It"
1069 " tries to treat them as template expression boundaries, not characters. In "
1070 "some but not all cases you can replace a ``{`` with ``[[`` and a ``}`` with "
1071 "`]]`. Advice: if your program contains ``{`` and ``}`` characters then you "
1072 "should use `General Program Mode`."
1073 msgstr ""
1074
1075 #: ../../../__w/calibre/calibre/manual/template_lang.rst:505
1076 msgid "Python Template Mode"
1077 msgstr ""
1078
1079 #: ../../../__w/calibre/calibre/manual/template_lang.rst:507
1080 msgid ""
1081 "Python Template Mode (PTM) lets you write templates using native Python and "
1082 "the `calibre API <https://manual.calibre-ebook.com/develop.html#api-"
1083 "documentation-for-various-parts-of-calibre>`_. The database API will be of "
1084 "most use; further discussion is beyond the scope of this manual. PTM "
1085 "templates are faster and can do more complicated operations but you must "
1086 "know how to write code in Python using the calibre API."
1087 msgstr ""
1088
1089 #: ../../../__w/calibre/calibre/manual/template_lang.rst:509
1090 msgid "A PTM template begins with:"
1091 msgstr ""
1092
1093 #: ../../../__w/calibre/calibre/manual/template_lang.rst:527
1094 msgid ""
1095 "You can add the above text to your template using the context menu, usually "
1096 "accessed with a right click. The comments are not significant and can be "
1097 "removed. You must use python indenting."
1098 msgstr ""
1099
1100 #: ../../../__w/calibre/calibre/manual/template_lang.rst:529
1101 msgid ""
1102 "The context object supports ``str(context)`` that returns a string of the "
1103 "context's contents, and ``context.attributes`` that returns a list of the "
1104 "attribute names in the context."
1105 msgstr ""
1106
1107 #: ../../../__w/calibre/calibre/manual/template_lang.rst:531
1108 msgid ""
1109 "The ``context.funcs`` attribute allows calling Built-in and User template "
1110 "functions, and Stored GPM/Python templates, so that you can execute them "
1111 "directly in your code. The functions are retrieved using their names. If the"
1112 " name conflicts with a Python keyword, add an underscore to the end of the "
1113 "name. Examples:"
1114 msgstr ""
1115
1116 #: ../../../__w/calibre/calibre/manual/template_lang.rst:538
1117 msgid ""
1118 "Here is an example of a PTM template that produces a list of all the authors"
1119 " for a series. The list is stored in a `Column built from other columns, "
1120 "behaves like tags`. It shows in :guilabel:`Book details` and has the "
1121 ":guilabel:`on separate lines` checked (in :guilabel:`Preferences->Look & "
1122 "feel->Book details`). That option requires the list to be comma-separated. "
1123 "To satisfy that requirement the template converts commas in author names to "
1124 "semicolons then builds a comma-separated list of authors. The authors are "
1125 "then sorted, which is why the template uses author_sort."
1126 msgstr ""
1127
1128 #: ../../../__w/calibre/calibre/manual/template_lang.rst:559
1129 msgid "The output in :guilabel:`Book details` looks like this:"
1130 msgstr ""
1131
1132 #: ../../../__w/calibre/calibre/manual/template_lang.rst:561
1133 msgid "E-book conversion dialog"
1134 msgstr "Dialogue de conversion des livres numériques"
1135
1136 #: ../../../__w/calibre/calibre/manual/template_lang.rst:569
1137 msgid "Templates and URLs"
1138 msgstr ""
1139
1140 #: ../../../__w/calibre/calibre/manual/template_lang.rst:571
1141 msgid "You can use templates to construct URLs. Two cases are described here:"
1142 msgstr ""
1143
1144 #: ../../../__w/calibre/calibre/manual/template_lang.rst:573
1145 msgid "Custom column :guilabel:`Book details` search URLs"
1146 msgstr ""
1147
1148 #: ../../../__w/calibre/calibre/manual/template_lang.rst:574
1149 msgid "The calibre URL scheme"
1150 msgstr ""
1151
1152 #: ../../../__w/calibre/calibre/manual/template_lang.rst:576
1153 msgid "**Custom column book details search URLs**"
1154 msgstr ""
1155
1156 #: ../../../__w/calibre/calibre/manual/template_lang.rst:578
1157 msgid ""
1158 "When you create a custom column you can provide a URL to be used in "
1159 ":guilabel:`Book details` using a template. For example, if you have a custom"
1160 " column for `Translators` you can define a URL to take you to a site for "
1161 "translators. Book details search URLs can be provided for `Text`, "
1162 "`Enumerated`, `Series`, and `Column built from other column` column types."
1163 msgstr ""
1164
1165 #: ../../../__w/calibre/calibre/manual/template_lang.rst:580
1166 msgid ""
1167 "When an item with a `search template` is clicked in :guilabel:`Book details`"
1168 " the template is evaluated. It is provided the normal book metadata. It is "
1169 "also provided three additional fields:"
1170 msgstr ""
1171
1172 #: ../../../__w/calibre/calibre/manual/template_lang.rst:582
1173 msgid "``item_value``: the value of the clicked item."
1174 msgstr ""
1175
1176 #: ../../../__w/calibre/calibre/manual/template_lang.rst:583
1177 msgid ""
1178 "``item_value_quoted``: the value of clicked item, URL-encoded. Special "
1179 "characters are escaped to make them valid in URLs and spaces are replaced by"
1180 " ``'+'`` (plus) signs."
1181 msgstr ""
1182
1183 #: ../../../__w/calibre/calibre/manual/template_lang.rst:584
1184 msgid ""
1185 "``item_value_no_plus``: the value of clicked item, URL-encoded. Special "
1186 "characters are escaped to make them valid in URLs and spaces are replaced by"
1187 " the ``%20``, not plus."
1188 msgstr ""
1189
1190 #: ../../../__w/calibre/calibre/manual/template_lang.rst:586
1191 msgid ""
1192 "There are several ways to construct the URL. The following use Wikipedia as "
1193 "an example."
1194 msgstr ""
1195
1196 #: ../../../__w/calibre/calibre/manual/template_lang.rst:588
1197 msgid "The simplest is a basic template::"
1198 msgstr ""
1199
1200 #: ../../../__w/calibre/calibre/manual/template_lang.rst:592
1201 msgid ""
1202 "In some cases you might want to do more processing. There are four template "
1203 "functions you can use, depending on the complexity of the processing."
1204 msgstr ""
1205
1206 #: ../../../__w/calibre/calibre/manual/template_lang.rst:599
1207 msgid ""
1208 "For example, assume you have a custom column `Translators` "
1209 "(``#translators``) where the names are `Last name, First name`. You might "
1210 "need to convert the name to `First name Last name` when creating the URL. "
1211 "You can use the :ref:`ff_make_url` function to do this::"
1212 msgstr ""
1213
1214 #: ../../../__w/calibre/calibre/manual/template_lang.rst:603
1215 msgid ""
1216 "If we assume that the translator's name is `Boy-Żeleński, Tadeusz` then the "
1217 "above template produces the link::"
1218 msgstr ""
1219
1220 #: ../../../__w/calibre/calibre/manual/template_lang.rst:607
1221 msgid ""
1222 "Note that the person's first name is now first, the space is now a plus, and"
1223 " that the non-English characters in the last name are URL-encoded."
1224 msgstr ""
1225
1226 #: ../../../__w/calibre/calibre/manual/template_lang.rst:609
1227 msgid ""
1228 "The functions :ref:`ff_make_url_extended`, :ref:`ff_query_string`, and "
1229 ":ref:`ff_encode_for_url` might be useful depending upon any additional "
1230 "processing complexity."
1231 msgstr ""
1232
1233 #: ../../../__w/calibre/calibre/manual/template_lang.rst:611
1234 msgid "**The calibre URL scheme**"
1235 msgstr ""
1236
1237 #: ../../../__w/calibre/calibre/manual/template_lang.rst:613
1238 msgid ""
1239 "Calibre supports several different URLs to navigate your calibre libraries. "
1240 "This section shows how to use templates to construct some of the URLs. See "
1241 ":doc:`url_scheme` for details on the URLs available."
1242 msgstr ""
1243
1244 #: ../../../__w/calibre/calibre/manual/template_lang.rst:616
1245 msgid "Switch to a specific library. The syntax of this URL is::"
1246 msgstr ""
1247
1248 #: ../../../__w/calibre/calibre/manual/template_lang.rst:620
1249 msgid ""
1250 "``Library_Name`` must be replaced with the name of the calibre library you "
1251 "wish to open. The library name is shown in the title bar of the window. It "
1252 "is a simple name, not the file path to the library. You must spell it as "
1253 "shown in the title bar, including letter case. The character ``_`` "
1254 "(underscore) stands for the current library. If the name contains any spaces"
1255 " or special characters then it must be hex encoded using the "
1256 ":ref:`ff_to_hex` function, as in the following example::"
1257 msgstr ""
1258
1259 #: ../../../__w/calibre/calibre/manual/template_lang.rst:628
1260 msgid "The template generates the URL::"
1261 msgstr ""
1262
1263 #: ../../../__w/calibre/calibre/manual/template_lang.rst:632
1264 msgid ""
1265 "You can replace the ``current_library_name()`` function with the actual name"
1266 " of the library, as in::"
1267 msgstr ""
1268
1269 #: ../../../__w/calibre/calibre/manual/template_lang.rst:636
1270 msgid ""
1271 "Links to show books. These links select a book in the calibre library. The "
1272 "syntax for this URL is::"
1273 msgstr ""
1274
1275 #: ../../../__w/calibre/calibre/manual/template_lang.rst:640
1276 msgid ""
1277 "The ``book id`` is the numeric calibre id for the book, available to "
1278 "templates as ``$id``. As above, the library name might need to be hex "
1279 "encoded. Here is an example::"
1280 msgstr ""
1281
1282 #: ../../../__w/calibre/calibre/manual/template_lang.rst:645
1283 msgid "It produces the URL::"
1284 msgstr ""
1285
1286 #: ../../../__w/calibre/calibre/manual/template_lang.rst:649
1287 msgid ""
1288 "Searching for books. These links search for books in the specified calibre "
1289 "library. The syntax for this URL is::"
1290 msgstr ""
1291
1292 #: ../../../__w/calibre/calibre/manual/template_lang.rst:654
1293 msgid ""
1294 "where `query` is any valid calibre search expression. You must hex encode "
1295 "any query containing spaces or special characters, which generally means all"
1296 " of them. For example, the calibre search expression for searching for a "
1297 "hierarchical tag beginning with 'AA' is ``tags:\"=.AA\"``. This template "
1298 "constructs a search URL for that expression::"
1299 msgstr ""
1300
1301 #: ../../../__w/calibre/calibre/manual/template_lang.rst:660
1302 msgid "The resulting URL is::"
1303 msgstr ""
1304
1305 #: ../../../__w/calibre/calibre/manual/template_lang.rst:664
1306 msgid ""
1307 "Here is an example of the same URL built using the "
1308 ":ref:``ff_make_url_extended`` function instead of :ref:`ff_strcat`::"
1309 msgstr ""
1310
1311 #: ../../../__w/calibre/calibre/manual/template_lang.rst:669
1312 msgid ""
1313 "Open a book details window on a book in some library. The syntax for this "
1314 "URL is::"
1315 msgstr ""
1316
1317 #: ../../../__w/calibre/calibre/manual/template_lang.rst:673
1318 msgid "An example template is::"
1319 msgstr ""
1320
1321 #: ../../../__w/calibre/calibre/manual/template_lang.rst:677
1322 #: ../../../__w/calibre/calibre/manual/template_lang.rst:694
1323 msgid "which produces the URL::"
1324 msgstr ""
1325
1326 #: ../../../__w/calibre/calibre/manual/template_lang.rst:681
1327 msgid ""
1328 "Open the notes associated with an author/series/etc. The syntax of the URL "
1329 "is::"
1330 msgstr ""
1331
1332 #: ../../../__w/calibre/calibre/manual/template_lang.rst:686
1333 msgid ""
1334 "``Field_Name`` is the lookup name of the field. If the field is a custom "
1335 "column then replace the ``#`` character with an underscore (``_``). "
1336 "``Item_Id`` is the internal numeric ID of the value in the field. There "
1337 "isn't a template function that returns the ``Item_Id``, so templates will "
1338 "normally use the second form, ``Hex_Encoded_Item_Name``. Here is a sample "
1339 "template that opens the note for the person ``Boy-Żeleński, Tadeusz`` in the"
1340 " field ``#authtest``::"
1341 msgstr ""
1342
1343 #: ../../../__w/calibre/calibre/manual/template_lang.rst:700
1344 msgid "Stored templates"
1345 msgstr "Modèles stockés"
1346
1347 #: ../../../__w/calibre/calibre/manual/template_lang.rst:702
1348 msgid ""
1349 "Both :ref:`General Program Mode <general_mode>` and :ref:`Python Template "
1350 "Mode <python_mode>` support saving templates and calling those templates "
1351 "from another template, much like calling stored functions. You save "
1352 "templates using :guilabel:`Preferences->Advanced->Template functions`. More "
1353 "information is provided in that dialog. You call a template the same way you"
1354 " call a function, passing positional arguments if desired. An argument can "
1355 "be any expression. Examples of calling a template, assuming the stored "
1356 "template is named ``foo``:"
1357 msgstr ""
1358
1359 #: ../../../__w/calibre/calibre/manual/template_lang.rst:704
1360 msgid "``foo()`` -- call the template passing no arguments."
1361 msgstr "``foo()`` -- appelle le modèle en ne passant aucun argument."
1362
1363 #: ../../../__w/calibre/calibre/manual/template_lang.rst:705
1364 msgid ""
1365 "``foo(a, b)`` call the template passing the values of the two variables "
1366 "``a`` and ``b``."
1367 msgstr "``foo(a, b)`` appelle le modèle en passant les valeurs des deux variables ``a`` et ``b``."
1368
1369 #: ../../../__w/calibre/calibre/manual/template_lang.rst:706
1370 msgid ""
1371 "``foo(if field('series') then field('series_index') else 0 fi)`` -- if the "
1372 "book has a ``series`` then pass the ``series_index``, otherwise pass the "
1373 "value ``0``."
1374 msgstr "``foo(if field('series') then field('series_index') else 0 fi)`` -- si le livre a ``series`` alors passez le ``series_index``, sinon passez la valeur ``0``."
1375
1376 #: ../../../__w/calibre/calibre/manual/template_lang.rst:708
1377 msgid ""
1378 "In GPM you retrieve the arguments passed in the call to the stored template "
1379 "using the ``arguments`` function. It both declares and initializes local "
1380 "variables, effectively parameters. The variables are positional; they get "
1381 "the value of the parameter given in the call in the same position. If the "
1382 "corresponding parameter is not provided in the call then ``arguments`` "
1383 "assigns that variable the provided default value. If there is no default "
1384 "value then the variable is set to the empty string. For example, the "
1385 "following ``arguments`` function declares 2 variables, ``key``, "
1386 "``alternate``::"
1387 msgstr ""
1388
1389 #: ../../../__w/calibre/calibre/manual/template_lang.rst:712
1390 msgid "Examples, again assuming the stored template is named ``foo``:"
1391 msgstr "Par exemple, en supposant encore une fois que le modèle stocké est nommé ``foo`` :"
1392
1393 #: ../../../__w/calibre/calibre/manual/template_lang.rst:714
1394 msgid ""
1395 "``foo('#myseries')`` -- argument ``key`` is assigned the value "
1396 "``'myseries'`` and the argument ``alternate`` is assigned the default value "
1397 "``'series'``."
1398 msgstr "``foo('#myseries')`` -- l'argument ``key`` se voit attribuer la valeur ``myseries'`` et l'argument ``alternate`` se voit attribuer la valeur par défaut ``'series'``."
1399
1400 #: ../../../__w/calibre/calibre/manual/template_lang.rst:715
1401 msgid ""
1402 "``foo('series', '#genre')`` the variable ``key`` is assigned the value "
1403 "``'series'`` and the variable ``alternate`` is assigned the value "
1404 "``'#genre'``."
1405 msgstr "``foo('series', '#genre')`` la variable ``key`` prend la valeur ``'series'`` et la variable ``alternate`` prend la valeur ``'#genre'``."
1406
1407 #: ../../../__w/calibre/calibre/manual/template_lang.rst:716
1408 msgid ""
1409 "``foo()`` -- the variable ``key`` is assigned the empty string and the "
1410 "variable ``alternate`` is assigned the value ``'series'``."
1411 msgstr "``foo()`` -- la variable ``key`` se voit attribuer la chaîne vide et la variable ``alternate`` se voit attribuer la valeur ``'series'``."
1412
1413 #: ../../../__w/calibre/calibre/manual/template_lang.rst:718
1414 msgid ""
1415 "In PTM the arguments are passed in the ``arguments`` parameter, which is a "
1416 "list of strings. There isn't any way to specify default values. You must "
1417 "check the length of the ``arguments`` list to be sure that the number of "
1418 "arguments is what you expect."
1419 msgstr ""
1420
1421 #: ../../../__w/calibre/calibre/manual/template_lang.rst:720
1422 msgid ""
1423 "An easy way to test stored templates is using the ``Template tester`` "
1424 "dialog. For ease of access give it a keyboard shortcut in "
1425 ":guilabel:`Preferences->Advanced->Keyboard shortcuts->Template tester`. "
1426 "Giving the ``Stored templates`` dialog a shortcut will help switching more "
1427 "rapidly between the tester and editing the stored template's source code."
1428 msgstr "Une façon simple de tester les modèles stockés est d'utiliser le dialogue \"Testeur de modèle\". Pour faciliter l'accès, donnez-lui un raccourci clavier dans :guilabel:`Préférences->Avancé->Raccourcis clavier->Tester le modèle``. Donner un raccourci au dialogue ``Modèles stockés`` aidera à passer plus rapidement du testeur à l'édition du code source du modèle stocké."
1429
1430 #: ../../../__w/calibre/calibre/manual/template_lang.rst:723
1431 msgid "Providing additional information to templates"
1432 msgstr "Fournir des informations supplémentaires aux modèles"
1433
1434 #: ../../../__w/calibre/calibre/manual/template_lang.rst:725
1435 msgid ""
1436 "A developer can choose to pass additional information to the template "
1437 "processor, such as application-specific book metadata or information about "
1438 "what the processor is being asked to do. A template can access this "
1439 "information and use it during the evaluation."
1440 msgstr "Un développeur peut choisir de transmettre des informations supplémentaires au processeur du modèle, telles que des métadonnées de livre spécifiques à l'application ou des informations sur ce qui est demandé au processeur. Un modèle peut accéder à ces informations et les utiliser pendant l'évaluation."
1441
1442 #: ../../../__w/calibre/calibre/manual/template_lang.rst:727
1443 msgid "**Developer: how to pass additional information**"
1444 msgstr "**Développeur : comment transmettre des informations supplémentaires**"
1445
1446 #: ../../../__w/calibre/calibre/manual/template_lang.rst:729
1447 msgid ""
1448 "The additional information is a Python dictionary containing pairs "
1449 "``variable_name: variable_value`` where the values must be strings. The "
1450 "template can access the dictionary, creating template local variables named "
1451 "``variable_name`` containing the value ``variable_value``. The user cannot "
1452 "change the name so it is best to use names that won't collide with other "
1453 "template local variables, for example by prefixing the name with an "
1454 "underscore."
1455 msgstr ""
1456
1457 #: ../../../__w/calibre/calibre/manual/template_lang.rst:731
1458 msgid ""
1459 "This dictionary is passed to the template processor (the ``formatter``) "
1460 "using the named parameter ``global_vars=your_dict``. The full method "
1461 "signature is::"
1462 msgstr ""
1463
1464 #: ../../../__w/calibre/calibre/manual/template_lang.rst:739
1465 msgid "**Template writer: how to access the additional information**"
1466 msgstr "**Rédacteur de modèles : comment accéder aux informations complémentaires**"
1467
1468 #: ../../../__w/calibre/calibre/manual/template_lang.rst:741
1469 msgid ""
1470 "You access the additional information (the ``globals`` dictionary) in a "
1471 "template using the template function::"
1472 msgstr ""
1473
1474 #: ../../../__w/calibre/calibre/manual/template_lang.rst:745
1475 msgid ""
1476 "where ``id`` is any legal variable name. This function checks whether the "
1477 "additional information provided by the developer contains the name. If it "
1478 "does then the function assigns the provided value to a template local "
1479 "variable with that name. If the name is not in the additional information "
1480 "and if an ``expression`` is provided, the ``expression`` is evaluated and "
1481 "the result is assigned to the local variable. If neither a value nor an "
1482 "expression is provided, the function assigns the empty string (``''``) to "
1483 "the local variable."
1484 msgstr "où ``id`` est un nom de variable légale quelconque. Cette fonction vérifie si les informations supplémentaires fournies par le développeur contiennent le nom. Si c'est le cas, la fonction attribue la valeur fournie à une variable locale modèle avec ce nom. Si le nom ne figure pas dans les informations supplémentaires et si une \"expression\" est fournie, cette \"expression\" est évaluée et le résultat est attribué à la variable locale. Si ni une valeur ni une expression n'est fournie, la fonction attribue la chaîne vide (``''``) à la variable locale."
1485
1486 #: ../../../__w/calibre/calibre/manual/template_lang.rst:747
1487 msgid ""
1488 "A template can set a value in the ``globals`` dictionary using the template "
1489 "function::"
1490 msgstr ""
1491
1492 #: ../../../__w/calibre/calibre/manual/template_lang.rst:751
1493 msgid ""
1494 "This function sets the ``globals`` dictionary key:value pair ``id:value`` "
1495 "where ``value`` is the value of the template local variable ``id``. If that "
1496 "local variable doesn't exist then ``value`` is set to the result of "
1497 "evaluating ``expression``."
1498 msgstr ""
1499
1500 #: ../../../__w/calibre/calibre/manual/template_lang.rst:754
1501 msgid "Notes on the difference between modes"
1502 msgstr "Notes sur la différence entre les modes"
1503
1504 #: ../../../__w/calibre/calibre/manual/template_lang.rst:756
1505 msgid ""
1506 "The three program modes, :ref:`Single Function Mode <single_mode>` (SFM), "
1507 ":ref:`Template Program Mode <template_mode>` (`TPM`), and :ref:`General "
1508 "Program Mode <general_mode>` (`GPM`), work differently. SFM is intended to "
1509 "be 'simple' so it hides a lot of programming language bits."
1510 msgstr "Les trois modes de programmation, :ref:`Mode Fonction Simple` (MFS), :ref:`Mode Modèle de Programmation` (`MMP`), et :ref:`Mode Général de Programmation` (`MGP`), fonctionnent différemment. Le MFS est destiné à être 'simple' et cache donc beaucoup de bits de langage de programmation."
1511
1512 #: ../../../__w/calibre/calibre/manual/template_lang.rst:758
1513 msgid "Differences:"
1514 msgstr "Différences :"
1515
1516 #: ../../../__w/calibre/calibre/manual/template_lang.rst:760
1517 msgid ""
1518 "In SFM the value of the column is always passed as an 'invisible' first "
1519 "argument to a function included in the template."
1520 msgstr "Dans MFS, la valeur de la colonne est toujours passée comme premier argument 'invisible' à une fonction incluse dans le modèle."
1521
1522 #: ../../../__w/calibre/calibre/manual/template_lang.rst:761
1523 msgid ""
1524 "SFM doesn't support the difference between variables and strings; all values"
1525 " are strings."
1526 msgstr "Le MFS ne supporte pas la différence entre les variables et les chaînes de caractères ; toutes les valeurs sont des chaînes de caractères."
1527
1528 #: ../../../__w/calibre/calibre/manual/template_lang.rst:762
1529 msgid ""
1530 "The following SFM template returns either the series name or the string \"no"
1531 " series\"::"
1532 msgstr "Le modèle SFM suivant renvoie soit le nom de la série, soit la chaîne \"pas de série\" ::"
1533
1534 #: ../../../__w/calibre/calibre/manual/template_lang.rst:766
1535 msgid "The equivalent template in `TPM` is ::"
1536 msgstr "Le modèle équivalent dans `MPM` est ::"
1537
1538 #: ../../../__w/calibre/calibre/manual/template_lang.rst:770
1539 msgid "The equivalent template in `GPM` is::"
1540 msgstr "Le modèle équivalent dans `MGP` est ::"
1541
1542 #: ../../../__w/calibre/calibre/manual/template_lang.rst:774
1543 msgid ""
1544 "The first argument to ``ifempty`` is the value of the field ``series``. The "
1545 "second argument is the string ``no series``. In SFM the first argument, the "
1546 "value of the field, is automatically passed (the invisible argument)."
1547 msgstr "Le premier argument de ``ifempty`` est la valeur du champ ``série``. Le second argument est la chaîne ``no series``. Dans SFM, le premier argument, la valeur du champ, est automatiquement passé (l'argument invisible)."
1548
1549 #: ../../../__w/calibre/calibre/manual/template_lang.rst:775
1550 msgid ""
1551 "Several template functions, for example ``booksize()`` and "
1552 "``current_library_name()``, take no arguments. Because of the 'invisible "
1553 "argument' you cannot use these functions in SFM."
1554 msgstr "Plusieurs fonctions du modèle, par exemple ``booksize()`` et ``current_library_name()``, ne prennent aucun argument. En raison de l'\"argument invisible\", vous ne pouvez pas utiliser ces fonctions dans SFM."
1555
1556 #: ../../../__w/calibre/calibre/manual/template_lang.rst:776
1557 msgid ""
1558 "Nested functions, where a function calls another function to compute an "
1559 "argument, cannot be used in SFM. For example this template, intended to "
1560 "return the first 5 characters of the series value uppercased, won't work in "
1561 "SFM::"
1562 msgstr "Les fonctions imbriquées, où une fonction appelle une autre fonction pour calculer un argument, ne peuvent pas être utilisées dans SFM. Par exemple, ce modèle, destiné à renvoyer les 5 premiers caractères de la valeur de la série en majuscules, ne fonctionnera pas dans SFM ::"
1563
1564 #: ../../../__w/calibre/calibre/manual/template_lang.rst:780
1565 msgid ""
1566 "`TPM` and `GPM` support nested functions. The above template in `TPM` would "
1567 "be::"
1568 msgstr "`MPM` et `MPG` soutiennent des fonctions imbriquées. Le modèle ci-dessus dans `MPM` serait ::"
1569
1570 #: ../../../__w/calibre/calibre/manual/template_lang.rst:784
1571 msgid "In `GPM` it would be::"
1572 msgstr "Dans `MPG`, ce serait ::"
1573
1574 #: ../../../__w/calibre/calibre/manual/template_lang.rst:788
1575 msgid ""
1576 "As noted in the above :ref:`Template Program Mode <template_mode>` section, "
1577 "using ``{`` and ``}`` characters in `TPM` string literals can lead to errors"
1578 " or unexpected results because they confuse the template processor. It tries"
1579 " to treat them as template boundaries, not characters. In some but not all "
1580 "cases you can replace a ``{`` with ``[[`` and a ``}`` with `]]`. Generally, "
1581 "if your program contains ``{`` and ``}`` characters then you should use "
1582 "`General Program Mode`."
1583 msgstr "Comme indiqué dans la section :ref:`Mode de Programmation des Modèles` ci-dessus, l'utilisation des caractères ``{`` et ``}`` dans les chaînes de caractères `MPM` peut conduire à des erreurs ou à des résultats inattendus car ils perturbent le processeur de modèles. Il essaie de les traiter comme des limites de modèles et non comme des caractères. Dans certains cas, mais pas dans tous, vous pouvez remplacer un ``{`` par ``[[`` et un ``}`` par ``]]`. En général, si votre programme contient des caractères ``{`` et ``}``, vous devriez utiliser le `Mode Général de Programmation`."
1584
1585 #: ../../../__w/calibre/calibre/manual/template_lang.rst:792
1586 msgid "User-defined Python template functions"
1587 msgstr "Fonctions des modèles Python définis par l'utilisateur"
1588
1589 #: ../../../__w/calibre/calibre/manual/template_lang.rst:794
1590 msgid ""
1591 "You can add your own Python functions to the template processor. Such "
1592 "functions can be used in any of the three template programming modes. The "
1593 "functions are added by going to :guilabel:`Preferences -> Advanced -> "
1594 "Template functions`. Instructions are shown in that dialog. Note that you "
1595 "can use `Python Templates` for a similar purpose. As calling user-defined "
1596 "functions is faster than calling a Python template, user-defined functions "
1597 "might be more efficient depending on the complexity of what the function or "
1598 "template does."
1599 msgstr ""
1600
1601 #: ../../../__w/calibre/calibre/manual/template_lang.rst:797
1602 msgid "Special notes for using templates in different contexts"
1603 msgstr ""
1604
1605 #: ../../../__w/calibre/calibre/manual/template_lang.rst:799
1606 msgid ""
1607 "In the GUI (:guilabel:`Columns made from other columns` and "
1608 ":guilabel:`Template searches`):"
1609 msgstr ""
1610
1611 #: ../../../__w/calibre/calibre/manual/template_lang.rst:801
1612 msgid "GPM templates work as before."
1613 msgstr ""
1614
1615 #: ../../../__w/calibre/calibre/manual/template_lang.rst:802
1616 msgid "Python templates have full access to the calibre database."
1617 msgstr ""
1618
1619 #: ../../../__w/calibre/calibre/manual/template_lang.rst:804
1620 msgid "In icon rules:"
1621 msgstr ""
1622
1623 #: ../../../__w/calibre/calibre/manual/template_lang.rst:806
1624 msgid ""
1625 "icon rule templates have no book data so field-based functions such as "
1626 ":ref:`ff_format_date_field`, :ref:`ff_list_count_field`, and "
1627 ":ref:`ff_check_yes_no` won't work."
1628 msgstr ""
1629
1630 #: ../../../__w/calibre/calibre/manual/template_lang.rst:808
1631 msgid "In the Content server:"
1632 msgstr ""
1633
1634 #: ../../../__w/calibre/calibre/manual/template_lang.rst:810
1635 msgid ""
1636 "Templates have access to the new API but not the old API (LibraryDatabase)."
1637 msgstr ""
1638
1639 #: ../../../__w/calibre/calibre/manual/template_lang.rst:811
1640 msgid ""
1641 "Because of the above, the following formatter functions are not guaranteed "
1642 "to work in GPM templates (composite columns, icon rules, etc) and should be "
1643 "avoided if you use the content server:"
1644 msgstr ""
1645
1646 #: ../../../__w/calibre/calibre/manual/template_lang.rst:813
1647 msgid ":ref:`ff_connected_device_name`"
1648 msgstr ""
1649
1650 #: ../../../__w/calibre/calibre/manual/template_lang.rst:814
1651 msgid ":ref:`ff_connected_device_uuid`"
1652 msgstr ""
1653
1654 #: ../../../__w/calibre/calibre/manual/template_lang.rst:815
1655 msgid ":ref:`ff_current_virtual_library_name`"
1656 msgstr ""
1657
1658 #: ../../../__w/calibre/calibre/manual/template_lang.rst:816
1659 msgid ":ref:`ff_is_marked`"
1660 msgstr ""
1661
1662 #: ../../../__w/calibre/calibre/manual/template_lang.rst:817
1663 msgid ":ref:`ff_virtual_libraries`"
1664 msgstr ""
1665
1666 #: ../../../__w/calibre/calibre/manual/template_lang.rst:820
1667 msgid "Special notes for save/send templates"
1668 msgstr "Notes spéciales pour la sauvergarde/l'envoi des modèles"
1669
1670 #: ../../../__w/calibre/calibre/manual/template_lang.rst:822
1671 msgid ""
1672 "Special processing is applied when a template is used in a :guilabel:`Save "
1673 "to disk` or :guilabel:`Send to device` template. The values of the fields "
1674 "are cleaned, replacing characters that are special to file systems with "
1675 "underscores, including slashes. This means that field text cannot be used to"
1676 " create folders. However, slashes are not changed in prefix or suffix "
1677 "strings, so slashes in these strings will cause folders to be created. "
1678 "Because of this, you can create variable-depth folder structure."
1679 msgstr ""
1680
1681 #: ../../../__w/calibre/calibre/manual/template_lang.rst:824
1682 msgid ""
1683 "For example, assume we want the folder structure `series/series_index - "
1684 "title`, with the caveat that if series does not exist, then the title should"
1685 " be in the top folder. The template to do this is::"
1686 msgstr "Par exemple, supposons que nous voulons que la structure des dossiers soit `series/series_index - titre`, en prévoyant que si la série n'existe pas, alors le titre devrait être dans le dossier racine (le premier dossier, pas le sous-dossier). Le modèle pour faire cela est :"
1687
1688 #: ../../../__w/calibre/calibre/manual/template_lang.rst:828
1689 msgid "The slash and the hyphen appear only if series is not empty."
1690 msgstr "La barre oblique et le trait d'union apparaissent uniquement si la série n'est pas vide."
1691
1692 #: ../../../__w/calibre/calibre/manual/template_lang.rst:830
1693 msgid ""
1694 "The lookup function lets us do even fancier processing. For example, assume "
1695 "that if a book has a series, then we want the folder structure "
1696 "`series/series index - title.fmt`. If the book does not have a series then "
1697 "we want the folder structure `genre/author_sort/title.fmt`. If the book has "
1698 "no genre then we want to use 'Unknown'. We want two completely different "
1699 "paths, depending on the value of series."
1700 msgstr "La fonction de recherche nous permet de faire le traitement encore plus poussé. Par exemple, supposons que si un livre est dans une série, alors nous voulons que la structure soit la suivante : `series/series index - title.fmt`.. Si le livre n'est pas dans une série, alors nous voulons que la structure des dossiers soit `genre/author_sort/title.fmt`. Si le livre n'a pas de genre, alors nous voulons utiliser 'Inconnu'. Nous voulons deux chemins de répertoire totalement différents en fonction de la valeur de la série."
1701
1702 #: ../../../__w/calibre/calibre/manual/template_lang.rst:832
1703 msgid "To accomplish this, we:"
1704 msgstr "Pour accomplir cela, nous :"
1705
1706 #: ../../../__w/calibre/calibre/manual/template_lang.rst:834
1707 msgid ""
1708 "Create a composite field (give it lookup name #aa) containing "
1709 "``{series}/{series_index} - {title}``. If the series is not empty, then this"
1710 " template will produce `series/series_index - title`."
1711 msgstr "Créer un champ composite (donner-lui le nom de recherche #aa) contenant ``{series}/{series_index} - {titre}``. Si la série n'est pas vide, alors ce modèle produira `series/series_index - titre`."
1712
1713 #: ../../../__w/calibre/calibre/manual/template_lang.rst:835
1714 msgid ""
1715 "Create a composite field (give it lookup name #bb) containing "
1716 "``{#genre:ifempty(Unknown)}/{author_sort}/{title}``. This template produces "
1717 "`genre/author_sort/title`, where an empty genre is replaced with `Unknown`."
1718 msgstr "Créons une champ composite (appelons-le #bb) contenant ``{#genre:ifempty(Unknown)}/{author_sort}/{title}``. Ce modèle produit `genre/author_sort/title`, où un genre vide est remplacé par `Inconnu`."
1719
1720 #: ../../../__w/calibre/calibre/manual/template_lang.rst:836
1721 msgid ""
1722 "Set the save template to ``{series:lookup(.,#aa,#bb)}``. This template "
1723 "chooses composite field ``#aa`` if series is not empty and composite field "
1724 "``#bb`` if series is empty. We therefore have two completely different save "
1725 "paths, depending on whether or not `series` is empty."
1726 msgstr ""
1727
1728 #: ../../../__w/calibre/calibre/manual/template_lang.rst:839
1729 msgid "Tips"
1730 msgstr "Astuces"
1731
1732 #: ../../../__w/calibre/calibre/manual/template_lang.rst:841
1733 msgid ""
1734 "Use the Template Tester to test templates. Add the tester to the context "
1735 "menu for books in the library and/or give it a keyboard shortcut."
1736 msgstr "Utilisez le Testeur de Modèles pour tester les modèles. Ajoutez le testeur au menu contextuel des livres de la bibliothèque et/ou donnez-lui un raccourci clavier."
1737
1738 #: ../../../__w/calibre/calibre/manual/template_lang.rst:842
1739 msgid ""
1740 "Templates can use other templates by referencing composite columns built "
1741 "with the desired template. Alternatively, you can use Stored Templates."
1742 msgstr "Les modèles peuvent utiliser d'autres modèles en faisant référence à des colonnes composites construites avec le modèle souhaité. Vous pouvez également utiliser des Modèles Stockés comme alternative."
1743
1744 #: ../../../__w/calibre/calibre/manual/template_lang.rst:843
1745 msgid ""
1746 "In a plugboard, you can set a field to empty (or whatever is equivalent to "
1747 "empty) by using the special template ``{}``. This template will always "
1748 "evaluate to an empty string."
1749 msgstr "Dans un tableau de connexions, vous pouvez paramétrer un champ à vide (ou quelque soit sont équivalent à vide) en utilisant le modèle spécial ``{}``. Ce modèle sera toujours évalué à une chaîne vide."
1750
1751 #: ../../../__w/calibre/calibre/manual/template_lang.rst:844
1752 msgid ""
1753 "The technique described above to show numbers even if they have a zero value"
1754 " works with the standard field series_index."
1755 msgstr "La technique indiquée ci-dessus pour montrer les nombre même s'ils ont une valeur zéro fonctionne avec le champ standard series_index."
1756
1757 #: ../../../__w/calibre/calibre/manual/template_lang.rst:849
1758 msgid "Template function reference"
1759 msgstr "Référence des modèles de fonctions"