summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-07-21 23:28:16 +0300
committerAndrei Karas <akaras@inbox.ru>2012-07-21 23:28:16 +0300
commit42c0ad1606c1169422b0baba3b4d4ba1d1129d36 (patch)
tree4399c3472e52c594c20bfe52b8c31a05158f6c17
parent0db159ef0f611ba014c59e773a59661b92ab7fde (diff)
downloadmv-42c0ad1606c1169422b0baba3b4d4ba1d1129d36.tar.gz
mv-42c0ad1606c1169422b0baba3b4d4ba1d1129d36.tar.bz2
mv-42c0ad1606c1169422b0baba3b4d4ba1d1129d36.tar.xz
mv-42c0ad1606c1169422b0baba3b4d4ba1d1129d36.zip
Add two new colors to themes.
BUBBLE_NAME for speaker nick. BUBBLE_TEXT for speach text.
-rw-r--r--data/graphics/gui/colors.xml3
-rw-r--r--data/themes/blacknblack/colors.xml2
-rw-r--r--data/themes/blackwood/colors.xml2
-rw-r--r--data/themes/enchilado/colors.xml2
-rw-r--r--data/themes/mana/colors.xml2
-rw-r--r--data/themes/pink/colors.xml2
-rw-r--r--data/themes/unity/colors.xml4
-rw-r--r--data/themes/wood/colors.xml2
-rw-r--r--src/being.cpp2
-rw-r--r--src/gui/speechbubble.cpp4
-rw-r--r--src/gui/speechbubble.h2
-rw-r--r--src/gui/theme.cpp2
-rw-r--r--src/gui/theme.h2
13 files changed, 25 insertions, 6 deletions
diff --git a/data/graphics/gui/colors.xml b/data/graphics/gui/colors.xml
index 4203b482c..a4798c760 100644
--- a/data/graphics/gui/colors.xml
+++ b/data/graphics/gui/colors.xml
@@ -48,7 +48,8 @@
<color id="SERVER_VERSION_NOT_SUPPORTED" color="#DC0000" />
<color id="WARNING" color="#FF0000" />
<color id="PLAYER_ADVANCED" color="#005000" />
-
+ <color id="BUBBLE_NAME" color="#ffffff" />
+ <color id="BUBBLE_TEXT" color="#ffffff" />
<color id="RED" color="#ff0000" />
<color id="GREEN" color="#009000" />
<color id="BLUE" color="#0000ff" />
diff --git a/data/themes/blacknblack/colors.xml b/data/themes/blacknblack/colors.xml
index 9723b3382..cda7bdfe4 100644
--- a/data/themes/blacknblack/colors.xml
+++ b/data/themes/blacknblack/colors.xml
@@ -48,6 +48,8 @@
<color id="SERVER_VERSION_NOT_SUPPORTED" color="#DC0000" />
<color id="WARNING" color="#ffdddd" />
<color id="PLAYER_ADVANCED" color="#005000" />
+ <color id="BUBBLE_NAME" color="#ffffff" />
+ <color id="BUBBLE_TEXT" color="#ffffff" />
<color id="RED" color="#ffffff" />
<color id="GREEN" color="#ffffff" />
diff --git a/data/themes/blackwood/colors.xml b/data/themes/blackwood/colors.xml
index 523d164c7..f21ae45b9 100644
--- a/data/themes/blackwood/colors.xml
+++ b/data/themes/blackwood/colors.xml
@@ -47,6 +47,8 @@
<color id="AMMO" color="#aa3c05" />
<color id="WARNING" color="#FF0000" />
<color id="PLAYER_ADVANCED" color="#005000" />
+ <color id="BUBBLE_NAME" color="#000000" />
+ <color id="BUBBLE_TEXT" color="#000000" />
<color id="RED" color="#ff0000" />
<color id="GREEN" color="#009000" />
diff --git a/data/themes/enchilado/colors.xml b/data/themes/enchilado/colors.xml
index 0c19f5a47..bf3fd8f3e 100644
--- a/data/themes/enchilado/colors.xml
+++ b/data/themes/enchilado/colors.xml
@@ -48,6 +48,8 @@
<color id="SERVER_VERSION_NOT_SUPPORTED" color="#DC0000" />
<color id="WARNING" color="#FF0000" />
<color id="PLAYER_ADVANCED" color="#005000" />
+ <color id="BUBBLE_NAME" color="#ffffff" />
+ <color id="BUBBLE_TEXT" color="#ffffff" />
<color id="RED" color="#ff0000" />
<color id="GREEN" color="#009000" />
diff --git a/data/themes/mana/colors.xml b/data/themes/mana/colors.xml
index 45937e268..79821eff2 100644
--- a/data/themes/mana/colors.xml
+++ b/data/themes/mana/colors.xml
@@ -48,6 +48,8 @@
<color id="SERVER_VERSION_NOT_SUPPORTED" color="#DC0000" />
<color id="WARNING" color="#FF0000" />
<color id="PLAYER_ADVANCED" color="#005000" />
+ <color id="BUBBLE_NAME" color="#ffffff" />
+ <color id="BUBBLE_TEXT" color="#ffffff" />
<color id="RED" color="#ff0000" />
<color id="GREEN" color="#009000" />
diff --git a/data/themes/pink/colors.xml b/data/themes/pink/colors.xml
index f2b20567e..478779f6e 100644
--- a/data/themes/pink/colors.xml
+++ b/data/themes/pink/colors.xml
@@ -48,6 +48,8 @@
<color id="SERVER_VERSION_NOT_SUPPORTED" color="#DC0000" />
<color id="WARNING" color="#FF0000" />
<color id="PLAYER_ADVANCED" color="#005000" />
+ <color id="BUBBLE_NAME" color="#000000" />
+ <color id="BUBBLE_TEXT" color="#000000" />
<color id="RED" color="#ff0000" />
<color id="GREEN" color="#009000" />
diff --git a/data/themes/unity/colors.xml b/data/themes/unity/colors.xml
index c1bca3d8c..059d8cce7 100644
--- a/data/themes/unity/colors.xml
+++ b/data/themes/unity/colors.xml
@@ -47,7 +47,9 @@
<color id="WARNING" color="#FC6400" />
<color id="PLAYER_ADVANCED" color="#FC6400" />
<color id="ITEM_NOT_EQUIPPED" color="#E0E0E0" />
-
+ <color id="BUBBLE_NAME" color="#ffffff" />
+ <color id="BUBBLE_TEXT" color="#ffffff" />
+
<color id="RED" color="#FFA8A8" />
<color id="GREEN" color="#59FF6C" />
<color id="BLUE" color="#00FFFF" />
diff --git a/data/themes/wood/colors.xml b/data/themes/wood/colors.xml
index 83842b503..4b3d14111 100644
--- a/data/themes/wood/colors.xml
+++ b/data/themes/wood/colors.xml
@@ -48,6 +48,8 @@
<color id="SERVER_VERSION_NOT_SUPPORTED" color="#DC0000" />
<color id="WARNING" color="#FF0000" />
<color id="PLAYER_ADVANCED" color="#005000" />
+ <color id="BUBBLE_NAME" color="#ffffff" />
+ <color id="BUBBLE_TEXT" color="#ffffff" />
<color id="RED" color="#ff0000" />
<color id="GREEN" color="#009000" />
diff --git a/src/being.cpp b/src/being.cpp
index eddf44991..892be44b1 100644
--- a/src/being.cpp
+++ b/src/being.cpp
@@ -1477,7 +1477,7 @@ void Being::drawSpeech(int offsetX, int offsetY)
delete mText;
mText = nullptr;
- mSpeechBubble->setCaption(isShowName ? mName : "", mTextColor);
+ mSpeechBubble->setCaption(isShowName ? mName : "");
mSpeechBubble->setText(mSpeech, isShowName);
mSpeechBubble->setPosition(px - (mSpeechBubble->getWidth() / 2),
diff --git a/src/gui/speechbubble.cpp b/src/gui/speechbubble.cpp
index 970b18ddb..ff20603ce 100644
--- a/src/gui/speechbubble.cpp
+++ b/src/gui/speechbubble.cpp
@@ -49,7 +49,7 @@ SpeechBubble::SpeechBubble():
mSpeechBox = new TextBox;
mSpeechBox->setEditable(false);
mSpeechBox->setOpaque(false);
- mSpeechBox->setTextColor(&Theme::getThemeColor(Theme::CHAT));
+ mSpeechBox->setTextColor(&Theme::getThemeColor(Theme::BUBBLE_TEXT));
add(mCaption);
add(mSpeechBox);
@@ -67,7 +67,7 @@ void SpeechBubble::setText(const std::string &text, bool showName)
if (text == mText && (mCaption->getWidth() <= mSpeechBox->getMinWidth()))
return;
- mSpeechBox->setTextColor(&Theme::getThemeColor(Theme::TEXT));
+ mSpeechBox->setTextColor(&Theme::getThemeColor(Theme::BUBBLE_TEXT));
int width = mCaption->getWidth() + 2 * getPadding();
mSpeechBox->setTextWrapped(text, 130 > width ? 130 : width);
diff --git a/src/gui/speechbubble.h b/src/gui/speechbubble.h
index 2f93cbd77..0208941c4 100644
--- a/src/gui/speechbubble.h
+++ b/src/gui/speechbubble.h
@@ -48,7 +48,7 @@ class SpeechBubble : public Popup
*/
void setCaption(const std::string &name,
const gcn::Color *color =
- &Theme::getThemeColor(Theme::TEXT));
+ &Theme::getThemeColor(Theme::BUBBLE_NAME));
/**
* Sets the text to be displayed.
diff --git a/src/gui/theme.cpp b/src/gui/theme.cpp
index 108d736cd..1ec40b3ad 100644
--- a/src/gui/theme.cpp
+++ b/src/gui/theme.cpp
@@ -689,6 +689,8 @@ static int readColorType(const std::string &type)
"WARNING",
"CHARM",
"PLAYER_ADVANCED",
+ "BUBBLE_NAME",
+ "BUBBLE_TEXT",
"RED",
"GREEN",
"BLUE",
diff --git a/src/gui/theme.h b/src/gui/theme.h
index 56c0c57c7..1cf8d9aa6 100644
--- a/src/gui/theme.h
+++ b/src/gui/theme.h
@@ -201,6 +201,8 @@ class Theme : public Palette, public ConfigListener
WARNING,
CHARM,
PLAYER_ADVANCED,
+ BUBBLE_NAME,
+ BUBBLE_TEXT,
RED,
GREEN,
BLUE,