Quote:
Originally Posted by beckywc
Do I place this in the documentation box of the template function? Sorry I'm really a new at this.
|
No. This is a template, and it goes in the template box when you create the new custom column.
In general, templates begin with a { character or, rarely, the word 'program:'. Python code, the stuff that goes into the template functions dialog, begin with 'def evaluate'. It will be rare that someone provides a python template function, because so few people can understand and modify them. Templates are more easily modified by users, so you will see them more often.
Pointer: you can edit a composite (column made from columns) custom column's template by clicking in the column and hitting F2. A dialog box will open in which you can change the template. This is far more convenient than editing the column definition.
You might want to read calibre's template language manual
http://calibre-ebook.com/user_manual/template_lang.html. That might give you some info about what it is the template is doing.