Debian Codegraph @

translations/manual/cs/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 # iTentalce <[email protected]>, 2021
7 # J Nezbeda, 2026
8 # Michal Várady <[email protected]>, 2026
9 # Patrik Špaňo <[email protected]>, 2026
10 # Trottel <[email protected]>, 2020
11 msgid ""
12 msgstr ""
13 "Project-Id-Version: calibre\n"
14 "Report-Msgid-Bugs-To: \n"
15 "POT-Creation-Date: 2026-06-24 05:21+0000\n"
16 "PO-Revision-Date: 2014-06-17 08:34+0000\n"
17 "Last-Translator: Michal Várady <[email protected]>, 2026\n"
18 "Language-Team: Czech (http://app.transifex.com/calibre/calibre/language/cs/)\n"
19 "MIME-Version: 1.0\n"
20 "Content-Type: text/plain; charset=UTF-8\n"
21 "Content-Transfer-Encoding: 8bit\n"
22 "Language: cs\n"
23 "Plural-Forms: nplurals=4; plural=(n == 1 && n % 1 == 0) ? 0 : (n >= 2 && n <= 4 && n % 1 == 0) ? 1: (n % 1 != 0 ) ? 2 : 3;\n"
24
25 #: ../../../__w/calibre/calibre/manual/template_lang.rst:4
26 msgid "The calibre template language"
27 msgstr "Jazyk šablon v programu Calibre"
28
29 #: ../../../__w/calibre/calibre/manual/template_lang.rst:6
30 msgid ""
31 "The calibre template language is a calibre-specific language used throughout"
32 " calibre for tasks such as specifying file paths, formatting values, and "
33 "computing the value for user-specified columns. Examples:"
34 msgstr "Jazyk šablon calibre je jazyk specifický pro calibre, který se v calibre používá pro úlohy, jako je určování cest k souborům, formátování hodnot a výpočet hodnoty pro uživatelem určené sloupce. Příklady:"
35
36 #: ../../../__w/calibre/calibre/manual/template_lang.rst:8
37 msgid ""
38 "Specify the folder structure and file names when saving files from the "
39 "calibre library to the disk or e-book reader."
40 msgstr "Určení struktury složek a názvů souborů při ukládání souborů z knihovny calibre na disk nebo do čtečky e-knih."
41
42 #: ../../../__w/calibre/calibre/manual/template_lang.rst:9
43 msgid "Define rules for adding icons and colors to the calibre book list."
44 msgstr "Definování pravidel pro přidávání ikon a barev do seznamu knih calibre."
45
46 #: ../../../__w/calibre/calibre/manual/template_lang.rst:10
47 msgid "Define `virtual columns` that contain data from other columns."
48 msgstr "Definování `virtuálních sloupců`, které obsahují data z jiných sloupců."
49
50 #: ../../../__w/calibre/calibre/manual/template_lang.rst:11
51 msgid "Advanced library searching."
52 msgstr "Pokročilé hledání v knihovně."
53
54 #: ../../../__w/calibre/calibre/manual/template_lang.rst:12
55 msgid "Advanced metadata search and replace."
56 msgstr "Pokročilé hledání a nahrazování v metadatech."
57
58 #: ../../../__w/calibre/calibre/manual/template_lang.rst:14
59 msgid ""
60 "The language is built around the notion of a `template`, which specifies "
61 "which book metadata to use, computations on that metadata, and how it is to "
62 "be formatted."
63 msgstr "Jazyk je založen na pojmu `šablona`, která určuje, která metadata knihy se mají použít, jaké výpočty se s nimi mají provést a jak mají být formátována."
64
65 #: ../../../__w/calibre/calibre/manual/template_lang.rst:17
66 msgid "Basic templates"
67 msgstr "Základní šablony"
68
69 #: ../../../__w/calibre/calibre/manual/template_lang.rst:19
70 msgid ""
71 "A basic template consists of one or more ``template expressions``. A "
72 "``template expression`` consists of text and names in curly brackets "
73 "(``{}``) that is replaced by the corresponding metadata from the book being "
74 "processed. For example, the default template in calibre used for saving "
75 "books to device has 4 ``template expressions``::"
76 msgstr "Základní šablona se skládá z jednoho nebo více ``výrazů šablony``. ``Výraz šablony`` se skládá z textu a názvů ve složených závorkách (``{}``), které jsou nahrazeny odpovídajícími metadaty ze zpracovávané knihy. Například výchozí šablona, kterou calibre používá při ukládání knih do zařízení, má čtyři ``výrazy šablony``::"
77
78 #: ../../../__w/calibre/calibre/manual/template_lang.rst:23
79 msgid "For the book \"The Foundation\" by \"Isaac Asimov\" the template will become::"
80 msgstr "Pro knihu \"The Foundation\" od autora \"Isaac Asimov\" se šablona změní na::"
81
82 #: ../../../__w/calibre/calibre/manual/template_lang.rst:27
83 msgid ""
84 "The slashes are not ``template expressions`` because they are not in between"
85 " ``{}``. Such text is left where it appears. For example, if the template "
86 "is::"
87 msgstr "Lomítka nejsou ``výrazy šablony``, protože nejsou mezi ``{}``. Takový text zůstane tam, kde se vyskytuje. Například pokud je šablona::"
88
89 #: ../../../__w/calibre/calibre/manual/template_lang.rst:31
90 msgid "then for \"The Foundation\" the template produces::"
91 msgstr "pak pro \"The Foundation\" šablona vytvoří::"
92
93 #: ../../../__w/calibre/calibre/manual/template_lang.rst:35
94 msgid ""
95 "A ``template expression`` can access all the metadata available in calibre, "
96 "including custom columns (columns you create yourself), by using a column's "
97 "``lookup name``. To find the lookup name for a `column` (sometimes called "
98 "`fields`), hover your mouse over the column header in calibre's book list. "
99 "Lookup names for custom columns always begin with ``#``. For series type "
100 "columns there is an additional field named ``#lookup name_index`` that is "
101 "the series index for that book in the series. For example, if you have a "
102 "custom series column named ``#myseries``, there will also be a column named "
103 "``#myseries_index``. The standard series column's index is named "
104 "``series_index``."
105 msgstr "``Výraz šablony`` může pomocí ``názvu vyhledávání`` sloupce přistupovat ke všem metadatům dostupným v calibre, včetně vlastních sloupců (sloupců, které si vytvoříte sami). Název vyhledávání pro `sloupec` (někdy označovaný jako `pole`) zjistíte tak, že najedete myší na záhlaví sloupce v seznamu knih calibre. Názvy vyhledávání pro vlastní sloupce vždy začínají znakem ``#``. U sloupců typu série existuje dodatečné pole s názvem ``#lookup name_index``, které představuje pořadí dané knihy v sérii. Pokud máte například vlastní sloupec série s názvem ``#myseries``, bude existovat také sloupec s názvem ``#myseries_index``. Pořadí ve standardním sloupci série se jmenuje ``series_index``."
106
107 #: ../../../__w/calibre/calibre/manual/template_lang.rst:37
108 msgid "In addition to the standard column based fields, you also can use:"
109 msgstr "Kromě standardních polí založených na sloupcích můžete použít také:"
110
111 #: ../../../__w/calibre/calibre/manual/template_lang.rst:39
112 msgid ""
113 "``{formats}`` - A list of formats available in the calibre library for a "
114 "book"
115 msgstr "``{formats}`` - seznam formátů dostupných pro knihu v knihovně calibre"
116
117 #: ../../../__w/calibre/calibre/manual/template_lang.rst:40
118 msgid "``{identifiers:select(isbn)}`` - The ISBN of the book"
119 msgstr "``{identifiers:select(isbn)}`` - ISBN knihy"
120
121 #: ../../../__w/calibre/calibre/manual/template_lang.rst:42
122 msgid ""
123 "If the metadata for the field for a given book is not defined then the field"
124 " in the template is replaced by the empty string (``''``). For example, "
125 "consider the following template::"
126 msgstr "Pokud nejsou metadata pole pro danou knihu definována, pole v šabloně se nahradí prázdným řetězcem (``''``). Zvažte například následující šablonu::"
127
128 #: ../../../__w/calibre/calibre/manual/template_lang.rst:46
129 msgid ""
130 "If Asimov's book \"Second Foundation\" is in the series \"Foundation\" then "
131 "the template produces::"
132 msgstr "Pokud je Asimovova kniha \"Second Foundation\" v sérii \"Foundation\", šablona vytvoří::"
133
134 #: ../../../__w/calibre/calibre/manual/template_lang.rst:50
135 msgid ""
136 "If a series has not been entered for the book then the template produces::"
137 msgstr "Pokud pro knihu nebyla zadána série, šablona vytvoří::"
138
139 #: ../../../__w/calibre/calibre/manual/template_lang.rst:54
140 msgid ""
141 "The template processor automatically removes multiple slashes and leading or"
142 " trailing spaces."
143 msgstr "Zpracovatel šablon automaticky odstraní vícenásobná lomítka a počáteční nebo koncové mezery."
144
145 #: ../../../__w/calibre/calibre/manual/template_lang.rst:57
146 msgid "Advanced formatting"
147 msgstr "Pokročilé formátování"
148
149 #: ../../../__w/calibre/calibre/manual/template_lang.rst:59
150 msgid ""
151 "In addition to metadata substitution, templates can conditionally include "
152 "additional text and control how substituted data is formatted."
153 msgstr "Kromě dosazování metadat mohou šablony podmíněně zahrnovat další text a určovat, jak se mají dosazená data formátovat."
154
155 #: ../../../__w/calibre/calibre/manual/template_lang.rst:61
156 msgid "**Conditionally including text**"
157 msgstr "**Podmíněné zahrnutí textu**"
158
159 #: ../../../__w/calibre/calibre/manual/template_lang.rst:63
160 msgid ""
161 "Sometimes you want text to appear in the output only if a field is not "
162 "empty. A common case is ``series`` and ``series_index`` where you want "
163 "either nothing or the two values separated by a hyphen. calibre handles this"
164 " case using a special ``template expression`` syntax."
165 msgstr "Někdy chcete, aby se text ve výstupu objevil jen tehdy, když pole není prázdné. Běžným případem jsou pole ``series`` a ``series_index``, u kterých buď nechcete zobrazit nic, nebo chcete zobrazit obě hodnoty oddělené spojovníkem. calibre tento případ řeší pomocí speciální syntaxe ``výrazu šablony``."
166
167 #: ../../../__w/calibre/calibre/manual/template_lang.rst:65
168 msgid ""
169 "For example and using the above Foundation example, assume you want the "
170 "template to produce `Foundation - 3 - Second Foundation`. This template "
171 "produces that output:"
172 msgstr "Například při použití výše uvedeného příkladu Foundation předpokládejme, že chcete, aby šablona vytvořila `Foundation - 3 - Second Foundation`. Tento výstup vytvoří následující šablona:"
173
174 #: ../../../__w/calibre/calibre/manual/template_lang.rst:67
175 msgid "``{series} - {series_index} - {title}``"
176 msgstr "``{series} - {series_index} - {title}``"
177
178 #: ../../../__w/calibre/calibre/manual/template_lang.rst:69
179 msgid ""
180 "However, if a book has no series the template will produce `- - the title`, "
181 "which is probably not what you want. Generally, people want the result be "
182 "the title without the extraneous hyphens. You can accomplish this using the "
183 "following template syntax:"
184 msgstr "Pokud ale kniha nemá žádnou sérii, šablona vytvoří `- - název`, což pravděpodobně není to, co chcete. Obvykle má být výsledkem název bez nadbytečných spojovníků. Toho můžete dosáhnout pomocí následující syntaxe šablony:"
185
186 #: ../../../__w/calibre/calibre/manual/template_lang.rst:71
187 msgid "``{field:|prefix_text|suffix_text}``"
188 msgstr "``{field:|prefix_text|suffix_text}``"
189
190 #: ../../../__w/calibre/calibre/manual/template_lang.rst:73
191 msgid ""
192 "This ``template expression`` says that if ``field`` has the value `XXXX` "
193 "then the result will be `prefix_textXXXXXsuffix_text`. If ``field`` is empty"
194 " (has no value) then the result will be the empty string (nothing) because "
195 "the prefix and suffix are ignored. The prefix and suffix can contain blanks."
196 msgstr "Tento ``výraz šablony`` říká, že pokud má ``field`` hodnotu `XXXX`, výsledkem bude `prefix_textXXXXsuffix_text`. Pokud je ``field`` prázdné (nemá žádnou hodnotu), výsledkem bude prázdný řetězec (nic), protože předpona a přípona se ignorují. Předpona a přípona mohou obsahovat mezery."
197
198 #: ../../../__w/calibre/calibre/manual/template_lang.rst:75
199 msgid ""
200 "**Do not use subtemplates (`{ ... }`) or functions (see below) in the prefix"
201 " or the suffix.**"
202 msgstr "**V předponě ani příponě nepoužívejte podšablony (`{ ... }`) ani funkce (viz níže).**"
203
204 #: ../../../__w/calibre/calibre/manual/template_lang.rst:77
205 msgid ""
206 "Using this syntax, we can solve the above no-series problem with the "
207 "template::"
208 msgstr "Pomocí této syntaxe můžeme výše uvedený problém s chybějící sérií vyřešit šablonou::"
209
210 #: ../../../__w/calibre/calibre/manual/template_lang.rst:81
211 msgid ""
212 "The hyphens will be included only if the book has a series index, which it "
213 "has only if it has a series. Continuing the Foundation example again, the "
214 "template will produce `Foundation - 1 - Second Foundation`."
215 msgstr "Spojovníky budou zahrnuty jen tehdy, pokud má kniha pořadí v sérii, které má pouze v případě, že patří do série. Pokud budeme pokračovat v příkladu Foundation, šablona vytvoří `Foundation - 1 - Second Foundation`."
216
217 #: ../../../__w/calibre/calibre/manual/template_lang.rst:83
218 #: ../../../__w/calibre/calibre/manual/template_lang.rst:293
219 #: ../../../__w/calibre/calibre/manual/template_lang.rst:469
220 msgid "Notes:"
221 msgstr "Poznámky:"
222
223 #: ../../../__w/calibre/calibre/manual/template_lang.rst:85
224 msgid ""
225 "You must include the colon after the ``lookup name`` if you are using a "
226 "prefix or a suffix."
227 msgstr "Pokud používáte předponu nebo příponu, musíte za ``název vyhledávání`` vložit dvojtečku."
228
229 #: ../../../__w/calibre/calibre/manual/template_lang.rst:86
230 msgid ""
231 "You must use either no or both ``|`` characters. Using one, as in ``{field:|"
232 " - }``, is not allowed."
233 msgstr "Musíte použít buď žádný, nebo oba znaky ``|``. Použití jen jednoho, například v ``{field:| - }``, není povoleno."
234
235 #: ../../../__w/calibre/calibre/manual/template_lang.rst:87
236 msgid ""
237 "It is OK to provide no text for either the prefix or the suffix, such as in "
238 "``{series:|| - }``. The template ``{title:||}`` is the same as ``{title}``."
239 msgstr "Je v pořádku pro předponu nebo příponu nezadat žádný text , například v ``{series:|| - }``. Šablona ``{title:||}`` je stejná jako ``{title}``."
240
241 #: ../../../__w/calibre/calibre/manual/template_lang.rst:89
242 msgid "**Formatting**"
243 msgstr "**Formátování**"
244
245 #: ../../../__w/calibre/calibre/manual/template_lang.rst:91
246 msgid ""
247 "Suppose you want the ``series_index`` to be formatted as three digits with "
248 "leading zeros. This does the trick:"
249 msgstr "Předpokládejme, že chcete ``series_index`` formátovat jako tři číslice s počátečními nulami. To zajistí následující zápis:"
250
251 #: ../../../__w/calibre/calibre/manual/template_lang.rst:93
252 msgid "``{series_index:0>3s}`` - Three digits with leading zeros"
253 msgstr "``{series_index:0>3s}`` - tři číslice s počátečními nulami"
254
255 #: ../../../__w/calibre/calibre/manual/template_lang.rst:95
256 msgid "For trailing zeros, use:"
257 msgstr "Pro koncové nuly použijte:"
258
259 #: ../../../__w/calibre/calibre/manual/template_lang.rst:97
260 msgid "``{series_index:0<3s}`` - Three digits with trailing zeros"
261 msgstr "``{series_index:0<3s}`` - tři číslice s koncovými nulami"
262
263 #: ../../../__w/calibre/calibre/manual/template_lang.rst:99
264 msgid ""
265 "If you use series indices with fractional values, e.g., 1.1, you might want "
266 "the decimal points to line up. For example, you might want the indices 1 and"
267 " 2.5 to appear as 01.00 and 02.50 so that they will sort correctly on a "
268 "device that does lexical sorting. To do this, use:"
269 msgstr "Pokud používáte pořadí v sérii s desetinnými hodnotami, například 1.1, můžete chtít zarovnat desetinné tečky. Například můžete chtít, aby se pořadí 1 a 2.5 zobrazila jako 01.00 a 02.50, aby se správně řadila na zařízení, které používá lexikální řazení. Toho dosáhnete takto:"
270
271 #: ../../../__w/calibre/calibre/manual/template_lang.rst:101
272 msgid ""
273 "``{series_index:0>5.2f}`` - Five characters consisting of two digits with "
274 "leading zeros, a decimal point, then 2 digits after the decimal point."
275 msgstr "``{series_index:0>5.2f}`` - pět znaků tvořených dvěma číslicemi s počátečními nulami, desetinnou tečkou a 2 číslicemi za desetinnou tečkou."
276
277 #: ../../../__w/calibre/calibre/manual/template_lang.rst:103
278 msgid "If you want only the first two letters of the data, use:"
279 msgstr "Pokud chcete použít pouze první dvě písmena dat, použijte:"
280
281 #: ../../../__w/calibre/calibre/manual/template_lang.rst:105
282 msgid ""
283 "``{author_sort:.2}`` - Only the first two letters of the author sort name"
284 msgstr "``{author_sort:.2}`` - pouze první dvě písmena hodnoty řazení autora"
285
286 #: ../../../__w/calibre/calibre/manual/template_lang.rst:107
287 msgid ""
288 "Much of the calibre template language formatting comes from Python. For more"
289 " details on the syntax of these advanced formatting operations see the "
290 "`Python documentation "
291 "<https://docs.python.org/3/library/string.html#formatstrings>`_."
292 msgstr "Velká část formátování v jazyce šablon calibre pochází z Pythonu. Další podrobnosti o syntaxi těchto pokročilých formátovacích operací najdete v `dokumentaci Pythonu <https://docs.python.org/3/library/string.html#formatstrings>`_."
293
294 #: ../../../__w/calibre/calibre/manual/template_lang.rst:111
295 msgid "Using templates to define custom columns"
296 msgstr "Použití šablon k definování vlastních sloupců"
297
298 #: ../../../__w/calibre/calibre/manual/template_lang.rst:113
299 msgid ""
300 "Templates can be used to display information that isn't in calibre metadata,"
301 " or to display metadata differently from calibre's normal format. For "
302 "example, you might want to show the ``ISBN``, a field that calibre does not "
303 "display. You can accomplish this creating a custom column with the type "
304 "`Column built from other columns` (hereafter called `composite columns`) and"
305 " providing a template to generate the displayed text. The column will "
306 "display the result of evaluating the template. For example, to display the "
307 "ISBN, create the column and enter ``{identifiers:select(isbn)}`` in the "
308 "template box. To display a column containing the values of two series custom"
309 " columns, separated by a comma, use ``{#series1:||,}{#series2}``."
310 msgstr "Šablony lze použít k zobrazení informací, které nejsou v metadatech calibre, nebo k zobrazení metadat jinak než v běžném formátu calibre. Můžete například chtít zobrazit ``ISBN``, což je pole, které calibre nezobrazuje. Toho dosáhnete vytvořením vlastního sloupce typu `Sloupec sestavený z jiných sloupců` (dále jen `složené sloupce`) a zadáním šablony, která vygeneruje zobrazovaný text. Sloupec zobrazí výsledek vyhodnocení šablony. Chcete-li například zobrazit ISBN, vytvořte sloupec a do pole šablony zadejte ``{identifiers:select(isbn)}``. Chcete-li zobrazit sloupec obsahující hodnoty dvou vlastních sloupců série oddělené čárkou, použijte ``{#series1:||,}{#series2}``."
311
312 #: ../../../__w/calibre/calibre/manual/template_lang.rst:115
313 msgid "Composite columns can use any template option, including formatting."
314 msgstr "Složené sloupce mohou používat libovolnou možnost šablony, včetně formátování."
315
316 #: ../../../__w/calibre/calibre/manual/template_lang.rst:117
317 msgid ""
318 "Note: You cannot edit the data displayed in a composite column. Instead you "
319 "edit the source columns. If you edit a composite column, for example by "
320 "double-clicking it, calibre will open the template for editing, not the "
321 "underlying data."
322 msgstr "Poznámka: Data zobrazená ve složeném sloupci nemůžete upravovat. Místo toho upravujete zdrojové sloupce. Pokud upravíte složený sloupec, například dvojitým kliknutím, calibre otevře k úpravám šablonu, ne podkladová data."
323
324 #: ../../../__w/calibre/calibre/manual/template_lang.rst:121
325 msgid "Templates and plugboards"
326 msgstr "Šablony a zásuvné panely"
327
328 #: ../../../__w/calibre/calibre/manual/template_lang.rst:123
329 msgid ""
330 "Plugboards are used for changing the metadata written into books during "
331 "send-to-device and save-to-disk operations. A plugboard permits you to "
332 "specify a template to provide the data to write into the book's metadata. "
333 "You can use plugboards to modify the following fields: authors, author_sort,"
334 " language, publisher, tags, title, title_sort. This feature helps people who"
335 " want to use different metadata in books on devices to solve sorting or "
336 "display issues."
337 msgstr "Zásuvné panely se používají ke změně metadat zapisovaných do knih během operací odeslání do zařízení a uložení na disk. Zásuvný panel umožňuje zadat šablonu, která poskytne data zapisovaná do metadat knihy. Pomocí zásuvných panelů můžete upravit následující pole: authors, author_sort, language, publisher, tags, title, title_sort. Tato funkce pomáhá lidem, kteří chtějí v knihách na zařízeních používat jiná metadata kvůli řešení problémů s řazením nebo zobrazením."
338
339 #: ../../../__w/calibre/calibre/manual/template_lang.rst:125
340 msgid ""
341 "When you create a plugboard, you specify the format and device for which the"
342 " plugboard is to be used. A special device is provided, ``save_to_disk``, "
343 "that is used when saving formats (as opposed to sending them to a device). "
344 "Once you have chosen the format and device, you choose the metadata fields "
345 "to change, providing templates to supply the new values. These templates are"
346 " `connected` to their destination fields, hence the name `plugboards`. You "
347 "can of course use composite columns in these templates."
348 msgstr "Při vytváření zásuvného panelu určíte formát a zařízení, pro které se má zásuvný panel použít. K dispozici je speciální zařízení ``save_to_disk``, které se používá při ukládání formátů (na rozdíl od jejich odesílání do zařízení). Jakmile zvolíte formát a zařízení, vyberete pole metadat, která se mají změnit, a zadáte šablony, které dodají nové hodnoty. Tyto šablony jsou `připojeny` ke svým cílovým polím, odtud název `zásuvné panely`. V těchto šablonách samozřejmě můžete používat složené sloupce."
349
350 #: ../../../__w/calibre/calibre/manual/template_lang.rst:127
351 msgid ""
352 "Plugboards are quite flexible and can be written in Single Function Mode, "
353 "Template Program Mode, General Program Mode, or Python Template mode."
354 msgstr "Zásuvné panely jsou poměrně flexibilní a lze je psát v režimu jedné funkce, režimu programu šablony, obecném režimu programu nebo režimu pythonové šablony."
355
356 #: ../../../__w/calibre/calibre/manual/template_lang.rst:129
357 msgid ""
358 "When a plugboard might apply (Content server, save to disk, or send to "
359 "device), calibre searches the defined plugboards to choose the correct one "
360 "for the given format and device. For example, to find the appropriate "
361 "plugboard for an EPUB book being sent to an ANDROID device, calibre searches"
362 " the plugboards using the following search order:"
363 msgstr "Když může být zásuvný panel použit (Server s obsahem, uložení na disk nebo odeslání do zařízení), calibre prohledá definované zásuvné panely a vybere správný pro daný formát a zařízení. Například při hledání vhodného zásuvného panelu pro knihu EPUB odesílanou do zařízení ANDROID calibre prohledá zásuvné panely v následujícím pořadí:"
364
365 #: ../../../__w/calibre/calibre/manual/template_lang.rst:133
366 msgid ""
367 "a plugboard with an exact match on format and device, e.g., ``EPUB`` and "
368 "``ANDROID``"
369 msgstr "zásuvný panel s přesnou shodou formátu a zařízení, např. ``EPUB`` a ``ANDROID``"
370
371 #: ../../../__w/calibre/calibre/manual/template_lang.rst:134
372 msgid ""
373 "a plugboard with an exact match on format and the special ``any device`` "
374 "choice, e.g., ``EPUB`` and ``any device``"
375 msgstr "zásuvný panel s přesnou shodou formátu a speciální volbou ``any device``, např. ``EPUB`` a ``any device``"
376
377 #: ../../../__w/calibre/calibre/manual/template_lang.rst:135
378 msgid ""
379 "a plugboard with the special ``any format`` choice and an exact match on "
380 "device, e.g., ``any format`` and ``ANDROID``"
381 msgstr "zásuvný panel se speciální volbou ``any format`` a přesnou shodou zařízení, např. ``any format`` a ``ANDROID``"
382
383 #: ../../../__w/calibre/calibre/manual/template_lang.rst:136
384 msgid "a plugboard with ``any format`` and ``any device``"
385 msgstr "zásuvný panel s ``any format`` a ``any device``"
386
387 #: ../../../__w/calibre/calibre/manual/template_lang.rst:138
388 msgid ""
389 "The tags and authors fields have special treatment, because both of these "
390 "fields can hold more than one item. A book can have many tags and many "
391 "authors. When you specify that one of these two fields is to be changed, the"
392 " template's result is examined to see if more than one item is there. For "
393 "tags, the result is cut apart wherever calibre finds a comma. For example, "
394 "if the template produces the value ``Thriller, Horror``, then the result "
395 "will be two tags, ``Thriller`` and ``Horror``. There is no way to put a "
396 "comma in the middle of a tag."
397 msgstr "Pole tags a authors mají speciální zpracování, protože obě tato pole mohou obsahovat více než jednu položku. Kniha může mít mnoho štítků a mnoho autorů. Když určíte, že se má jedno z těchto dvou polí změnit, výsledek šablony se zkontroluje, zda obsahuje více než jednu položku. U štítků se výsledek rozdělí všude, kde calibre najde čárku. Pokud například šablona vytvoří hodnotu ``Thriller, Horror``, výsledkem budou dva štítky, ``Thriller`` a ``Horror``. Čárku doprostřed štítku nelze vložit."
398
399 #: ../../../__w/calibre/calibre/manual/template_lang.rst:141
400 msgid ""
401 "The same thing happens for authors, but using a different character for the "
402 "cut, a `&` (ampersand) instead of a comma. For example, if the template "
403 "produces the value ``Blogs, Joe&Posts, Susan``, then the book will end up "
404 "with two authors, ``Blogs, Joe`` and ``Posts, Susan``. If the template "
405 "produces the value ``Blogs, Joe;Posts, Susan``, then the book will have one "
406 "author with a rather strange name."
407 msgstr "Totéž se děje u autorů, ale pro rozdělení se místo čárky používá jiný znak, `&` (ampersand). Pokud například šablona vytvoří hodnotu ``Blogs, Joe&Posts, Susan``, kniha bude mít nakonec dva autory, ``Blogs, Joe`` a ``Posts, Susan``. Pokud šablona vytvoří hodnotu ``Blogs, Joe;Posts, Susan``, bude mít kniha jednoho autora s poměrně zvláštním jménem."
408
409 #: ../../../__w/calibre/calibre/manual/template_lang.rst:143
410 msgid ""
411 "Plugboards affect the metadata written into the book when it is saved to "
412 "disk or written to the device. Plugboards do not affect the metadata used by"
413 " ``save to disk`` and ``send to device`` to create the file names. Instead, "
414 "file names are constructed using the templates entered on the appropriate "
415 "preferences window."
416 msgstr "Zásuvné panely ovlivňují metadata zapisovaná do knihy při jejím uložení na disk nebo zápisu do zařízení. Zásuvné panely neovlivňují metadata, která ``save to disk`` a ``send to device`` používají k vytváření názvů souborů. Názvy souborů se místo toho sestavují pomocí šablon zadaných v příslušném okně předvoleb."
417
418 #: ../../../__w/calibre/calibre/manual/template_lang.rst:148
419 msgid "Using functions in templates - Single Function Mode"
420 msgstr "Použití funkcí v šablonách - Režim jedné funkce"
421
422 #: ../../../__w/calibre/calibre/manual/template_lang.rst:150
423 msgid ""
424 "Suppose you want to display the value of a field in upper case when that "
425 "field is normally in title case. You can do this using `template functions`."
426 " For example, to display the title in upper case use the ``uppercase`` "
427 "function, as in ``{title:uppercase()}``. To display it in title case, use "
428 "``{title:titlecase()}``."
429 msgstr "Předpokládejme, že chcete zobrazit hodnotu pole velkými písmeny, zatímco běžně je toto pole ve formátu velkých počátečních písmen. To můžete udělat pomocí `funkcí šablony`. Chcete-li například zobrazit název velkými písmeny, použijte funkci ``uppercase`` jako v ``{title:uppercase()}``. Chcete-li jej zobrazit s velkými počátečními písmeny, použijte ``{title:titlecase()}``."
430
431 #: ../../../__w/calibre/calibre/manual/template_lang.rst:152
432 msgid ""
433 "Functions go into the format part of the template, after the ``:`` and "
434 "before the first ``|`` or the closing ``}`` if no prefix/suffix is used. If "
435 "you have both a format and a function reference, the function comes after a "
436 "second ``:``. Functions return the value of the column specified in the "
437 "template, suitably modified."
438 msgstr "Funkce patří do formátovací části šablony, za ``:`` a před první ``|`` nebo před uzavírací ``}``, pokud se nepoužívá předpona/přípona. Pokud máte současně formát i odkaz na funkci, funkce následuje za druhou ``:``. Funkce vracejí hodnotu sloupce určeného ve vhodně upravené šabloně."
439
440 #: ../../../__w/calibre/calibre/manual/template_lang.rst:154
441 msgid "The syntax for using functions is one of::"
442 msgstr "Syntaxe použití funkcí je jedna z následujících::"
443
444 #: ../../../__w/calibre/calibre/manual/template_lang.rst:161
445 msgid ""
446 "Function names must always be followed by opening and closing parentheses. "
447 "Some functions require extra values (arguments), and these go inside the "
448 "parentheses. Arguments are separated by commas. Literal commas (commas as "
449 "text, not argument separators) must be preceded by a backslash (``\\``) . "
450 "The last (or only) argument cannot contain a textual closing parenthesis."
451 msgstr "Za názvy funkcí musí vždy následovat otevírací a uzavírací závorka. Některé funkce vyžadují další hodnoty (argumenty) a ty se zapisují do závorek. Argumenty jsou oddělené čárkami. Doslovným čárkám (čárkám jako textu, ne jako oddělovačům argumentů) musí předcházet zpětné lomítko (``\\``). Poslední (nebo jediný) argument nesmí obsahovat uzavírací závorku zadanou jako text."
452
453 #: ../../../__w/calibre/calibre/manual/template_lang.rst:163
454 msgid ""
455 "Functions are evaluated before format specifications and the prefix/suffix. "
456 "See further down for an example of using both a format and a function."
457 msgstr "Funkce se vyhodnocují před specifikacemi formátu a předponou/příponou. Níže najdete příklad použití formátu i funkce současně."
458
459 #: ../../../__w/calibre/calibre/manual/template_lang.rst:165
460 msgid ""
461 "**Important**: If you have programming experience, please note that the "
462 "syntax in `Single Function Mode` is not what you expect. Strings are not "
463 "quoted and spaces are significant. All arguments are considered to be "
464 "constants; there are no expressions."
465 msgstr "**Důležité**: Pokud máte zkušenosti s programováním, všimněte si, že syntaxe v `režimu jedné funkce` není taková, jakou byste očekávali. Řetězce se neuzavírají do uvozovek a mezery jsou významné. Všechny argumenty se považují za konstanty; neexistují zde žádné výrazy."
466
467 #: ../../../__w/calibre/calibre/manual/template_lang.rst:167
468 msgid ""
469 "**Do not use subtemplates (`{ ... }`) as function arguments.** Instead, use "
470 ":ref:`Template Program Mode <template_mode>` and :ref:`General Program Mode "
471 "<general_mode>`."
472 msgstr "**Nepoužívejte podšablony (`{ ... }`) jako argumenty funkcí.** Místo toho použijte :ref:`režim programu šablony <template_mode>` a :ref:`obecný režim programu <general_mode>`."
473
474 #: ../../../__w/calibre/calibre/manual/template_lang.rst:169
475 msgid "Notes on calling functions in Single Function Mode:"
476 msgstr "Poznámky k volání funkcí v režimu jedné funkce:"
477
478 #: ../../../__w/calibre/calibre/manual/template_lang.rst:171
479 msgid ""
480 "When functions are used in Single Function Mode, the first parameter, "
481 "``value``, is automatically replaced by the content of the field specified "
482 "in the template. For example, when the template ``{title:capitalize()}`` is "
483 "processed, the content of the ``title`` field is passed as the parameter "
484 "``value`` to the capitalize function."
485 msgstr "Při použití funkcí v režimu jedné funkce se první parametr, ``value``, automaticky nahradí obsahem pole určeného v šabloně. Například při zpracování šablony ``{title:capitalize()}`` se obsah pole ``title`` předá funkci capitalize jako parametr ``value``."
486
487 #: ../../../__w/calibre/calibre/manual/template_lang.rst:172
488 msgid ""
489 "In the function documentation, the notation ``[something]*`` means that "
490 "``something`` can be repeated zero or more times. The notation "
491 "``[something]+`` means that the ``something`` is repeated one or more times "
492 "(must exist at least one time)."
493 msgstr "V dokumentaci funkcí zápis ``[something]*`` znamená, že ``something`` se může opakovat nula nebo vícekrát. Zápis ``[something]+`` znamená, že se ``something`` opakuje jednou nebo vícekrát (musí existovat alespoň jednou)."
494
495 #: ../../../__w/calibre/calibre/manual/template_lang.rst:173
496 msgid ""
497 "Some functions use regular expressions. In the template language regular "
498 "expression matching is case-insensitive."
499 msgstr "Některé funkce využívají regulární výrazy. V jazyce šablon se při porovnávání regulárních výrazů nerozlišují velká a malá písmena."
500
501 #: ../../../__w/calibre/calibre/manual/template_lang.rst:175
502 msgid ""
503 "Functions are documented in :ref:`template_functions_reference`. The "
504 "documentation tells you what arguments the functions require and what the "
505 "functions do. For example, here is the documentation of the "
506 ":ref:`ff_ifempty` function."
507 msgstr "Funkce jsou zdokumentovány v :ref:`template_functions_reference`. Dokumentace uvádí, jaké argumenty funkce vyžadují a co funkce dělají. Například zde je dokumentace funkce :ref:`ff_ifempty`."
508
509 #: ../../../__w/calibre/calibre/manual/template_lang.rst:179
510 msgid ""
511 "You see that the function requires two arguments, ``value`` and "
512 "``text_if_empty``. However, because we are using Single Function Mode, we "
513 "omit the ``value`` argument, passing only ``text_if_empty``. For example, "
514 "this template::"
515 msgstr "Vidíte, že funkce vyžaduje dva argumenty, ``value`` a ``text_if_empty``. Protože ale používáme režim jedné funkce, argument ``value`` vynecháme a předáme pouze ``text_if_empty``. Například tato šablona::"
516
517 #: ../../../__w/calibre/calibre/manual/template_lang.rst:183
518 msgid ""
519 "shows the tags for a book, if any. If it has no tags then it shows `No tags "
520 "on this book`."
521 msgstr "zobrazí štítky knihy, pokud nějaké má. Pokud nemá žádné štítky, zobrazí `No tags on this book`."
522
523 #: ../../../__w/calibre/calibre/manual/template_lang.rst:185
524 msgid ""
525 "The following functions are usable in Single Function Mode because their "
526 "first parameter is ``value``."
527 msgstr "Následující funkce lze použít v režimu jedné funkce, protože jejich prvním parametrem je ``value``."
528
529 #: ../../../__w/calibre/calibre/manual/template_lang.rst:227
530 msgid "**Using functions and formatting in the same template**"
531 msgstr "**Použití funkcí a formátování ve stejné šabloně**"
532
533 #: ../../../__w/calibre/calibre/manual/template_lang.rst:229
534 msgid ""
535 "Suppose you have an integer custom column ``#myint`` that you want displayed"
536 " with leading zeros, as in ``003``. One way to do this is to use a format of"
537 " ``0>3s``. However, by default if a number (integer or float) equals zero "
538 "then the value is displayed as the empty string so zero values will produce "
539 "the empty string, not ``000``. If you want to see ``000`` values then you "
540 "use both the format string and the ``ifempty`` function to change the empty "
541 "value back to a zero. The template would be::"
542 msgstr "Předpokládejme, že máte celočíselný vlastní sloupec ``#myint``, který chcete zobrazit s počátečními nulami, například jako ``003``. Jedním způsobem je použít formát ``0>3s``. Ve výchozím nastavení se však číslo (celé číslo nebo číslo s plovoucí desetinnou čárkou) rovné nule zobrazí jako prázdný řetězec, takže nulové hodnoty vytvoří prázdný řetězec, ne ``000``. Pokud chcete vidět hodnoty ``000``, použijte formátovací řetězec i funkci ``ifempty`` a změňte prázdnou hodnotu zpět na nulu. Šablona by byla::"
543
544 #: ../../../__w/calibre/calibre/manual/template_lang.rst:233
545 msgid ""
546 "Note that you can use the prefix and suffix as well. If you want the number "
547 "to appear as ``[003]`` or ``[000]``, then use the template::"
548 msgstr "Všimněte si, že můžete použít také předponu a příponu. Pokud chcete, aby se číslo zobrazilo jako ``[003]`` nebo ``[000]``, použijte šablonu::"
549
550 #: ../../../__w/calibre/calibre/manual/template_lang.rst:240
551 msgid "General Program Mode"
552 msgstr "Obecný režim programu"
553
554 #: ../../../__w/calibre/calibre/manual/template_lang.rst:242
555 msgid ""
556 "`General Program Mode` (`GPM`) replaces `template expressions` with a "
557 "program written in the `template language`. The syntax of the language is "
558 "defined by the following grammar::"
559 msgstr "`Obecný režim programu` (`GPM`) nahrazuje `výrazy šablony` programem napsaným v `jazyce šablon`. Syntaxe jazyka je definována následující gramatikou::"
560
561 #: ../../../__w/calibre/calibre/manual/template_lang.rst:295
562 msgid ""
563 "a ``top_expression`` always has a value. The value of an ``expression_list``"
564 " is the value of the last ``top_expression`` in the list. For example, the "
565 "value of the expression list ``1;2;'foobar';3`` is ``3``."
566 msgstr "``top_expression`` má vždy hodnotu. Hodnota ``expression_list`` je hodnota posledního ``top_expression`` v seznamu. Například hodnota seznamu výrazů ``1;2;'foobar';3`` je ``3``."
567
568 #: ../../../__w/calibre/calibre/manual/template_lang.rst:296
569 msgid "In a logical context, any non-empty value is ``True``"
570 msgstr "V logickém kontextu je každá neprázdná hodnota ``True``"
571
572 #: ../../../__w/calibre/calibre/manual/template_lang.rst:297
573 msgid "In a logical context, the empty value is ``False``"
574 msgstr "V logickém kontextu je prázdná hodnota ``False``"
575
576 #: ../../../__w/calibre/calibre/manual/template_lang.rst:298
577 msgid ""
578 "Strings and numbers can be used interchangeably. For example, ``10`` and "
579 "``'10'`` are the same thing."
580 msgstr "Řetězce a čísla lze používat zaměnitelně. Například ``10`` a ``'10'`` jsou totéž."
581
582 #: ../../../__w/calibre/calibre/manual/template_lang.rst:299
583 msgid ""
584 "Comments are lines starting with a '#' character, possibly preceded by "
585 "blanks or tabs."
586 msgstr "Komentáře jsou řádky začínající znakem „#“, kterému mohou předcházet mezery nebo tabulátory."
587
588 #: ../../../__w/calibre/calibre/manual/template_lang.rst:301
589 msgid "**Operator precedence**"
590 msgstr "**Priorita operátorů**"
591
592 #: ../../../__w/calibre/calibre/manual/template_lang.rst:303
593 msgid ""
594 "The operator precedence (order of evaluation) from highest (evaluated first)"
595 " to lowest (evaluated last) is:"
596 msgstr "Priorita operátorů (pořadí vyhodnocení) od nejvyšší (vyhodnocuje se jako první) po nejnižší (vyhodnocuje se jako poslední) je:"
597
598 #: ../../../__w/calibre/calibre/manual/template_lang.rst:305
599 msgid ""
600 "Function calls, constants, parenthesized expressions, statement expressions,"
601 " assignment expressions, field references."
602 msgstr "Volání funkcí, konstanty, výrazy v závorkách, výrazy příkazů, přiřazovací výrazy, odkazy na pole."
603
604 #: ../../../__w/calibre/calibre/manual/template_lang.rst:306
605 msgid ""
606 "Unary plus (``+``) and minus (``-``). These operators evaluate right to "
607 "left."
608 msgstr "Unární plus (``+``) a minus (``-``). Tyto operátory se vyhodnocují zprava doleva."
609
610 #: ../../../__w/calibre/calibre/manual/template_lang.rst:308
611 msgid ""
612 "These and all the other arithmetic operators return integers if the "
613 "expression results in a fractional part equal to zero. For example, if an "
614 "expression returns ``3.0`` it is changed to ``3``."
615 msgstr "Tyto i všechny ostatní aritmetické operátory vracejí celá čísla, pokud výsledkem výrazu je desetinná část rovná nule. Pokud například výraz vrátí ``3.0``, změní se na ``3``."
616
617 #: ../../../__w/calibre/calibre/manual/template_lang.rst:309
618 msgid ""
619 "Multiply (``*``) and divide (``/``). These operators are associative and "
620 "evaluate left to right. Use parentheses if you want to change the order of "
621 "evaluation."
622 msgstr "Násobení (``*``) a dělení (``/``). Tyto operátory jsou asociativní a vyhodnocují se zleva doprava. Pokud chcete změnit pořadí vyhodnocení, použijte závorky."
623
624 #: ../../../__w/calibre/calibre/manual/template_lang.rst:310
625 msgid ""
626 "Add (``+``) and subtract (``-``). These operators are associative and "
627 "evaluate left to right."
628 msgstr "Sčítání (``+``) a odčítání (``-``). Tyto operátory jsou asociativní a vyhodnocují se zleva doprava."
629
630 #: ../../../__w/calibre/calibre/manual/template_lang.rst:311
631 msgid ""
632 "Numeric and string comparisons. These operators return ``'1'`` if the "
633 "comparison succeeds, otherwise the empty string (``''``). Comparisons are "
634 "not associative: ``a < b < c`` is a syntax error."
635 msgstr "Číselná a řetězcová porovnání. Tyto operátory vracejí ``'1'``, pokud je porovnání úspěšné, jinak prázdný řetězec (``''``). Porovnání nejsou asociativní: ``a < b < c`` je syntaktická chyba."
636
637 #: ../../../__w/calibre/calibre/manual/template_lang.rst:312
638 msgid ""
639 "String concatenation (``&``). The ``&`` operator returns a string formed by "
640 "concatenating the left-hand and right-hand expressions. Example: ``'aaa' & "
641 "'bbb'`` returns ``'aaabbb'``. The operator is associative and evaluates left"
642 " to right."
643 msgstr "Zřetězení řetězců (``&``). Operátor ``&`` vrací řetězec vytvořený zřetězením levého a pravého výrazu. Příklad: ``'aaa' & 'bbb'`` vrátí ``'aaabbb'``. Operátor je asociativní a vyhodnocuje se zleva doprava."
644
645 #: ../../../__w/calibre/calibre/manual/template_lang.rst:313
646 msgid ""
647 "Unary logical not (``!``). This operator returns ``'1'`` if the expression "
648 "is False (evaluates to the empty string), otherwise ``''``."
649 msgstr "Unární logické ne (``!``). Tento operátor vrací ``'1'``, pokud je výraz False (vyhodnotí se jako prázdný řetězec), jinak vrací ``''``."
650
651 #: ../../../__w/calibre/calibre/manual/template_lang.rst:314
652 msgid ""
653 "Logical and (``&&``). This operator returns '1' if both the left-hand and "
654 "right-hand expressions are True, or the empty string ``''`` if either is "
655 "False. It is associative, evaluates left to right, and does `short-"
656 "circuiting <https://chortle.ccsu.edu/java5/Notes/chap40/ch40_2.html>`_."
657 msgstr "Logické a (``&&``). Tento operátor vrací '1', pokud jsou levý i pravý výraz True, nebo prázdný řetězec ``''``, pokud je kterýkoli z nich False. Je asociativní, vyhodnocuje se zleva doprava a používá `zkratové vyhodnocování <https://chortle.ccsu.edu/java5/Notes/chap40/ch40_2.html>`_."
658
659 #: ../../../__w/calibre/calibre/manual/template_lang.rst:315
660 msgid ""
661 "Logical or (``||``). This operator returns ``'1'`` if either the left-hand "
662 "or right-hand expression is True, or ``''`` if both are False. It is "
663 "associative, evaluates left to right, and does `short-circuiting "
664 "<https://chortle.ccsu.edu/java5/Notes/chap40/ch40_2.html>`_. It is an "
665 "`inclusive or`, returning ``'1'`` if both the left- and right-hand "
666 "expressions are True."
667 msgstr "Logické nebo (``||``). Tento operátor vrací ``'1'``, pokud je levý nebo pravý výraz True, nebo ``''``, pokud jsou oba False. Je asociativní, vyhodnocuje se zleva doprava a používá `zkratové vyhodnocování <https://chortle.ccsu.edu/java5/Notes/chap40/ch40_2.html>`_. Je to `inkluzivní nebo`, které vrací ``'1'``, pokud jsou levý i pravý výraz True."
668
669 #: ../../../__w/calibre/calibre/manual/template_lang.rst:317
670 msgid "**Field references**"
671 msgstr "**Odkazy na pole**"
672
673 #: ../../../__w/calibre/calibre/manual/template_lang.rst:319
674 msgid ""
675 "A ``field_reference`` evaluates to the value of the metadata field named by "
676 "lookup name that follows the ``$`` or ``$$``. Using ``$`` is equivalent to "
677 "using the :ref:`ff_field` function. Using ``$$`` is equivalent to using the "
678 ":ref:`ff_raw_field` function. Examples::"
679 msgstr "``field_reference`` se vyhodnotí jako hodnota pole metadat určeného názvem vyhledávání, který následuje za ``$`` nebo ``$$``. Použití ``$`` je ekvivalentní použití funkce :ref:`ff_field`. Použití ``$$`` je ekvivalentní použití funkce :ref:`ff_raw_field`. Příklady::"
680
681 #: ../../../__w/calibre/calibre/manual/template_lang.rst:326
682 msgid "**If expressions**"
683 msgstr "**Výrazy if**"
684
685 #: ../../../__w/calibre/calibre/manual/template_lang.rst:328
686 msgid ""
687 "``If`` expressions first evaluate the ``condition``. If the ``condition`` is"
688 " True (a non-empty value) then the ``expression_list`` in the ``then`` "
689 "clause is evaluated. If it is False then if present the ``expression_list`` "
690 "in the ``elif`` or ``else`` clause is evaluated. The ``elif`` and ``else`` "
691 "parts are optional. The words ``if``, ``then``, ``elif``, ``else``, and "
692 "``fi`` are reserved; you cannot use them as identifier names. You can put "
693 "newlines and white space wherever they make sense. The ``condition`` is a "
694 "``top_expression`` not an ``expression_list``; semicolons are not allowed. "
695 "The ``expression_lists`` are semicolon-separated sequences of "
696 "``top_expressions``. An ``if`` expression returns the result of the last "
697 "``top_expression`` in the evaluated ``expression_list``, or the empty string"
698 " if no expression list was evaluated."
699 msgstr "Výrazy ``if`` nejprve vyhodnotí ``condition``. Pokud je ``condition`` True (neprázdná hodnota), vyhodnotí se ``expression_list`` ve větvi ``then``. Pokud je False, vyhodnotí se, pokud existuje, ``expression_list`` ve větvi ``elif`` nebo ``else``. Části ``elif`` a ``else`` jsou volitelné. Slova ``if``, ``then``, ``elif``, ``else`` a ``fi`` jsou rezervovaná; nemůžete je použít jako názvy identifikátorů. Nové řádky a bílé znaky můžete vložit všude, kde dávají smysl. ``condition`` je ``top_expression``, ne ``expression_list``; středníky nejsou povoleny. ``expression_lists`` jsou sekvence ``top_expressions`` oddělené středníky. Výraz ``if`` vrátí výsledek posledního ``top_expression`` ve vyhodnoceném ``expression_list`` nebo prázdný řetězec, pokud nebyl vyhodnocen žádný seznam výrazů."
700
701 #: ../../../__w/calibre/calibre/manual/template_lang.rst:330
702 msgid "Examples::"
703 msgstr "Příklady::"
704
705 #: ../../../__w/calibre/calibre/manual/template_lang.rst:343
706 msgid "Nested ``if`` example::"
707 msgstr "Příklad vnořeného ``if``::"
708
709 #: ../../../__w/calibre/calibre/manual/template_lang.rst:356
710 msgid ""
711 "As said above, an ``if`` produces a value. This means that all the following"
712 " are equivalent::"
713 msgstr "Jak bylo uvedeno výše, ``if`` produkuje hodnotu. To znamená, že všechny následující zápisy jsou ekvivalentní::"
714
715 #: ../../../__w/calibre/calibre/manual/template_lang.rst:362
716 msgid ""
717 "For example, this program returns the value of the ``series`` column if the "
718 "book has a series, otherwise the value of the ``title`` column::"
719 msgstr "Například tento program vrátí hodnotu sloupce ``series``, pokud má kniha sérii, jinak hodnotu sloupce ``title``::"
720
721 #: ../../../__w/calibre/calibre/manual/template_lang.rst:366
722 msgid "**For expressions**"
723 msgstr "**Výrazy for**"
724
725 #: ../../../__w/calibre/calibre/manual/template_lang.rst:368
726 msgid ""
727 "The ``for`` expression iterates over a list of values, processing them one "
728 "at a time. The ``list_expression`` must evaluate either to a metadata field "
729 "``lookup name`` e.g., ``tags`` or ``#genre``, or to a list of values. The "
730 ":ref:`ff_range` generates a list of numbers. If the result is a valid "
731 "``lookup name`` then the field's value is fetched and the separator "
732 "specified for that field type is used. If the result isn't a valid lookup "
733 "name then it is assumed to be a list of values. The list is assumed to be "
734 "separated by commas unless the optional keyword ``separator`` is supplied, "
735 "in which case the list values must be separated by the result of evaluating "
736 "the ``separator_expr``. A separator cannot be used if the list is generated "
737 "by ``range()``. Each value in the list is assigned to the specified variable"
738 " then the ``expression_list`` is evaluated. You can use ``break`` to jump "
739 "out of the loop, and ``continue`` to jump to the beginning of the loop for "
740 "the next iteration."
741 msgstr "Výraz ``for`` iteruje přes seznam hodnot a zpracovává je po jedné. ``list_expression`` se musí vyhodnotit buď jako ``název vyhledávání`` pole metadat, např. ``tags`` nebo ``#genre``, nebo jako seznam hodnot. :ref:`ff_range` generuje seznam čísel. Pokud je výsledkem platný ``název vyhledávání``, načte se hodnota pole a použije se oddělovač určený pro tento typ pole. Pokud výsledkem není platný název vyhledávání, předpokládá se, že jde o seznam hodnot. Předpokládá se, že seznam je oddělen čárkami, pokud není zadáno volitelné klíčové slovo ``separator``; v takovém případě musí být hodnoty seznamu odděleny výsledkem vyhodnocení ``separator_expr``. Oddělovač nelze použít, pokud seznam generuje ``range()``. Každá hodnota v seznamu se přiřadí zadané proměnné a potom se vyhodnotí ``expression_list``. Pomocí ``break`` můžete vyskočit ze smyčky a pomocí ``continue`` přejít na začátek smyčky pro další iteraci."
742
743 #: ../../../__w/calibre/calibre/manual/template_lang.rst:370
744 msgid ""
745 "Example: This template removes the first hierarchical name for each value in"
746 " Genre (``#genre``), constructing a list with the new names::"
747 msgstr "Příklad: Tato šablona odebere z každé hodnoty pole Žánr (``#genre``) první úroveň hierarchického názvu a vytvoří seznam s novými názvy::"
748
749 #: ../../../__w/calibre/calibre/manual/template_lang.rst:380
750 msgid ""
751 "If the original Genre is `History.Military, Science Fiction.Alternate "
752 "History, ReadMe` then the template returns `Military, Alternate History, "
753 "ReadMe`. You could use this template in calibre's :guilabel:`Edit metadata "
754 "in bulk -> Search & replace` with :guilabel:`Search for` set to ``template``"
755 " to strip off the first level of the hierarchy and assign the resulting "
756 "value to Genre."
757 msgstr "Pokud je původní Žánr `History.Military, Science Fiction.Alternate History, ReadMe`, šablona vrátí `Military, Alternate History, ReadMe`. Tuto šablonu můžete v calibre použít v :guilabel:`Upravit metadata hromadně -> Hledat a nahradit` s položkou :guilabel:`Hledat` nastavenou na ``template`` k odstranění první úrovně hierarchie a přiřazení výsledné hodnoty do pole Žánr."
758
759 #: ../../../__w/calibre/calibre/manual/template_lang.rst:383
760 msgid ""
761 "Note: the last line in the template, ``new_tags``, isn't strictly necessary "
762 "in this case because ``for`` returns the value of the last top_expression in"
763 " the expression list. The value of an assignment is the value of its "
764 "expression, so the value of the ``for`` statement is what was assigned to "
765 "``new_tags``."
766 msgstr "Poznámka: poslední řádek v šabloně, ``new_tags``, není v tomto případě nezbytně nutný, protože ``for`` vrací hodnotu posledního výrazu top_expression v seznamu výrazů. Hodnotou přiřazení je hodnota jeho výrazu, takže hodnota příkazu ``for`` je to, co bylo přiřazeno do ``new_tags``."
767
768 #: ../../../__w/calibre/calibre/manual/template_lang.rst:385
769 msgid "**with expressions**"
770 msgstr "**Výrazy with**"
771
772 #: ../../../__w/calibre/calibre/manual/template_lang.rst:387
773 msgid "The ``with`` expression:"
774 msgstr "Výraz ``with``:"
775
776 #: ../../../__w/calibre/calibre/manual/template_lang.rst:389
777 msgid ""
778 "changes the current book to the book with calibre book id (an integer) "
779 "produced by evaluating the ``top_expression``."
780 msgstr "změní aktuální knihu na knihu s ID knihy v calibre (celé číslo) získaným vyhodnocením ``top_expression``."
781
782 #: ../../../__w/calibre/calibre/manual/template_lang.rst:390
783 msgid "runs the ``expression_list``."
784 msgstr "provede ``expression_list``."
785
786 #: ../../../__w/calibre/calibre/manual/template_lang.rst:391
787 msgid "then resets the current book back to what it was."
788 msgstr "potom znovu nastaví jako aktuální původní knihu."
789
790 #: ../../../__w/calibre/calibre/manual/template_lang.rst:393
791 msgid ""
792 "The ``with`` expression returns the result of the last ``top_expression`` in"
793 " the evaluated ``expression_list``, or the empty string if no expression "
794 "list was evaluated."
795 msgstr "Výraz ``with`` vrátí výsledek posledního ``top_expression`` ve vyhodnoceném ``expression_list`` nebo prázdný řetězec, pokud nebyl vyhodnocen žádný seznam výrazů."
796
797 #: ../../../__w/calibre/calibre/manual/template_lang.rst:396
798 msgid ""
799 "For example, this template returns a list of the titles of each book "
800 "selected in the GUI::"
801 msgstr "Například tato šablona vrátí seznam názvů všech knih vybraných v GUI::"
802
803 #: ../../../__w/calibre/calibre/manual/template_lang.rst:408
804 msgid "**Return stmt**"
805 msgstr "**Příkaz return**"
806
807 #: ../../../__w/calibre/calibre/manual/template_lang.rst:410
808 msgid ""
809 "Return the value of the ``expression``. If executed in a function then it "
810 "returns the value of the expression to the caller. If executed in the "
811 "outermost context (the template) then it sets the value of the template to "
812 "the value of the expression and exits the template."
813 msgstr "Vrátí hodnotu výrazu ``expression``. Pokud se provede ve funkci, vrátí hodnotu výrazu volajícímu. Pokud se provede v nejvnějším kontextu (v šabloně), nastaví hodnotu šablony na hodnotu výrazu a šablonu ukončí."
814
815 #: ../../../__w/calibre/calibre/manual/template_lang.rst:412
816 msgid "**Function definition**"
817 msgstr "**Definice funkce**"
818
819 #: ../../../__w/calibre/calibre/manual/template_lang.rst:414
820 msgid ""
821 "If you have repeated code in a template then you can put that code into a "
822 "local function. The ``def`` keyword starts the definition. It is followed by"
823 " the function name, the argument list, then the code in the function. The "
824 "function definition ends with the ``fed`` keyword."
825 msgstr "Pokud máte v šabloně opakovaný kód, můžete tento kód vložit do lokální funkce. Klíčové slovo ``def`` zahajuje definici. Za ním následuje název funkce, seznam argumentů a potom kód funkce. Definice funkce končí klíčovým slovem ``fed``."
826
827 #: ../../../__w/calibre/calibre/manual/template_lang.rst:416
828 msgid ""
829 "Arguments are positional. When a function is called the supplied arguments "
830 "are matched left to right against the defined parameters, with the value of "
831 "the argument assigned to the parameter. It is an error to provide more "
832 "arguments than defined parameters. Parameters can have default values, such "
833 "as ``a = 25``. If an argument is not supplied for that parameter then the "
834 "default value is used, otherwise the parameter is set to the empty string."
835 msgstr "Argumenty jsou poziční. Při volání funkce se dodané argumenty párují zleva doprava s definovanými parametry a hodnota argumentu se přiřadí parametru. Zadání většího počtu argumentů, než je definovaných parametrů, je chyba. Parametry mohou mít výchozí hodnoty, například ``a = 25``. Pokud pro daný parametr není argument zadán, použije se výchozí hodnota; pokud žádná výchozí hodnota není, parametr se nastaví na prázdný řetězec."
836
837 #: ../../../__w/calibre/calibre/manual/template_lang.rst:418
838 msgid "The ``return`` statement can be used in a local function."
839 msgstr "Příkaz ``return`` lze použít v lokální funkci."
840
841 #: ../../../__w/calibre/calibre/manual/template_lang.rst:420
842 msgid "A function must be defined before it can be used."
843 msgstr "Funkce musí být definována předtím, než ji lze použít."
844
845 #: ../../../__w/calibre/calibre/manual/template_lang.rst:422
846 msgid ""
847 "Example: This template computes an approximate duration in years, months, "
848 "and days from a number of days. The function ``to_plural()`` formats the "
849 "computed values. Note that the example also uses the ``&`` operator::"
850 msgstr "Příklad: Tato šablona vypočítá z počtu dnů přibližnou dobu trvání v letech, měsících a dnech. Funkce ``to_plural()`` formátuje vypočtené hodnoty. Všimněte si, že příklad používá také operátor ``&``::"
851
852 #: ../../../__w/calibre/calibre/manual/template_lang.rst:437
853 msgid "**Relational operators**"
854 msgstr "**Relační operátory**"
855
856 #: ../../../__w/calibre/calibre/manual/template_lang.rst:439
857 msgid ""
858 "Relational operators return ``'1'`` if the comparison is true, otherwise the"
859 " empty string (``''``)."
860 msgstr "Relační operátory vracejí ``'1'``, pokud je porovnání pravdivé, jinak vracejí prázdný řetězec (``''``)."
861
862 #: ../../../__w/calibre/calibre/manual/template_lang.rst:441
863 msgid ""
864 "There are two forms of relational operators: string comparisons and numeric "
865 "comparisons."
866 msgstr "Existují dvě formy relačních operátorů: řetězcová porovnání a číselná porovnání."
867
868 #: ../../../__w/calibre/calibre/manual/template_lang.rst:443
869 msgid ""
870 "String comparisons do case-insensitive string comparison using lexical "
871 "order. The supported string comparison operators are ``==``, ``!=``, ``<``, "
872 "``<=``, ``>``, ``>=``, ``in``, ``inlist``, and ``inlist_field``. For the "
873 "``in``, ``inlist``, and ``inlist_field`` operators, the result of the left "
874 "hand expression is interpreted as a regular expression pattern. They are "
875 "true if the value of left-hand regular expression matches the value of the "
876 "right hand expression. The regular expressions are case-insensitive."
877 msgstr "Řetězcová porovnání porovnávají řetězce v lexikálním pořadí bez rozlišení velikosti písmen. Podporované operátory řetězcového porovnání jsou ``==``, ``!=``, ``<``, ``<=``, ``>``, ``>=``, ``in``, ``inlist`` a ``inlist_field``. U operátorů ``in``, ``inlist`` a ``inlist_field`` se výsledek levého výrazu interpretuje jako vzor regulárního výrazu. Tyto operátory jsou pravdivé, pokud regulární výraz z levé strany odpovídá hodnotě pravého výrazu. Regulární výrazy nerozlišují velikost písmen."
878
879 #: ../../../__w/calibre/calibre/manual/template_lang.rst:446
880 msgid ""
881 "The ``inlist`` operator is true if the left hand regular expression matches "
882 "any one of the items in the right hand list where the items in the list are "
883 "separated by commas. The ``inlist_field`` operator is true if the left hand "
884 "regular expression matches any of the items in the field (column) named by "
885 "the right hand expression, using the separator defined for the field. NB: "
886 "the ``inlist_field`` operator requires the right hand expression to evaluate"
887 " to a field name, while the ``inlist`` operator requires the right hand "
888 "expression to evaluate to a string containing a comma-separated list. "
889 "Because of this difference, ``inlist_field`` is substantially faster than "
890 "``inlist`` because no string conversions or list constructions are done."
891 msgstr "Operátor ``inlist`` je pravdivý, pokud regulární výraz na levé straně odpovídá kterékoli položce v seznamu na pravé straně, kde jsou položky seznamu odděleny čárkami. Operátor ``inlist_field`` je pravdivý, pokud regulární výraz na levé straně odpovídá kterékoli položce v poli (sloupci) pojmenovaném pravým výrazem, přičemž se použije oddělovač definovaný pro dané pole. Poznámka: operátor ``inlist_field`` vyžaduje, aby se pravý výraz vyhodnotil na název pole, zatímco operátor ``inlist`` vyžaduje, aby se pravý výraz vyhodnotil na řetězec obsahující seznam oddělený čárkami. Kvůli tomuto rozdílu je ``inlist_field`` podstatně rychlejší než ``inlist``, protože se neprovádějí žádné převody na řetězce ani vytváření seznamů."
892
893 #: ../../../__w/calibre/calibre/manual/template_lang.rst:448
894 msgid ""
895 "The numeric comparison operators are ``==#``, ``!=#``, ``<#``, ``<=#``, "
896 "``>#``, ``>=#``. The left and right expressions must evaluate to numeric "
897 "values with two exceptions: both the string value \"None\" (undefined field)"
898 " and the empty string evaluate to the value zero."
899 msgstr "Operátory číselného porovnání jsou ``==#``, ``!=#``, ``<#``, ``<=#``, ``>#`` a ``>=#``. Levý a pravý výraz se musí vyhodnotit na číselné hodnoty se dvěma výjimkami: řetězcová hodnota \"None\" (nedefinované pole) i prázdný řetězec se vyhodnotí na hodnotu nula."
900
901 #: ../../../__w/calibre/calibre/manual/template_lang.rst:450
902 msgid "Examples:"
903 msgstr "Příklady:"
904
905 #: ../../../__w/calibre/calibre/manual/template_lang.rst:452
906 msgid ""
907 "``program: field('series') == 'foo'`` returns ``'1'`` if the book's series "
908 "is `foo`, otherwise ``''``."
909 msgstr "``program: field('series') == 'foo'`` vrátí ``'1'``, pokud je série knihy `foo`, jinak ``''``."
910
911 #: ../../../__w/calibre/calibre/manual/template_lang.rst:453
912 msgid ""
913 "``program: 'f.o' in field('series')`` returns ``'1'`` if the book's series "
914 "matches the regular expression ``f.o`` (e.g., `foo`, `Off Onyx`, etc.), "
915 "otherwise ``''``."
916 msgstr "``program: 'f.o' in field('series')`` vrátí ``'1'``, pokud série knihy odpovídá regulárnímu výrazu ``f.o`` (např. `foo`, `Off Onyx` atd.), jinak ``''``."
917
918 #: ../../../__w/calibre/calibre/manual/template_lang.rst:454
919 msgid ""
920 "``program: 'science' inlist $#genre`` returns ``'1'`` if any of the values "
921 "retrieved from the book's genres match the regular expression ``science``, "
922 "e.g., `Science`, `History of Science`, `Science Fiction` etc., otherwise "
923 "``''``."
924 msgstr "``program: 'science' inlist $#genre`` vrátí ``'1'``, pokud některá z hodnot získaných ze žánrů knihy odpovídá regulárnímu výrazu ``science``, např. `Science`, `History of Science`, `Science Fiction` atd., jinak ``''``."
925
926 #: ../../../__w/calibre/calibre/manual/template_lang.rst:455
927 msgid ""
928 "``program: '^science$' inlist $#genre`` returns ``'1'`` if any of the book's"
929 " genres exactly match the regular expression ``^science$``, e.g., `Science`,"
930 " otherwise ``''``. The genres `History of Science` and `Science Fiction` "
931 "don't match."
932 msgstr "``program: '^science$' inlist $#genre`` vrátí ``'1'``, pokud některý ze žánrů knihy přesně odpovídá regulárnímu výrazu ``^science$``, např. `Science`, jinak ``''``. Žánry `History of Science` a `Science Fiction` neodpovídají."
933
934 #: ../../../__w/calibre/calibre/manual/template_lang.rst:456
935 msgid ""
936 "``program: 'asimov' inlist $authors`` returns ``'1'`` if any author matches "
937 "the regular expression ``asimov``, e.g., `Asimov, Isaac` or `Isaac Asimov`, "
938 "otherwise ``''``."
939 msgstr "``program: 'asimov' inlist $authors`` vrátí ``'1'``, pokud některý autor odpovídá regulárnímu výrazu ``asimov``, např. `Asimov, Isaac` nebo `Isaac Asimov`, jinak ``''``."
940
941 #: ../../../__w/calibre/calibre/manual/template_lang.rst:457
942 msgid ""
943 "``program: 'asimov' inlist_field 'authors'`` returns ``'1'`` if any author "
944 "matches the regular expression ``asimov``, e.g., `Asimov, Isaac` or `Isaac "
945 "Asimov`, otherwise ``''``."
946 msgstr "``program: 'asimov' inlist_field 'authors'`` vrátí ``'1'``, pokud některý autor odpovídá regulárnímu výrazu ``asimov``, např. `Asimov, Isaac` nebo `Isaac Asimov`, jinak ``''``."
947
948 #: ../../../__w/calibre/calibre/manual/template_lang.rst:458
949 msgid ""
950 "``program: 'asimov$' inlist_field 'authors'`` returns ``'1'`` if any author "
951 "matches the regular expression ``asimov$``, e.g., `Isaac Asimov`, otherwise "
952 "``''``. It doesn't match `Asimov, Isaac` because of the ``$`` anchor in the "
953 "regular expression."
954 msgstr "``program: 'asimov$' inlist_field 'authors'`` vrátí ``'1'``, pokud některý autor odpovídá regulárnímu výrazu ``asimov$``, např. `Isaac Asimov`, jinak ``''``. Hodnota `Asimov, Isaac` neodpovídá kvůli kotvě ``$`` v regulárním výrazu."
955
956 #: ../../../__w/calibre/calibre/manual/template_lang.rst:459
957 msgid ""
958 "``program: if field('series') != 'foo' then 'bar' else 'mumble' fi`` returns"
959 " ``'bar'`` if the book's series is not `foo`. Otherwise it returns "
960 "``'mumble'``."
961 msgstr "``program: if field('series') != 'foo' then 'bar' else 'mumble' fi`` vrátí ``'bar'``, pokud série knihy není `foo`. Jinak vrátí ``'mumble'``."
962
963 #: ../../../__w/calibre/calibre/manual/template_lang.rst:460
964 msgid ""
965 "``program: if field('series') == 'foo' || field('series') == '1632' then "
966 "'yes' else 'no' fi`` returns ``'yes'`` if series is either `foo` or `1632`, "
967 "otherwise ``'no'``."
968 msgstr "``program: if field('series') == 'foo' || field('series') == '1632' then 'yes' else 'no' fi`` vrátí ``'yes'``, pokud je série buď `foo`, nebo `1632`, jinak ``'no'``."
969
970 #: ../../../__w/calibre/calibre/manual/template_lang.rst:461
971 msgid ""
972 "``program: if '^(foo|1632)$' in field('series') then 'yes' else 'no' fi`` "
973 "returns ``'yes'`` if series is either `foo` or `1632`, otherwise ``'no'``."
974 msgstr "``program: if '^(foo|1632)$' in field('series') then 'yes' else 'no' fi`` vrátí ``'yes'``, pokud je série buď `foo`, nebo `1632`, jinak ``'no'``."
975
976 #: ../../../__w/calibre/calibre/manual/template_lang.rst:462
977 msgid ""
978 "``program: if 11 > 2 then 'yes' else 'no' fi`` returns ``'no'`` because the "
979 "``>`` operator does a lexical comparison."
980 msgstr "``program: if 11 > 2 then 'yes' else 'no' fi`` vrátí ``'no'``, protože operátor ``>`` provádí lexikální porovnání."
981
982 #: ../../../__w/calibre/calibre/manual/template_lang.rst:463
983 msgid ""
984 "``program: if 11 ># 2 then 'yes' else 'no' fi`` returns ``'yes'`` because "
985 "the ``>#`` operator does a numeric comparison."
986 msgstr "``program: if 11 ># 2 then 'yes' else 'no' fi`` vrátí ``'yes'``, protože operátor ``>#`` provádí číselné porovnání."
987
988 #: ../../../__w/calibre/calibre/manual/template_lang.rst:465
989 msgid "**Functions in General Program Mode**"
990 msgstr "**Funkce v obecném režimu programu**"
991
992 #: ../../../__w/calibre/calibre/manual/template_lang.rst:467
993 msgid ""
994 "See :ref:`template_functions_reference` for the list of functions built into"
995 " the template language."
996 msgstr "Seznam funkcí zabudovaných do jazyka šablon najdete v sekci :ref:`template_functions_reference`."
997
998 #: ../../../__w/calibre/calibre/manual/template_lang.rst:471
999 msgid ""
1000 "As opposed to :ref:`Single Function Mode <single_mode>`, in General Program "
1001 "Mode you must specify the first parameter ``value``."
1002 msgstr "Na rozdíl od :ref:`režimu jedné funkce <single_mode>` musíte v obecném režimu programu zadat první parametr ``value``."
1003
1004 #: ../../../__w/calibre/calibre/manual/template_lang.rst:472
1005 msgid "All parameters are expression_lists (see the grammar above)."
1006 msgstr "Všechny parametry jsou seznamy výrazů (``expression_lists``; viz gramatika výše)."
1007
1008 #: ../../../__w/calibre/calibre/manual/template_lang.rst:477
1009 msgid "More complex programs in template expressions - Template Program Mode"
1010 msgstr "Složitější programy ve výrazech šablony - Režim programu šablony"
1011
1012 #: ../../../__w/calibre/calibre/manual/template_lang.rst:479
1013 msgid ""
1014 "`Template Program Mode` (`TPM`) is a blend of :ref:`General Program Mode "
1015 "<general_mode>` and :ref:`Single Function Mode <single_mode>`. `TPM` differs"
1016 " from Single Function Mode in that it permits writing template expressions "
1017 "that refer to other metadata fields, use nested functions, modify variables,"
1018 " and do arithmetic. It differs from `General Program Mode` in that the "
1019 "template is contained between ``{`` and ``}`` characters and doesn't begin "
1020 "with the word ``program:``. The program portion of the template is a General"
1021 " Program Mode expression list."
1022 msgstr "`Režim programu šablony` (`TPM`) je kombinací :ref:`obecného režimu programu <general_mode>` a :ref:`režimu jedné funkce <single_mode>`. `TPM` se od režimu jedné funkce liší tím, že umožňuje psát výrazy šablony, které odkazují na jiná pole metadat, používají vnořené funkce, mění proměnné a provádějí aritmetiku. Od `obecného režimu programu` se liší tím, že šablona je uzavřena mezi znaky ``{`` a ``}`` a nezačíná slovem ``program:``. Programová část šablony je seznam výrazů obecného režimu programu."
1023
1024 #: ../../../__w/calibre/calibre/manual/template_lang.rst:482
1025 msgid ""
1026 "Example: assume you want a template to show the series for a book if it has "
1027 "one, otherwise show the value of a custom field #genre. You cannot do this "
1028 "in the :ref:`Single Function Mode <single_mode>` because you cannot make "
1029 "reference to another metadata field within a template expression. In `TPM` "
1030 "you can, as the following expression demonstrates::"
1031 msgstr "Příklad: předpokládejme, že chcete, aby šablona zobrazila sérii knihy, pokud ji kniha má, jinak aby zobrazila hodnotu vlastního pole ``#genre``. V :ref:`režimu jedné funkce <single_mode>` to nemůžete udělat, protože ve výrazu šablony nelze odkazovat na jiné pole metadat. V `TPM` to možné je, jak ukazuje následující výraz::"
1032
1033 #: ../../../__w/calibre/calibre/manual/template_lang.rst:487
1034 msgid "The example shows several things:"
1035 msgstr "Příklad ukazuje několik věcí:"
1036
1037 #: ../../../__w/calibre/calibre/manual/template_lang.rst:489
1038 msgid ""
1039 "`TPM` is used if the expression begins with ``:'`` and ends with ``'}``. "
1040 "Anything else is assumed to be in :ref:`Single Function Mode <single_mode>`."
1041 msgstr "`TPM` se použije, pokud výraz začíná ``:'`` a končí ``'}``. U všeho ostatního se předpokládá, že jde o :ref:`režim jedné funkce <single_mode>`."
1042
1043 #: ../../../__w/calibre/calibre/manual/template_lang.rst:491
1044 msgid ""
1045 "If the template contains a prefix and suffix, the expression ends with "
1046 "``'|`` where the ``|`` is the delimiter for the prefix. Example::"
1047 msgstr "Pokud šablona obsahuje předponu a příponu, výraz končí ``'|``, kde ``|`` je oddělovač předpony. Příklad::"
1048
1049 #: ../../../__w/calibre/calibre/manual/template_lang.rst:495
1050 msgid ""
1051 "Functions must be given all their arguments. For example, the standard "
1052 "built-in functions must be given the initial parameter ``value``."
1053 msgstr "Funkcím musí být předány všechny jejich argumenty. Například standardním vestavěným funkcím musí být předán první parametr ``value``."
1054
1055 #: ../../../__w/calibre/calibre/manual/template_lang.rst:496
1056 msgid ""
1057 "The variable ``$`` is usable as the ``value`` argument and stands for the "
1058 "value of the field named in the template, ``series`` in this case."
1059 msgstr "Proměnnou ``$`` lze použít jako argument ``value`` a představuje hodnotu pole pojmenovaného v šabloně, v tomto případě ``series``."
1060
1061 #: ../../../__w/calibre/calibre/manual/template_lang.rst:497
1062 msgid "white space is ignored and can be used anywhere within the expression."
1063 msgstr "bílé znaky jsou ignorovány a lze je použít kdekoli uvnitř výrazu."
1064
1065 #: ../../../__w/calibre/calibre/manual/template_lang.rst:498
1066 msgid ""
1067 "constant strings are enclosed in matching quotes, either ``'`` or ``\"``."
1068 msgstr "konstantní řetězce se uzavírají do párových uvozovek, buď ``'``, nebo ``\"``."
1069
1070 #: ../../../__w/calibre/calibre/manual/template_lang.rst:500
1071 msgid ""
1072 "In `TPM`, using ``{`` and ``}`` characters in string literals can lead to "
1073 "errors or unexpected results because they confuse the template processor. It"
1074 " tries to treat them as template expression boundaries, not characters. In "
1075 "some but not all cases you can replace a ``{`` with ``[[`` and a ``}`` with "
1076 "`]]`. Advice: if your program contains ``{`` and ``}`` characters then you "
1077 "should use `General Program Mode`."
1078 msgstr "V `TPM` může použití znaků ``{`` a ``}`` v řetězcových literálech vést k chybám nebo neočekávaným výsledkům, protože matou zpracovatele šablon. Ten se je pokouší vykládat jako hranice výrazů šablony, ne jako samotné znaky. V některých případech, ale ne ve všech, můžete ``{`` nahradit ``[[`` a ``}`` nahradit `]]`. Doporučení: pokud váš program obsahuje znaky ``{`` a ``}``, měli byste použít `obecný režim programu`."
1079
1080 #: ../../../__w/calibre/calibre/manual/template_lang.rst:505
1081 msgid "Python Template Mode"
1082 msgstr "Režim pythonové šablony"
1083
1084 #: ../../../__w/calibre/calibre/manual/template_lang.rst:507
1085 msgid ""
1086 "Python Template Mode (PTM) lets you write templates using native Python and "
1087 "the `calibre API <https://manual.calibre-ebook.com/develop.html#api-"
1088 "documentation-for-various-parts-of-calibre>`_. The database API will be of "
1089 "most use; further discussion is beyond the scope of this manual. PTM "
1090 "templates are faster and can do more complicated operations but you must "
1091 "know how to write code in Python using the calibre API."
1092 msgstr "Režim pythonové šablony (PTM) umožňuje psát šablony pomocí nativního Pythonu a `API calibre <https://manual.calibre-ebook.com/develop.html#api-documentation-for-various-parts-of-calibre>`_. Nejvíce se uplatní databázové API; další výklad je mimo rozsah této příručky. Šablony PTM jsou rychlejší a zvládnou složitější operace, ale musíte umět psát kód v Pythonu s využitím API calibre."
1093
1094 #: ../../../__w/calibre/calibre/manual/template_lang.rst:509
1095 msgid "A PTM template begins with:"
1096 msgstr "Šablona PTM začíná takto:"
1097
1098 #: ../../../__w/calibre/calibre/manual/template_lang.rst:527
1099 msgid ""
1100 "You can add the above text to your template using the context menu, usually "
1101 "accessed with a right click. The comments are not significant and can be "
1102 "removed. You must use python indenting."
1103 msgstr "Výše uvedený text můžete do šablony přidat pomocí místní nabídky, která se obvykle otevře kliknutím pravým tlačítkem myši. Komentáře nejsou pro funkci šablony podstatné a lze je odstranit. Musíte používat odsazení podle pravidel Pythonu."
1104
1105 #: ../../../__w/calibre/calibre/manual/template_lang.rst:529
1106 msgid ""
1107 "The context object supports ``str(context)`` that returns a string of the "
1108 "context's contents, and ``context.attributes`` that returns a list of the "
1109 "attribute names in the context."
1110 msgstr "Objekt ``context`` podporuje volání ``str(context)``, které vrací řetězec s obsahem objektu ``context``, a vlastnost ``context.attributes``, která vrací seznam názvů atributů v objektu ``context``."
1111
1112 #: ../../../__w/calibre/calibre/manual/template_lang.rst:531
1113 msgid ""
1114 "The ``context.funcs`` attribute allows calling Built-in and User template "
1115 "functions, and Stored GPM/Python templates, so that you can execute them "
1116 "directly in your code. The functions are retrieved using their names. If the"
1117 " name conflicts with a Python keyword, add an underscore to the end of the "
1118 "name. Examples:"
1119 msgstr "Atribut ``context.funcs`` umožňuje volat vestavěné a uživatelské funkce šablon a uložené šablony GPM/Python, takže je můžete spouštět přímo ve svém kódu. Funkce se získávají podle svého názvu. Pokud je název v konfliktu s klíčovým slovem Pythonu, přidejte na konec názvu podtržítko. Příklady:"
1120
1121 #: ../../../__w/calibre/calibre/manual/template_lang.rst:538
1122 msgid ""
1123 "Here is an example of a PTM template that produces a list of all the authors"
1124 " for a series. The list is stored in a `Column built from other columns, "
1125 "behaves like tags`. It shows in :guilabel:`Book details` and has the "
1126 ":guilabel:`on separate lines` checked (in :guilabel:`Preferences->Look & "
1127 "feel->Book details`). That option requires the list to be comma-separated. "
1128 "To satisfy that requirement the template converts commas in author names to "
1129 "semicolons then builds a comma-separated list of authors. The authors are "
1130 "then sorted, which is why the template uses author_sort."
1131 msgstr "Zde je příklad šablony PTM, která vytvoří seznam všech autorů pro danou sérii. Seznam je uložen ve sloupci `Sloupec sestavený z jiných sloupců, chová se jako štítky`. Tento sloupec se zobrazuje v :guilabel:`Podrobnosti o knize` a má zaškrtnutou volbu :guilabel:`na oddělených řádcích` (v :guilabel:`Předvolby->Vzhled a chování->Podrobnosti o knize`). Tato volba vyžaduje, aby byl seznam oddělený čárkami. Aby šablona tento požadavek splnila, převádí čárky ve jménech autorů na středníky a potom vytvoří seznam autorů oddělený čárkami. Autoři se potom seřadí, proto šablona používá ``author_sort``."
1132
1133 #: ../../../__w/calibre/calibre/manual/template_lang.rst:559
1134 msgid "The output in :guilabel:`Book details` looks like this:"
1135 msgstr "Výstup v :guilabel:`Podrobnosti o knize` vypadá takto:"
1136
1137 #: ../../../__w/calibre/calibre/manual/template_lang.rst:561
1138 msgid "E-book conversion dialog"
1139 msgstr "Dialogové okno převodu e-knihy"
1140
1141 #: ../../../__w/calibre/calibre/manual/template_lang.rst:569
1142 msgid "Templates and URLs"
1143 msgstr "Šablony a URL"
1144
1145 #: ../../../__w/calibre/calibre/manual/template_lang.rst:571
1146 msgid "You can use templates to construct URLs. Two cases are described here:"
1147 msgstr "Šablony můžete použít k sestavování adres URL. Zde jsou popsány dva případy:"
1148
1149 #: ../../../__w/calibre/calibre/manual/template_lang.rst:573
1150 msgid "Custom column :guilabel:`Book details` search URLs"
1151 msgstr "Vyhledávací URL vlastního sloupce v :guilabel:`Podrobnosti o knize`"
1152
1153 #: ../../../__w/calibre/calibre/manual/template_lang.rst:574
1154 msgid "The calibre URL scheme"
1155 msgstr "Schéma URL calibre"
1156
1157 #: ../../../__w/calibre/calibre/manual/template_lang.rst:576
1158 msgid "**Custom column book details search URLs**"
1159 msgstr "**Vyhledávací URL vlastního sloupce v Podrobnostech o knize**"
1160
1161 #: ../../../__w/calibre/calibre/manual/template_lang.rst:578
1162 msgid ""
1163 "When you create a custom column you can provide a URL to be used in "
1164 ":guilabel:`Book details` using a template. For example, if you have a custom"
1165 " column for `Translators` you can define a URL to take you to a site for "
1166 "translators. Book details search URLs can be provided for `Text`, "
1167 "`Enumerated`, `Series`, and `Column built from other column` column types."
1168 msgstr "Při vytváření vlastního sloupce můžete pomocí šablony zadat adresu URL, která se použije v :guilabel:`Podrobnosti o knize`. Pokud máte například vlastní sloupec `Překladatelé`, můžete definovat adresu URL, která otevře web pro překladatele. Vyhledávací URL v Podrobnostech o knize lze zadat pro typy sloupců `Text`, `Text s pevnou sadou povolených hodnot`, `Série` a `Sloupec sestavený z jiných sloupců`."
1169
1170 #: ../../../__w/calibre/calibre/manual/template_lang.rst:580
1171 msgid ""
1172 "When an item with a `search template` is clicked in :guilabel:`Book details`"
1173 " the template is evaluated. It is provided the normal book metadata. It is "
1174 "also provided three additional fields:"
1175 msgstr "Když v :guilabel:`Podrobnosti o knize` kliknete na položku s `vyhledávací šablonou`, šablona se vyhodnotí. Šabloně se předají běžná metadata knihy a také tři další pole:"
1176
1177 #: ../../../__w/calibre/calibre/manual/template_lang.rst:582
1178 msgid "``item_value``: the value of the clicked item."
1179 msgstr "``item_value``: hodnota položky, na kterou bylo kliknuto."
1180
1181 #: ../../../__w/calibre/calibre/manual/template_lang.rst:583
1182 msgid ""
1183 "``item_value_quoted``: the value of clicked item, URL-encoded. Special "
1184 "characters are escaped to make them valid in URLs and spaces are replaced by"
1185 " ``'+'`` (plus) signs."
1186 msgstr "``item_value_quoted``: hodnota položky, na kterou bylo kliknuto, zakódovaná pro URL. Speciální znaky jsou zakódovány tak, aby byly v URL platné, a mezery jsou nahrazeny znaky ``'+'`` (znaménko plus)."
1187
1188 #: ../../../__w/calibre/calibre/manual/template_lang.rst:584
1189 msgid ""
1190 "``item_value_no_plus``: the value of clicked item, URL-encoded. Special "
1191 "characters are escaped to make them valid in URLs and spaces are replaced by"
1192 " the ``%20``, not plus."
1193 msgstr "``item_value_no_plus``: hodnota položky, na kterou bylo kliknuto, zakódovaná pro URL. Speciální znaky jsou zakódovány tak, aby byly v URL platné, a mezery jsou nahrazeny hodnotou ``%20``, nikoli znaménkem plus."
1194
1195 #: ../../../__w/calibre/calibre/manual/template_lang.rst:586
1196 msgid ""
1197 "There are several ways to construct the URL. The following use Wikipedia as "
1198 "an example."
1199 msgstr "URL lze sestavit několika způsoby. Následující příklady používají Wikipedii."
1200
1201 #: ../../../__w/calibre/calibre/manual/template_lang.rst:588
1202 msgid "The simplest is a basic template::"
1203 msgstr "Nejjednodušší je základní šablona::"
1204
1205 #: ../../../__w/calibre/calibre/manual/template_lang.rst:592
1206 msgid ""
1207 "In some cases you might want to do more processing. There are four template "
1208 "functions you can use, depending on the complexity of the processing."
1209 msgstr "V některých případech můžete chtít provést další zpracování. Podle složitosti zpracování můžete použít čtyři funkce šablon."
1210
1211 #: ../../../__w/calibre/calibre/manual/template_lang.rst:599
1212 msgid ""
1213 "For example, assume you have a custom column `Translators` "
1214 "(``#translators``) where the names are `Last name, First name`. You might "
1215 "need to convert the name to `First name Last name` when creating the URL. "
1216 "You can use the :ref:`ff_make_url` function to do this::"
1217 msgstr "Předpokládejme například, že máte vlastní sloupec `Překladatelé` (``#translators``), ve kterém jsou jména ve tvaru `Příjmení, jméno`. Při vytváření URL možná budete potřebovat převést jméno do tvaru `Jméno Příjmení`. K tomu můžete použít funkci :ref:`ff_make_url`::"
1218
1219 #: ../../../__w/calibre/calibre/manual/template_lang.rst:603
1220 msgid ""
1221 "If we assume that the translator's name is `Boy-Żeleński, Tadeusz` then the "
1222 "above template produces the link::"
1223 msgstr "Pokud předpokládáme, že jméno překladatele je `Boy-Żeleński, Tadeusz`, pak výše uvedená šablona vytvoří odkaz::"
1224
1225 #: ../../../__w/calibre/calibre/manual/template_lang.rst:607
1226 msgid ""
1227 "Note that the person's first name is now first, the space is now a plus, and"
1228 " that the non-English characters in the last name are URL-encoded."
1229 msgstr "Všimněte si, že křestní jméno osoby je nyní na prvním místě, mezera je nyní znaménkem plus a znaky mimo angličtinu v příjmení jsou zakódované pro URL."
1230
1231 #: ../../../__w/calibre/calibre/manual/template_lang.rst:609
1232 msgid ""
1233 "The functions :ref:`ff_make_url_extended`, :ref:`ff_query_string`, and "
1234 ":ref:`ff_encode_for_url` might be useful depending upon any additional "
1235 "processing complexity."
1236 msgstr "Funkce :ref:`ff_make_url_extended`, :ref:`ff_query_string` a :ref:`ff_encode_for_url` mohou být užitečné podle toho, jak složité další zpracování potřebujete."
1237
1238 #: ../../../__w/calibre/calibre/manual/template_lang.rst:611
1239 msgid "**The calibre URL scheme**"
1240 msgstr "**Schéma URL calibre**"
1241
1242 #: ../../../__w/calibre/calibre/manual/template_lang.rst:613
1243 msgid ""
1244 "Calibre supports several different URLs to navigate your calibre libraries. "
1245 "This section shows how to use templates to construct some of the URLs. See "
1246 ":doc:`url_scheme` for details on the URLs available."
1247 msgstr "Calibre podporuje několik různých adres URL pro navigaci v knihovnách calibre. Tato část ukazuje, jak pomocí šablon sestavit některé z těchto adres URL. Podrobnosti o dostupných adresách URL najdete v :doc:`url_scheme`."
1248
1249 #: ../../../__w/calibre/calibre/manual/template_lang.rst:616
1250 msgid "Switch to a specific library. The syntax of this URL is::"
1251 msgstr "Přepnutí na konkrétní knihovnu. Syntaxe této URL je::"
1252
1253 #: ../../../__w/calibre/calibre/manual/template_lang.rst:620
1254 msgid ""
1255 "``Library_Name`` must be replaced with the name of the calibre library you "
1256 "wish to open. The library name is shown in the title bar of the window. It "
1257 "is a simple name, not the file path to the library. You must spell it as "
1258 "shown in the title bar, including letter case. The character ``_`` "
1259 "(underscore) stands for the current library. If the name contains any spaces"
1260 " or special characters then it must be hex encoded using the "
1261 ":ref:`ff_to_hex` function, as in the following example::"
1262 msgstr "``Library_Name`` je třeba nahradit názvem knihovny calibre, kterou chcete otevřít. Název knihovny je zobrazen v záhlaví okna. Jde o jednoduchý název, nikoli o cestu ke knihovně. Musíte ho zapsat tak, jak je zobrazen v záhlaví okna, včetně velikosti písmen. Znak ``_`` (podtržítko) označuje aktuální knihovnu. Pokud název obsahuje mezery nebo speciální znaky, musí být hexadecimálně zakódován pomocí funkce :ref:`ff_to_hex`, jako v následujícím příkladu::"
1263
1264 #: ../../../__w/calibre/calibre/manual/template_lang.rst:628
1265 msgid "The template generates the URL::"
1266 msgstr "Šablona vygeneruje URL::"
1267
1268 #: ../../../__w/calibre/calibre/manual/template_lang.rst:632
1269 msgid ""
1270 "You can replace the ``current_library_name()`` function with the actual name"
1271 " of the library, as in::"
1272 msgstr "Funkci ``current_library_name()`` můžete nahradit skutečným názvem knihovny, například::"
1273
1274 #: ../../../__w/calibre/calibre/manual/template_lang.rst:636
1275 msgid ""
1276 "Links to show books. These links select a book in the calibre library. The "
1277 "syntax for this URL is::"
1278 msgstr "Odkazy pro zobrazení knih. Tyto odkazy vyberou knihu v knihovně calibre. Syntaxe této URL je::"
1279
1280 #: ../../../__w/calibre/calibre/manual/template_lang.rst:640
1281 msgid ""
1282 "The ``book id`` is the numeric calibre id for the book, available to "
1283 "templates as ``$id``. As above, the library name might need to be hex "
1284 "encoded. Here is an example::"
1285 msgstr "``book id`` je číselné ID knihy v calibre, dostupné šablonám jako ``$id``. Stejně jako výše může být nutné název knihovny hexadecimálně zakódovat. Zde je příklad::"
1286
1287 #: ../../../__w/calibre/calibre/manual/template_lang.rst:645
1288 msgid "It produces the URL::"
1289 msgstr "Vytvoří URL::"
1290
1291 #: ../../../__w/calibre/calibre/manual/template_lang.rst:649
1292 msgid ""
1293 "Searching for books. These links search for books in the specified calibre "
1294 "library. The syntax for this URL is::"
1295 msgstr "Vyhledávání knih. Tyto odkazy vyhledají knihy v zadané knihovně calibre. Syntaxe této URL je::"
1296
1297 #: ../../../__w/calibre/calibre/manual/template_lang.rst:654
1298 msgid ""
1299 "where `query` is any valid calibre search expression. You must hex encode "
1300 "any query containing spaces or special characters, which generally means all"
1301 " of them. For example, the calibre search expression for searching for a "
1302 "hierarchical tag beginning with 'AA' is ``tags:\"=.AA\"``. This template "
1303 "constructs a search URL for that expression::"
1304 msgstr "kde `query` je libovolný platný vyhledávací výraz calibre. Každý dotaz obsahující mezery nebo speciální znaky musíte hexadecimálně zakódovat, což obecně znamená všechny dotazy. Například vyhledávací výraz calibre pro hledání hierarchického štítku začínajícího na 'AA' je ``tags:\"=.AA\"``. Tato šablona sestaví vyhledávací URL pro tento výraz::"
1305
1306 #: ../../../__w/calibre/calibre/manual/template_lang.rst:660
1307 msgid "The resulting URL is::"
1308 msgstr "Výsledná URL je::"
1309
1310 #: ../../../__w/calibre/calibre/manual/template_lang.rst:664
1311 msgid ""
1312 "Here is an example of the same URL built using the "
1313 ":ref:``ff_make_url_extended`` function instead of :ref:`ff_strcat`::"
1314 msgstr "Zde je příklad stejné URL sestavené pomocí funkce :ref:`ff_make_url_extended` místo :ref:`ff_strcat`::"
1315
1316 #: ../../../__w/calibre/calibre/manual/template_lang.rst:669
1317 msgid ""
1318 "Open a book details window on a book in some library. The syntax for this "
1319 "URL is::"
1320 msgstr "Otevření okna Podrobnosti o knize pro knihu v některé knihovně. Syntaxe této URL je::"
1321
1322 #: ../../../__w/calibre/calibre/manual/template_lang.rst:673
1323 msgid "An example template is::"
1324 msgstr "Ukázková šablona je::"
1325
1326 #: ../../../__w/calibre/calibre/manual/template_lang.rst:677
1327 #: ../../../__w/calibre/calibre/manual/template_lang.rst:694
1328 msgid "which produces the URL::"
1329 msgstr "která vytvoří URL::"
1330
1331 #: ../../../__w/calibre/calibre/manual/template_lang.rst:681
1332 msgid ""
1333 "Open the notes associated with an author/series/etc. The syntax of the URL "
1334 "is::"
1335 msgstr "Otevření poznámek přidružených k autorovi, sérii atd. Syntaxe URL je::"
1336
1337 #: ../../../__w/calibre/calibre/manual/template_lang.rst:686
1338 msgid ""
1339 "``Field_Name`` is the lookup name of the field. If the field is a custom "
1340 "column then replace the ``#`` character with an underscore (``_``). "
1341 "``Item_Id`` is the internal numeric ID of the value in the field. There "
1342 "isn't a template function that returns the ``Item_Id``, so templates will "
1343 "normally use the second form, ``Hex_Encoded_Item_Name``. Here is a sample "
1344 "template that opens the note for the person ``Boy-Żeleński, Tadeusz`` in the"
1345 " field ``#authtest``::"
1346 msgstr "``Field_Name`` je název vyhledávání daného pole. Pokud je pole vlastním sloupcem, nahraďte znak ``#`` podtržítkem (``_``). ``Item_Id`` je interní číselné ID hodnoty v poli. Neexistuje funkce šablony, která by vracela ``Item_Id``, takže šablony obvykle použijí druhou podobu, ``Hex_Encoded_Item_Name``. Zde je ukázková šablona, která otevře poznámku pro osobu ``Boy-Żeleński, Tadeusz`` v poli ``#authtest``::"
1347
1348 #: ../../../__w/calibre/calibre/manual/template_lang.rst:700
1349 msgid "Stored templates"
1350 msgstr "Uložené šablony"
1351
1352 #: ../../../__w/calibre/calibre/manual/template_lang.rst:702
1353 msgid ""
1354 "Both :ref:`General Program Mode <general_mode>` and :ref:`Python Template "
1355 "Mode <python_mode>` support saving templates and calling those templates "
1356 "from another template, much like calling stored functions. You save "
1357 "templates using :guilabel:`Preferences->Advanced->Template functions`. More "
1358 "information is provided in that dialog. You call a template the same way you"
1359 " call a function, passing positional arguments if desired. An argument can "
1360 "be any expression. Examples of calling a template, assuming the stored "
1361 "template is named ``foo``:"
1362 msgstr "Jak :ref:`obecný režim programu <general_mode>`, tak :ref:`režim pythonové šablony <python_mode>` podporují ukládání šablon a volání těchto šablon z jiné šablony, podobně jako při volání uložených funkcí. Šablony ukládáte pomocí :guilabel:`Předvolby->Rozšířené->Funkce šablony`. Další informace jsou uvedeny v tomto dialogu. Šablonu voláte stejně jako funkci a podle potřeby jí předáváte poziční argumenty. Argumentem může být libovolný výraz. Příklady volání šablony za předpokladu, že uložená šablona se jmenuje ``foo``:"
1363
1364 #: ../../../__w/calibre/calibre/manual/template_lang.rst:704
1365 msgid "``foo()`` -- call the template passing no arguments."
1366 msgstr "``foo()`` -- zavolá šablonu bez předání argumentů."
1367
1368 #: ../../../__w/calibre/calibre/manual/template_lang.rst:705
1369 msgid ""
1370 "``foo(a, b)`` call the template passing the values of the two variables "
1371 "``a`` and ``b``."
1372 msgstr "``foo(a, b)`` zavolá šablonu a předá jí hodnoty dvou proměnných ``a`` a ``b``."
1373
1374 #: ../../../__w/calibre/calibre/manual/template_lang.rst:706
1375 msgid ""
1376 "``foo(if field('series') then field('series_index') else 0 fi)`` -- if the "
1377 "book has a ``series`` then pass the ``series_index``, otherwise pass the "
1378 "value ``0``."
1379 msgstr "``foo(if field('series') then field('series_index') else 0 fi)`` -- pokud má kniha hodnotu v poli ``series``, předá se ``series_index``, jinak se předá hodnota ``0``."
1380
1381 #: ../../../__w/calibre/calibre/manual/template_lang.rst:708
1382 msgid ""
1383 "In GPM you retrieve the arguments passed in the call to the stored template "
1384 "using the ``arguments`` function. It both declares and initializes local "
1385 "variables, effectively parameters. The variables are positional; they get "
1386 "the value of the parameter given in the call in the same position. If the "
1387 "corresponding parameter is not provided in the call then ``arguments`` "
1388 "assigns that variable the provided default value. If there is no default "
1389 "value then the variable is set to the empty string. For example, the "
1390 "following ``arguments`` function declares 2 variables, ``key``, "
1391 "``alternate``::"
1392 msgstr "V GPM načtete argumenty předané při volání uložené šablony pomocí funkce ``arguments``. Ta zároveň deklaruje a inicializuje lokální proměnné, fakticky tedy parametry. Proměnné jsou poziční; získají hodnotu argumentu zadaného ve volání na stejné pozici. Pokud odpovídající argument ve volání zadán není, funkce ``arguments`` přiřadí této proměnné zadanou výchozí hodnotu. Pokud výchozí hodnota neexistuje, proměnná se nastaví na prázdný řetězec. Například následující funkce ``arguments`` deklaruje dvě proměnné, ``key`` a ``alternate``::"
1393
1394 #: ../../../__w/calibre/calibre/manual/template_lang.rst:712
1395 msgid "Examples, again assuming the stored template is named ``foo``:"
1396 msgstr "Příklady, opět za předpokladu, že uložená šablona se jmenuje ``foo``:"
1397
1398 #: ../../../__w/calibre/calibre/manual/template_lang.rst:714
1399 msgid ""
1400 "``foo('#myseries')`` -- argument ``key`` is assigned the value "
1401 "``'myseries'`` and the argument ``alternate`` is assigned the default value "
1402 "``'series'``."
1403 msgstr "``foo('#myseries')`` -- proměnné ``key`` se přiřadí hodnota ``'#myseries'`` a proměnné ``alternate`` výchozí hodnota ``'series'``."
1404
1405 #: ../../../__w/calibre/calibre/manual/template_lang.rst:715
1406 msgid ""
1407 "``foo('series', '#genre')`` the variable ``key`` is assigned the value "
1408 "``'series'`` and the variable ``alternate`` is assigned the value "
1409 "``'#genre'``."
1410 msgstr "``foo('series', '#genre')`` proměnné ``key`` se přiřadí hodnota ``'series'`` a proměnné ``alternate`` hodnota ``'#genre'``."
1411
1412 #: ../../../__w/calibre/calibre/manual/template_lang.rst:716
1413 msgid ""
1414 "``foo()`` -- the variable ``key`` is assigned the empty string and the "
1415 "variable ``alternate`` is assigned the value ``'series'``."
1416 msgstr "``foo()`` -- proměnné ``key`` se přiřadí prázdný řetězec a proměnné ``alternate`` hodnota ``'series'``."
1417
1418 #: ../../../__w/calibre/calibre/manual/template_lang.rst:718
1419 msgid ""
1420 "In PTM the arguments are passed in the ``arguments`` parameter, which is a "
1421 "list of strings. There isn't any way to specify default values. You must "
1422 "check the length of the ``arguments`` list to be sure that the number of "
1423 "arguments is what you expect."
1424 msgstr "V PTM se argumenty předávají v atributu ``arguments``, což je seznam řetězců. Výchozí hodnoty nelze nijak zadat. Musíte zkontrolovat délku seznamu ``arguments``, abyste měli jistotu, že počet argumentů odpovídá tomu, co očekáváte."
1425
1426 #: ../../../__w/calibre/calibre/manual/template_lang.rst:720
1427 msgid ""
1428 "An easy way to test stored templates is using the ``Template tester`` "
1429 "dialog. For ease of access give it a keyboard shortcut in "
1430 ":guilabel:`Preferences->Advanced->Keyboard shortcuts->Template tester`. "
1431 "Giving the ``Stored templates`` dialog a shortcut will help switching more "
1432 "rapidly between the tester and editing the stored template's source code."
1433 msgstr "Uložené šablony lze snadno testovat pomocí dialogu ``Testovač šablon``. Pro snadný přístup mu přiřaďte klávesovou zkratku v :guilabel:`Předvolby->Rozšířené->Klávesové zkratky->Testovač šablon`. Přiřazení zkratky dialogu ``Uložené šablony`` vám pomůže rychleji přepínat mezi testovačem a úpravami zdrojového kódu uložené šablony."
1434
1435 #: ../../../__w/calibre/calibre/manual/template_lang.rst:723
1436 msgid "Providing additional information to templates"
1437 msgstr "Předávání dodatečných informací šablonám"
1438
1439 #: ../../../__w/calibre/calibre/manual/template_lang.rst:725
1440 msgid ""
1441 "A developer can choose to pass additional information to the template "
1442 "processor, such as application-specific book metadata or information about "
1443 "what the processor is being asked to do. A template can access this "
1444 "information and use it during the evaluation."
1445 msgstr "Vývojář může zpracovateli šablon předat dodatečné informace, například metadata knih specifická pro aplikaci nebo informace o tom, co je po zpracovateli požadováno. Šablona k těmto informacím může přistupovat a použít je během vyhodnocování."
1446
1447 #: ../../../__w/calibre/calibre/manual/template_lang.rst:727
1448 msgid "**Developer: how to pass additional information**"
1449 msgstr "**Vývojář: jak předat dodatečné informace**"
1450
1451 #: ../../../__w/calibre/calibre/manual/template_lang.rst:729
1452 msgid ""
1453 "The additional information is a Python dictionary containing pairs "
1454 "``variable_name: variable_value`` where the values must be strings. The "
1455 "template can access the dictionary, creating template local variables named "
1456 "``variable_name`` containing the value ``variable_value``. The user cannot "
1457 "change the name so it is best to use names that won't collide with other "
1458 "template local variables, for example by prefixing the name with an "
1459 "underscore."
1460 msgstr "Dodatečné informace jsou slovník Pythonu obsahující dvojice ``variable_name: variable_value``, kde hodnoty musí být řetězce. Šablona může ke slovníku přistupovat tak, že vytvoří lokální proměnné šablony s názvem ``variable_name`` obsahující hodnotu ``variable_value``. Uživatel název nemůže změnit, proto je nejlepší použít názvy, které nebudou kolidovat s jinými lokálními proměnnými šablony, například přidáním podtržítka na začátek názvu."
1461
1462 #: ../../../__w/calibre/calibre/manual/template_lang.rst:731
1463 msgid ""
1464 "This dictionary is passed to the template processor (the ``formatter``) "
1465 "using the named parameter ``global_vars=your_dict``. The full method "
1466 "signature is::"
1467 msgstr "Tento slovník se předává zpracovateli šablon (``formatter``) pomocí pojmenovaného parametru ``global_vars=your_dict``. Úplná signatura metody je::"
1468
1469 #: ../../../__w/calibre/calibre/manual/template_lang.rst:739
1470 msgid "**Template writer: how to access the additional information**"
1471 msgstr "**Autor šablony: jak přistupovat k dodatečným informacím**"
1472
1473 #: ../../../__w/calibre/calibre/manual/template_lang.rst:741
1474 msgid ""
1475 "You access the additional information (the ``globals`` dictionary) in a "
1476 "template using the template function::"
1477 msgstr "K dodatečným informacím (slovníku ``globals``) v šabloně přistupujete pomocí funkce šablony::"
1478
1479 #: ../../../__w/calibre/calibre/manual/template_lang.rst:745
1480 msgid ""
1481 "where ``id`` is any legal variable name. This function checks whether the "
1482 "additional information provided by the developer contains the name. If it "
1483 "does then the function assigns the provided value to a template local "
1484 "variable with that name. If the name is not in the additional information "
1485 "and if an ``expression`` is provided, the ``expression`` is evaluated and "
1486 "the result is assigned to the local variable. If neither a value nor an "
1487 "expression is provided, the function assigns the empty string (``''``) to "
1488 "the local variable."
1489 msgstr "kde ``id`` je libovolný platný název proměnné. Tato funkce zkontroluje, zda dodatečné informace poskytnuté vývojářem obsahují daný název. Pokud ano, funkce přiřadí poskytnutou hodnotu lokální proměnné šablony s tímto názvem. Pokud název v dodatečných informacích není a je zadán ``expression``, vyhodnotí se ``expression`` a výsledek se přiřadí lokální proměnné. Pokud není zadána ani hodnota, ani výraz, funkce přiřadí lokální proměnné prázdný řetězec (``''``)."
1490
1491 #: ../../../__w/calibre/calibre/manual/template_lang.rst:747
1492 msgid ""
1493 "A template can set a value in the ``globals`` dictionary using the template "
1494 "function::"
1495 msgstr "Šablona může nastavit hodnotu ve slovníku ``globals`` pomocí funkce šablony::"
1496
1497 #: ../../../__w/calibre/calibre/manual/template_lang.rst:751
1498 msgid ""
1499 "This function sets the ``globals`` dictionary key:value pair ``id:value`` "
1500 "where ``value`` is the value of the template local variable ``id``. If that "
1501 "local variable doesn't exist then ``value`` is set to the result of "
1502 "evaluating ``expression``."
1503 msgstr "Tato funkce nastaví ve slovníku ``globals`` dvojici klíč:hodnota ``id:value``, kde ``value`` je hodnota lokální proměnné šablony ``id``. Pokud tato lokální proměnná neexistuje, nastaví se ``value`` na výsledek vyhodnocení ``expression``."
1504
1505 #: ../../../__w/calibre/calibre/manual/template_lang.rst:754
1506 msgid "Notes on the difference between modes"
1507 msgstr "Poznámky k rozdílům mezi režimy"
1508
1509 #: ../../../__w/calibre/calibre/manual/template_lang.rst:756
1510 msgid ""
1511 "The three program modes, :ref:`Single Function Mode <single_mode>` (SFM), "
1512 ":ref:`Template Program Mode <template_mode>` (`TPM`), and :ref:`General "
1513 "Program Mode <general_mode>` (`GPM`), work differently. SFM is intended to "
1514 "be 'simple' so it hides a lot of programming language bits."
1515 msgstr "Tři režimy programu, :ref:`režim jedné funkce <single_mode>` (SFM), :ref:`režim programu šablony <template_mode>` (`TPM`) a :ref:`obecný režim programu <general_mode>` (`GPM`), fungují odlišně. SFM má být „jednoduchý“, proto skrývá mnoho částí programovacího jazyka."
1516
1517 #: ../../../__w/calibre/calibre/manual/template_lang.rst:758
1518 msgid "Differences:"
1519 msgstr "Rozdíly:"
1520
1521 #: ../../../__w/calibre/calibre/manual/template_lang.rst:760
1522 msgid ""
1523 "In SFM the value of the column is always passed as an 'invisible' first "
1524 "argument to a function included in the template."
1525 msgstr "V SFM se hodnota sloupce vždy předává jako „neviditelný“ první argument funkci obsažené v šabloně."
1526
1527 #: ../../../__w/calibre/calibre/manual/template_lang.rst:761
1528 msgid ""
1529 "SFM doesn't support the difference between variables and strings; all values"
1530 " are strings."
1531 msgstr "SFM nerozlišuje mezi proměnnými a řetězci; všechny hodnoty jsou řetězce."
1532
1533 #: ../../../__w/calibre/calibre/manual/template_lang.rst:762
1534 msgid ""
1535 "The following SFM template returns either the series name or the string \"no"
1536 " series\"::"
1537 msgstr "Následující šablona SFM vrátí buď název série, nebo řetězec „no series“::"
1538
1539 #: ../../../__w/calibre/calibre/manual/template_lang.rst:766
1540 msgid "The equivalent template in `TPM` is ::"
1541 msgstr "Ekvivalentní šablona v `TPM` je ::"
1542
1543 #: ../../../__w/calibre/calibre/manual/template_lang.rst:770
1544 msgid "The equivalent template in `GPM` is::"
1545 msgstr "V `GPM` by to vypadalo takto::"
1546
1547 #: ../../../__w/calibre/calibre/manual/template_lang.rst:774
1548 msgid ""
1549 "The first argument to ``ifempty`` is the value of the field ``series``. The "
1550 "second argument is the string ``no series``. In SFM the first argument, the "
1551 "value of the field, is automatically passed (the invisible argument)."
1552 msgstr "První argument funkce ``ifempty`` je hodnota pole ``series``. Druhý argument je řetězec ``no series``. V SFM se první argument, hodnota pole, předává automaticky (neviditelný argument)."
1553
1554 #: ../../../__w/calibre/calibre/manual/template_lang.rst:775
1555 msgid ""
1556 "Several template functions, for example ``booksize()`` and "
1557 "``current_library_name()``, take no arguments. Because of the 'invisible "
1558 "argument' you cannot use these functions in SFM."
1559 msgstr "Několik funkcí šablony, například ``booksize()`` a ``current_library_name()``, nepřijímá žádné argumenty. Kvůli „neviditelnému argumentu“ tyto funkce nelze v SFM použít."
1560
1561 #: ../../../__w/calibre/calibre/manual/template_lang.rst:776
1562 msgid ""
1563 "Nested functions, where a function calls another function to compute an "
1564 "argument, cannot be used in SFM. For example this template, intended to "
1565 "return the first 5 characters of the series value uppercased, won't work in "
1566 "SFM::"
1567 msgstr "Vnořené funkce, kdy funkce volá jinou funkci pro výpočet argumentu, nelze v SFM použít. Například tato šablona, která má vrátit prvních 5 znaků hodnoty série převedených na velká písmena, nebude v SFM fungovat::"
1568
1569 #: ../../../__w/calibre/calibre/manual/template_lang.rst:780
1570 msgid ""
1571 "`TPM` and `GPM` support nested functions. The above template in `TPM` would "
1572 "be::"
1573 msgstr "`TPM` a `GPM` podporují vnořené funkce. Výše uvedená šablona v `TPM` by vypadala takto::"
1574
1575 #: ../../../__w/calibre/calibre/manual/template_lang.rst:784
1576 msgid "In `GPM` it would be::"
1577 msgstr "V `GPM` by to vypadalo takto::"
1578
1579 #: ../../../__w/calibre/calibre/manual/template_lang.rst:788
1580 msgid ""
1581 "As noted in the above :ref:`Template Program Mode <template_mode>` section, "
1582 "using ``{`` and ``}`` characters in `TPM` string literals can lead to errors"
1583 " or unexpected results because they confuse the template processor. It tries"
1584 " to treat them as template boundaries, not characters. In some but not all "
1585 "cases you can replace a ``{`` with ``[[`` and a ``}`` with `]]`. Generally, "
1586 "if your program contains ``{`` and ``}`` characters then you should use "
1587 "`General Program Mode`."
1588 msgstr "Jak je uvedeno výše v části :ref:`režim programu šablony <template_mode>`, použití znaků ``{`` a ``}`` v řetězcových literálech `TPM` může vést k chybám nebo neočekávaným výsledkům, protože matou zpracovatele šablon. Ten se je pokouší zpracovat jako hranice šablony, ne jako znaky. V některých případech, ale ne ve všech, můžete ``{`` nahradit ``[[`` a ``}`` nahradit `]]`. Obecně platí, že pokud váš program obsahuje znaky ``{`` a ``}``, měli byste použít `obecný režim programu`."
1589
1590 #: ../../../__w/calibre/calibre/manual/template_lang.rst:792
1591 msgid "User-defined Python template functions"
1592 msgstr "Uživatelsky definované pythonové funkce šablon"
1593
1594 #: ../../../__w/calibre/calibre/manual/template_lang.rst:794
1595 msgid ""
1596 "You can add your own Python functions to the template processor. Such "
1597 "functions can be used in any of the three template programming modes. The "
1598 "functions are added by going to :guilabel:`Preferences -> Advanced -> "
1599 "Template functions`. Instructions are shown in that dialog. Note that you "
1600 "can use `Python Templates` for a similar purpose. As calling user-defined "
1601 "functions is faster than calling a Python template, user-defined functions "
1602 "might be more efficient depending on the complexity of what the function or "
1603 "template does."
1604 msgstr "Do zpracovatele šablon můžete přidat vlastní pythonové funkce. Takové funkce lze použít v kterémkoliv ze tří programovacích režimů šablon. Funkce se přidávají v :guilabel:`Předvolby -> Rozšířené -> Funkce šablony`. Pokyny jsou uvedeny v tomto dialogu. Všimněte si, že k podobnému účelu můžete použít také `pythonové šablony`. Protože volání uživatelsky definovaných funkcí je rychlejší než volání pythonové šablony, mohou být uživatelsky definované funkce efektivnější v závislosti na složitosti toho, co funkce nebo šablona dělá."
1605
1606 #: ../../../__w/calibre/calibre/manual/template_lang.rst:797
1607 msgid "Special notes for using templates in different contexts"
1608 msgstr "Speciální poznámky k používání šablon v různých kontextech"
1609
1610 #: ../../../__w/calibre/calibre/manual/template_lang.rst:799
1611 msgid ""
1612 "In the GUI (:guilabel:`Columns made from other columns` and "
1613 ":guilabel:`Template searches`):"
1614 msgstr "V GUI (:guilabel:`Sloupce sestavené z jiných sloupců` a :guilabel:`Vyhledávání pomocí šablon`):"
1615
1616 #: ../../../__w/calibre/calibre/manual/template_lang.rst:801
1617 msgid "GPM templates work as before."
1618 msgstr "Šablony GPM fungují stejně jako dříve."
1619
1620 #: ../../../__w/calibre/calibre/manual/template_lang.rst:802
1621 msgid "Python templates have full access to the calibre database."
1622 msgstr "Pythonové šablony mají plný přístup k databázi calibre."
1623
1624 #: ../../../__w/calibre/calibre/manual/template_lang.rst:804
1625 msgid "In icon rules:"
1626 msgstr "V pravidlech ikon:"
1627
1628 #: ../../../__w/calibre/calibre/manual/template_lang.rst:806
1629 msgid ""
1630 "icon rule templates have no book data so field-based functions such as "
1631 ":ref:`ff_format_date_field`, :ref:`ff_list_count_field`, and "
1632 ":ref:`ff_check_yes_no` won't work."
1633 msgstr "Šablony pravidel ikon nemají k dispozici data knihy, takže funkce založené na polích, jako jsou :ref:`ff_format_date_field`, :ref:`ff_list_count_field` a :ref:`ff_check_yes_no`, nebudou fungovat."
1634
1635 #: ../../../__w/calibre/calibre/manual/template_lang.rst:808
1636 msgid "In the Content server:"
1637 msgstr "V Serveru s obsahem:"
1638
1639 #: ../../../__w/calibre/calibre/manual/template_lang.rst:810
1640 msgid ""
1641 "Templates have access to the new API but not the old API (LibraryDatabase)."
1642 msgstr "Šablony mají přístup k novému API, ale ne ke starému API (LibraryDatabase)."
1643
1644 #: ../../../__w/calibre/calibre/manual/template_lang.rst:811
1645 msgid ""
1646 "Because of the above, the following formatter functions are not guaranteed "
1647 "to work in GPM templates (composite columns, icon rules, etc) and should be "
1648 "avoided if you use the content server:"
1649 msgstr "Z výše uvedeného důvodu není zaručeno, že následující funkce formatteru budou fungovat v šablonách GPM (složené sloupce, pravidla ikon atd.), a pokud používáte server s obsahem, měli byste se jim vyhnout:"
1650
1651 #: ../../../__w/calibre/calibre/manual/template_lang.rst:813
1652 msgid ":ref:`ff_connected_device_name`"
1653 msgstr ":ref:`ff_connected_device_name`"
1654
1655 #: ../../../__w/calibre/calibre/manual/template_lang.rst:814
1656 msgid ":ref:`ff_connected_device_uuid`"
1657 msgstr ":ref:`ff_connected_device_uuid`"
1658
1659 #: ../../../__w/calibre/calibre/manual/template_lang.rst:815
1660 msgid ":ref:`ff_current_virtual_library_name`"
1661 msgstr ":ref:`ff_current_virtual_library_name`"
1662
1663 #: ../../../__w/calibre/calibre/manual/template_lang.rst:816
1664 msgid ":ref:`ff_is_marked`"
1665 msgstr ":ref:`ff_is_marked`"
1666
1667 #: ../../../__w/calibre/calibre/manual/template_lang.rst:817
1668 msgid ":ref:`ff_virtual_libraries`"
1669 msgstr ":ref:`ff_virtual_libraries`"
1670
1671 #: ../../../__w/calibre/calibre/manual/template_lang.rst:820
1672 msgid "Special notes for save/send templates"
1673 msgstr "Speciální poznámky k šablonám pro uložení/odeslání"
1674
1675 #: ../../../__w/calibre/calibre/manual/template_lang.rst:822
1676 msgid ""
1677 "Special processing is applied when a template is used in a :guilabel:`Save "
1678 "to disk` or :guilabel:`Send to device` template. The values of the fields "
1679 "are cleaned, replacing characters that are special to file systems with "
1680 "underscores, including slashes. This means that field text cannot be used to"
1681 " create folders. However, slashes are not changed in prefix or suffix "
1682 "strings, so slashes in these strings will cause folders to be created. "
1683 "Because of this, you can create variable-depth folder structure."
1684 msgstr "Při použití šablony jako šablony pro :guilabel:`Uložit na disk` nebo :guilabel:`Odeslat do zařízení` se použije speciální zpracování. Hodnoty polí se vyčistí tak, že znaky se speciálním významem pro systémy souborů, včetně lomítek, se nahradí podtržítky. To znamená, že text pole nelze použít k vytváření složek. Lomítka se však nemění v řetězcích předpony nebo přípony, takže lomítka v těchto řetězcích způsobí vytvoření složek. Díky tomu můžete vytvořit strukturu složek s proměnlivou hloubkou."
1685
1686 #: ../../../__w/calibre/calibre/manual/template_lang.rst:824
1687 msgid ""
1688 "For example, assume we want the folder structure `series/series_index - "
1689 "title`, with the caveat that if series does not exist, then the title should"
1690 " be in the top folder. The template to do this is::"
1691 msgstr "Předpokládejme například, že chceme strukturu složek `series/series_index - title`, s tím omezením, že pokud série neexistuje, má být název knihy v nejvyšší složce. Šablona pro tento účel je::"
1692
1693 #: ../../../__w/calibre/calibre/manual/template_lang.rst:828
1694 msgid "The slash and the hyphen appear only if series is not empty."
1695 msgstr "Lomítko a spojovník se zobrazí pouze v případě, že pole series není prázdné."
1696
1697 #: ../../../__w/calibre/calibre/manual/template_lang.rst:830
1698 msgid ""
1699 "The lookup function lets us do even fancier processing. For example, assume "
1700 "that if a book has a series, then we want the folder structure "
1701 "`series/series index - title.fmt`. If the book does not have a series then "
1702 "we want the folder structure `genre/author_sort/title.fmt`. If the book has "
1703 "no genre then we want to use 'Unknown'. We want two completely different "
1704 "paths, depending on the value of series."
1705 msgstr "Funkce lookup umožňuje ještě propracovanější zpracování. Předpokládejme například, že pokud má kniha sérii, chceme strukturu složek `series/series index - title.fmt`. Pokud kniha sérii nemá, chceme strukturu složek `genre/author_sort/title.fmt`. Pokud kniha nemá žánr, chceme použít hodnotu 'Unknown'. Chceme dvě zcela odlišné cesty v závislosti na hodnotě pole series."
1706
1707 #: ../../../__w/calibre/calibre/manual/template_lang.rst:832
1708 msgid "To accomplish this, we:"
1709 msgstr "Abychom toho dosáhli, provedeme toto:"
1710
1711 #: ../../../__w/calibre/calibre/manual/template_lang.rst:834
1712 msgid ""
1713 "Create a composite field (give it lookup name #aa) containing "
1714 "``{series}/{series_index} - {title}``. If the series is not empty, then this"
1715 " template will produce `series/series_index - title`."
1716 msgstr "Vytvořte složené pole (dejte mu název vyhledávání #aa) obsahující ``{series}/{series_index} - {title}``. Pokud série není prázdná, tato šablona vytvoří `series/series_index - title`."
1717
1718 #: ../../../__w/calibre/calibre/manual/template_lang.rst:835
1719 msgid ""
1720 "Create a composite field (give it lookup name #bb) containing "
1721 "``{#genre:ifempty(Unknown)}/{author_sort}/{title}``. This template produces "
1722 "`genre/author_sort/title`, where an empty genre is replaced with `Unknown`."
1723 msgstr "Vytvořte složené pole (dejte mu název vyhledávání #bb) obsahující ``{#genre:ifempty(Unknown)}/{author_sort}/{title}``. Tato šablona vytvoří `genre/author_sort/title`, kde se prázdný žánr nahradí hodnotou `Unknown`."
1724
1725 #: ../../../__w/calibre/calibre/manual/template_lang.rst:836
1726 msgid ""
1727 "Set the save template to ``{series:lookup(.,#aa,#bb)}``. This template "
1728 "chooses composite field ``#aa`` if series is not empty and composite field "
1729 "``#bb`` if series is empty. We therefore have two completely different save "
1730 "paths, depending on whether or not `series` is empty."
1731 msgstr "Nastavte šablonu pro uložení na ``{series:lookup(.,#aa,#bb)}``. Tato šablona vybere složené pole ``#aa``, pokud pole series není prázdné, a složené pole ``#bb``, pokud je pole series prázdné. Máme tedy dvě zcela odlišné cesty pro uložení podle toho, zda je pole `series` prázdné."
1732
1733 #: ../../../__w/calibre/calibre/manual/template_lang.rst:839
1734 msgid "Tips"
1735 msgstr "Rady"
1736
1737 #: ../../../__w/calibre/calibre/manual/template_lang.rst:841
1738 msgid ""
1739 "Use the Template Tester to test templates. Add the tester to the context "
1740 "menu for books in the library and/or give it a keyboard shortcut."
1741 msgstr "K testování šablon použijte Testovač šablon. Přidejte testovač do místní nabídky knih v knihovně nebo mu přiřaďte klávesovou zkratku, případně obojí."
1742
1743 #: ../../../__w/calibre/calibre/manual/template_lang.rst:842
1744 msgid ""
1745 "Templates can use other templates by referencing composite columns built "
1746 "with the desired template. Alternatively, you can use Stored Templates."
1747 msgstr "Šablony mohou používat jiné šablony prostřednictvím odkazů na složené sloupce sestavené požadovanou šablonou. Případně můžete použít uložené šablony."
1748
1749 #: ../../../__w/calibre/calibre/manual/template_lang.rst:843
1750 msgid ""
1751 "In a plugboard, you can set a field to empty (or whatever is equivalent to "
1752 "empty) by using the special template ``{}``. This template will always "
1753 "evaluate to an empty string."
1754 msgstr "V zásuvném panelu můžete pole nastavit na prázdnou hodnotu (nebo na ekvivalent prázdné hodnoty) pomocí speciální šablony ``{}``. Tato šablona se vždy vyhodnotí jako prázdný řetězec."
1755
1756 #: ../../../__w/calibre/calibre/manual/template_lang.rst:844
1757 msgid ""
1758 "The technique described above to show numbers even if they have a zero value"
1759 " works with the standard field series_index."
1760 msgstr "Výše popsaná technika pro zobrazení čísel i tehdy, když mají nulovou hodnotu, funguje se standardním polem series_index."
1761
1762 #: ../../../__w/calibre/calibre/manual/template_lang.rst:849
1763 msgid "Template function reference"
1764 msgstr "Referenční příručka funkcí šablon"