Package trac :: Package util :: Module html :: Class Deuglifier

Class Deuglifier

source code

object --+
         |
        Deuglifier

Help base class used for cleaning up HTML riddled with <FONT COLOR=...> tags and replace them with appropriate <span class="...">.

The subclass must define a rules() static method returning a list of regular expression fragments, each defining a capture group in which the name will be reused for the span's class. Two special group names, font and endfont are used to emit <span> and </span>, respectively.

Instance Methods
 
format(self, indata) source code
 
replace(self, fullmatch) source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __init__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Static Methods
a new object with type S, a subtype of T
__new__(cls) source code
Properties

Inherited from object: __class__

Method Details

__new__(cls)
Static Method

source code 
Returns: a new object with type S, a subtype of T
Overrides: object.__new__
(inherited documentation)