summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/gui/theme.cpp5
-rw-r--r--src/gui/theme.h2
-rw-r--r--src/gui/whoisonline.cpp5
3 files changed, 12 insertions, 0 deletions
diff --git a/src/gui/theme.cpp b/src/gui/theme.cpp
index 4ff1f8ea4..3e7775b63 100644
--- a/src/gui/theme.cpp
+++ b/src/gui/theme.cpp
@@ -195,6 +195,7 @@ Theme::Theme():
mColors[SERVER].ch = 'S';
mColors[LOGGER].ch = 'L';
mColors[HYPERLINK].ch = '<';
+ mColors[SELFNICK].ch = 's';
mCharColors['H'] = HIGHLIGHT;
mCharColors['C'] = CHAT;
mCharColors['G'] = GM;
@@ -207,6 +208,7 @@ Theme::Theme():
mCharColors['S'] = SERVER;
mCharColors['L'] = LOGGER;
mCharColors['<'] = HYPERLINK;
+ mCharColors['s'] = SELFNICK;
// here need use outlined colors
mCharColors['H' | 0x80] = HIGHLIGHT_OUTLINE;
@@ -221,6 +223,7 @@ Theme::Theme():
mCharColors['S' | 0x80] = SERVER_OUTLINE;
mCharColors['L' | 0x80] = LOGGER_OUTLINE;
mCharColors['<' | 0x80] = HYPERLINK_OUTLINE;
+ mCharColors['s' | 0x80] = SELFNICK_OUTLINE;
}
Theme::~Theme()
@@ -724,6 +727,8 @@ static int readColorType(const std::string &type)
{
"BROWSERBOX",
"BROWSERBOX_OUTLINE",
+ "SELFNICK",
+ "SELFNICK_OUTLINE",
"TEXT",
"CARET",
"SHADOW",
diff --git a/src/gui/theme.h b/src/gui/theme.h
index 572946e0b..f46bd23ab 100644
--- a/src/gui/theme.h
+++ b/src/gui/theme.h
@@ -190,6 +190,8 @@ class Theme final : public Palette, public ConfigListener
{
BROWSERBOX = 0,
BROWSERBOX_OUTLINE,
+ SELFNICK_OUTLINE,
+ SELFNICK,
TEXT,
CARET,
SHADOW,
diff --git a/src/gui/whoisonline.cpp b/src/gui/whoisonline.cpp
index 893b27a46..170f5ba9e 100644
--- a/src/gui/whoisonline.cpp
+++ b/src/gui/whoisonline.cpp
@@ -733,6 +733,11 @@ void WhoIsOnline::setNeutralColor(OnlinePlayer *const player)
if (actorSpriteManager && player_node)
{
const std::string &nick = player->getNick();
+ if (nick == player_node->getName())
+ {
+ player->setText("s");
+ return;
+ }
if (player_node->isInParty())
{
const Party *const party = player_node->getParty();