Allow additional ansi mappings to be passed from settings for easier customization.
This commit is contained in:
parent
80f7bb1cb5
commit
f263ea2aaa
2 changed files with 5 additions and 1 deletions
|
|
@ -319,7 +319,10 @@ PROTOTYPE_MODULES = ["world.prototypes"]
|
||||||
# Module holding settings/actions for the dummyrunner program (see the
|
# Module holding settings/actions for the dummyrunner program (see the
|
||||||
# dummyrunner for more information)
|
# dummyrunner for more information)
|
||||||
DUMMYRUNNER_SETTINGS_MODULE = "evennia.server.profiling.dummyrunner_settings"
|
DUMMYRUNNER_SETTINGS_MODULE = "evennia.server.profiling.dummyrunner_settings"
|
||||||
|
# Additional mappings used to extend the existing Evennia ANSI mappings.
|
||||||
|
# All mappings should be a tuple of a string to one of the constants provided
|
||||||
|
# in ansi.py. For example, (r'%r', "\r\n")
|
||||||
|
ADDITIONAL_ANSI_MAPPINGS = []
|
||||||
######################################################################
|
######################################################################
|
||||||
# Default command sets
|
# Default command sets
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
|
||||||
|
|
@ -414,6 +414,7 @@ class ANSIParser(object):
|
||||||
(r'|[W', ANSI_BACK_WHITE), # light grey background
|
(r'|[W', ANSI_BACK_WHITE), # light grey background
|
||||||
(r'|[X', ANSI_BACK_BLACK) # pure black background
|
(r'|[X', ANSI_BACK_BLACK) # pure black background
|
||||||
]
|
]
|
||||||
|
ext_ansi_map += settings.ADDITIONAL_ANSI_MAPPINGS
|
||||||
|
|
||||||
ansi_bright_bgs = [
|
ansi_bright_bgs = [
|
||||||
# "bright" ANSI backgrounds using xterm256 since ANSI
|
# "bright" ANSI backgrounds using xterm256 since ANSI
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue