mirror of
https://github.com/evennia/evennia.git
synced 2026-04-01 13:37:17 +02:00
Removed <strong> conversion of multiple ansii highlights in the web client. It doesn't matter either way for me, and since it seems it does for others, I can just as well disable it so it all looks the same in webclient and telnet. This relates to one of the points in Issue 309.
This commit is contained in:
parent
6a1f66d759
commit
d4bf67e94e
1 changed files with 5 additions and 3 deletions
|
|
@ -51,9 +51,11 @@ class TextToHTMLparser(object):
|
|||
return re.sub(self.normalcode, "", text)
|
||||
|
||||
def re_bold(self, text):
|
||||
"Replace ansi hilight with strong text element."
|
||||
regexp = "(?:%s)(.*?)(?=%s)" % (self.bold, self.codestop)
|
||||
return re.sub(regexp, r'<strong>\1</strong>', text)
|
||||
"Clean out superfluous hilights rather than set <strong>to make it match the look of telnet."
|
||||
#"Replace ansi hilight with strong text element."
|
||||
#regexp = "(?:%s)(.*?)(?=%s)" % (self.bold, self.codestop)
|
||||
#return re.sub(regexp, r'<strong>\1</strong>', text)
|
||||
return re.sub(self.bold, "", text)
|
||||
|
||||
def re_underline(self, text):
|
||||
"Replace ansi underline with html underline class name."
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue