Logo Search packages:      
Sourcecode: yagtd version File versions  Download package

def yagtd::GTD::_colorize (   self,
  string 
) [private]
Colorize the given 'string'.

Definition at line 188 of file yagtd.py.

                               :
        """Colorize the given 'string'."""

        s = string

        if self.colorize:
            # Scan to colorize attributes (accordingly to global settings) ...
            for attr in Task.attributes_list[3:]:
                color_fct = lambda m: eval(attr.upper() + '_COLOR') + m.group(0) + DEFAULT_COLOR
                s = eval(attr.upper() + '_REGEXP').sub(color_fct, s)

        return s


Generated by  Doxygen 1.6.0   Back to index