def _grow(self, generation, rule, angle, length, time=maxint, draw=True):
if generation == <NUM_LIT:0>:<EOL><INDENT>self._duration = <NUM_LIT:1> + maxint-time<EOL><DEDENT>if length <= self.threshold:<EOL><INDENT>self._duration = <NUM_LIT:1> + maxint-time<EOL>return<EOL><DEDENT>if rule in self.commands:<EOL><INDENT>self.commands[rule](self, generation, rule, angle, length, time)<EOL><DEDENT>if draw:<EOL><INDENT>if rule == "<STR_LIT:f>":<EOL><INDENT>_ctx.translate(<NUM_LIT:0>, -min(length, length*time))<EOL><DEDENT>elif rule == "<STR_LIT:->":<EOL><INDENT>_ctx.rotate(max(-angle, -angle*time))<EOL><DEDENT>elif rule == "<STR_LIT:+>":<EOL><INDENT>_ctx.rotate(min(+angle, +angle*time))<EOL><DEDENT>elif rule == "<STR_LIT:|>":<EOL><INDENT>_ctx.rotate(<NUM_LIT>)<EOL><DEDENT>elif rule == "<STR_LIT:[>":<EOL><INDENT>_ctx.push()<EOL><DEDENT>elif rule == "<STR_LIT:]>":<EOL><INDENT>_ctx.pop()<EOL><DEDENT><DEDENT>if rule in self.rulesand generation > <NUM_LIT:0>and time > <NUM_LIT:0>:<EOL><INDENT>for cmd in self.rules[rule]:<EOL><INDENT>if cmd == "<STR_LIT:F>":<EOL><INDENT>time -= self.cost<EOL><DEDENT>elif cmd == "<STR_LIT:!>":<EOL><INDENT>angle = -angle<EOL><DEDENT>elif cmd == "<STR_LIT:(>":<EOL><INDENT>angle *= <NUM_LIT><EOL><DEDENT>elif cmd == "<STR_LIT:)>":<EOL><INDENT>angle *= <NUM_LIT><EOL><DEDENT>elif cmd == "<STR_LIT:<>":<EOL><INDENT>length *= <NUM_LIT><EOL><DEDENT>elif cmd == "<STR_LIT:>>":<EOL><INDENT>length *= <NUM_LIT><EOL><DEDENT>self._grow(<EOL>generation-<NUM_LIT:1>,<EOL>cmd,<EOL>angle,<EOL>length*self.decrease,<EOL>time,<EOL>draw<EOL>)<EOL><DEDENT><DEDENT>elif rule == "<STR_LIT:F>"or (rule in self.rules and self.rules[rule] == "<STR_LIT>"):<EOL><INDENT>self._segments += <NUM_LIT:1><EOL>if draw and time > <NUM_LIT:0>:<EOL><INDENT>length = min(length, length*time)<EOL>if self._timed:<EOL><INDENT>self.segment(length, generation, time, id=self._segments)<EOL><DEDENT>else:<EOL><INDENT>self.segment(length, generation, None, id=self._segments)<EOL><DEDENT>_ctx.translate(<NUM_LIT:0>, -length)<EOL><DEDENT><DEDENT>
Recurse through the system.

        When a segment is drawn, the LSsytem.segment() method will be called.
        You can customize this method to create your own visualizations.
        It takes an optional time parameter. 

        If you divide this parameter by LSsytem.duration() you get 
        a number between 0.0 and 1.0 you can use as an alpha value for example.

        The method also has an id parameter which is a unique number 
        between 0 and LSystem.segments.