@Kovid,
I think, there seems to be something wrong in the manual. Missing/wrong character for backslash.
First place:
https://manual.calibre-ebook.com/template_lang.html, section:
"Using functions in templates - single-function mode"
Quote:
Arguments are separated by commas. Commas inside arguments must be preceeded by a backslash ( ‘' ). The last (or only) argument cannot contain a closing parenthesis ( ‘)’ ). Functions return the value of the field used in the template, suitably modified.
|
( ‘' ) --> [‘] instead of [\]
Second place:
https://manual.calibre-ebook.com/gen...ndex-separator
Quote:
Examples using basic template mode and assuming that the tags column (which is comma-separated) contains "A, B, C": {tags:sublist(0,1,,)} returns "A". {tags:sublist(-1,0,,)} returns "C". {tags:sublist(0,-1,,)} returns "A, B".
|
instead of
Quote:
Examples using basic template mode and assuming that the tags column (which is comma-separated) contains "A, B, C": {tags:sublist(0,1,\,)} returns "A". {tags:sublist(-1,0,\,)} returns "C". {tags:sublist(0,-1,\,)} returns "A, B".
|