Added a comment about the emoticon regex

This commit is contained in:
Travis Shirk 2005-11-13 21:16:21 +00:00
parent a433b2d58c
commit fdb89e2ff8
1 changed files with 2 additions and 0 deletions

View File

@ -1062,6 +1062,8 @@ class Interface:
basic_pattern = links + mail + formatting basic_pattern = links + mail + formatting
self.basic_pattern_re = sre.compile(basic_pattern, sre.IGNORECASE) self.basic_pattern_re = sre.compile(basic_pattern, sre.IGNORECASE)
# When an emoticon is bordered by an alpha-numeric character it is NOT
# expanded. e.g., foo:) NO, foo :) YES, (brb) NO, (:)) YES, etc.
emoticons_pattern = '(?<!\w)(?:' emoticons_pattern = '(?<!\w)(?:'
# sort keys by length so :qwe emot is checked before :q # sort keys by length so :qwe emot is checked before :q
keys = self.emoticons.keys() keys = self.emoticons.keys()