This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author dmgass
Recipients
Date 2004-07-28.22:02:40
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Logged In: YES 
user_id=995755

For the case where you instantiate HtmlDiff saying you want
tabs expanded it will insert non-breaking space(s) up to the
next tab stop.  

For the case where you do NOT specify tab expansion it will
substitute one non-breakable space unless you override it
with a different string (where you could choose 3,4, or 8
spaces).  We could make 3,4, or 8 spaces the default but it
makes it more complex because it would require two
overridable class-level members ...
    spaces_per_tab = 8
    tab_space = '&nbsp'
... and the post processing would look like ...
     return s.replace('\t',self.tab_space*self.spaces_per_tab)
... and the pre-processing setup in the constructor would
need to override the class-level member used for the post
processing:
     self.spaces_per_tab=1

We could also use a special character for tabs.  We could
even attempt to use a combination of nbsp and a special
character to show the tab stops.  I'd need to play with re's
to do that.
History
Date User Action Args
2007-08-23 15:36:20adminlinkissue914575 messages
2007-08-23 15:36:20admincreate