Slight change to the dialog

This commit is contained in:
Charles Haley 2011-01-13 13:05:11 +00:00
parent 3cdc088f0d
commit 13fd31dd87

View File

@ -29,7 +29,7 @@ p, li { white-space: pre-wrap; }
</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;">
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Here you can add and remove functions used in template processing. A template function is writen in python. It takes information from the book, processes it in some way, then returns a string result. Functions defined here are usable in templates in the same way that builtin functions are usable. The function must be named </span><span style=" font-size:8pt; font-weight:600;">evaluate</span><span style=" font-size:8pt;">, and must have the signature shown below. </span></p>
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt; font-weight:600;">evaluate(self, formatter, kwargs, mi, locals, your_arguments)</span></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt; font-weight:600;">evaluate(self, formatter, kwargs, mi, locals, your_arguments) </span><span style=" font-size:8pt;">returning a</span><span style=" font-size:8pt; font-weight:600;"> unicode </span><span style=" font-size:8pt;">string</span></p>
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The arguments to evaluate are:</span></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">- formatter: the instance of the formatter being used to evaluate the current template. You can use this to do recursive template evaluation.</span></p>