Move {- and %c color markup to contrib, make easily extendable, as per #1229

This commit is contained in:
Griatch 2017-07-19 20:32:21 +02:00
parent 83163ae4b3
commit 03f4ecb3a4
4 changed files with 168 additions and 98 deletions

View file

@ -331,10 +331,34 @@ PROTOTYPE_MODULES = ["world.prototypes"]
# dummyrunner for more information)
DUMMYRUNNER_SETTINGS_MODULE = "evennia.server.profiling.dummyrunner_settings"
# Mapping to extend Evennia's normal ANSI color tags. The mapping is a list of
# tuples mapping the tag to the ANSI convertion, like `("%c%r", ansi.ANSI_RED)`
# (the evennia.utils.ansi module contains all ANSI escape sequences). This is
# mainly supplied for support of legacy codebase tag formats.
# tuples mapping the tag to the ANSI convertion, like `(r"%c%r", ansi.ANSI_RED)`
# (the evennia.utils.ansi module contains all ANSI escape sequences). Default
# is to use `|` and `|[` prefixes.
COLOR_ANSI_EXTRA_MAP = []
# Extend the available regexes for adding XTERM256 colors in-game. This is given
# as a list of regexes, where each regex must contain three anonymous groups for
# holding integers 0-5 for the red, green and blue components Default is
# is r'\|([0-5])([0-5])([0-5])', which allows e.g. |500 for red.
# XTERM256 foreground color replacement
COLOR_XTERM256_EXTRA_FG = []
# XTERM256 background color replacement. Default is \|\[([0-5])([0-5])([0-5])'
COLOR_XTERM256_EXTRA_BG = []
# Extend the available regexes for adding XTERM256 grayscale values in-game. Given
# as a list of regexes, where each regex must contain one anonymous group containing
# a single letter a-z to mark the level from white to black. Default is r'\|=([a-z])',
# which allows e.g. |=k for a medium gray.
# XTERM256 grayscale foreground
COLOR_XTERM256_EXTRA_GFG = []
# XTERM256 grayscale background. Default is \|\[=([a-z])'
COLOR_XTERM256_EXTRA_GBG = []
# ANSI does not support bright backgrounds, so Evennia fakes this by mapping it to
# XTERM256 backgrounds where supported. This is a list of tuples that maps the wanted
# regex to a valid XTERM256 background tag, such as `(r'{[r', r'{[500')`.
COLOR_ANSI_BRIGHT_BG_EXTRA_MAP = []
# If set True, the above color settings *replace* the default |-style color markdown
# rather than extend it.
COLOR_NO_DEFAULT = False
######################################################################
# Default command sets