> The code is a crude hack as it makes it own analysis of the directives
> but having it run before split_text made it much more simple to program.

Oh and what i forgot, this is only half the job. Consider this:

| [% BLOCK foo %]
|   Hello
|     1234
| [% BLOCK %]

This would be deintend to

| Hello
|   1234

However when used like this:

| <foo>
|   <bar>
|     [% INCLUDE foo %]
|   </bar>
| </foo>

the output should of course be:

| <foo>
|   <bar>
|     Hello
|       1234
|   </bar>
| </foo>

So the identation in this case must be saved and added while
processing the called block. So i guess all the identation 
and deindentation must be done later in the parsing of the
template.


Regards
Michael

-- 
It's an insane world, but i'm proud to be a part of it. -- Bill Hicks

_______________________________________________
templates mailing list
[email protected]
http://mail.template-toolkit.org/mailman/listinfo/templates

Reply via email to