Terry J. Reedy <tjre...@udel.edu> added the comment:

A coda on my 'obsolete and superseded' claim: text formatting events have 2 
sources -- the text being displayed and user actions while reading.  formatter 
somewhat mixes these together.

html.parser.HTMLParser generates events from the text in the form of calls to 
handle_xyz methods, where 'xyy is most commonly 'starttag', 'data', 'endtag'.  
HTMLPareser subclasses replace the default 'pass' implementations.  So the idea 
is similar to  formatter.NullFormatter.  IDLE uses the tkinter Text widget as 
the writer instance for its HTMLParser subclass.  Responses to events may 
depend on user settings, which may be changed by user events.

For a GUI app, user events are handled by the GUI framework and may or mayy not 
require user coding to handle.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue42299>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to