Changeset 2398:473b6c2a063a in livinglogic.python.xist

Show
Ignore:
Timestamp:
06/24/05 15:48:30 (15 years ago)
Author:
Walter Doerwald <walter@…>
Branch:
default
Message:

SGMLOPParser can now create Text nodes, even if the application registered
is not a XIST Parser.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • _xist/parsers.py

    r2361 r2398  
    1414<par>It contains different &sax;2 parser driver classes (mostly for sgmlop, everything else 
    1515is from <app moreinfo="http://pyxml.sf.net/">PyXML</app>). It includes a 
    16 <pyref class="HTMLParser"><class>HTMLParser</class></pyref> that uses sgmlop to parse &html; 
    17 and emit &sax;2 events.</par> 
     16<pyref class="HTMLParser"><class>HTMLParser</class></pyref> that uses sgmlop 
     17to parse &html; and emit &sax;2 events.</par> 
    1818""" 
    1919 
     
    230230        if text is None: 
    231231            return xsc.Null 
    232         ct = self.getContentHandler().createText 
     232        ct = getattr(self.getContentHandler(), "createText", xsc.Text) 
    233233        node = xsc.Frag() 
    234234        while True: