summaryrefslogtreecommitdiff
path: root/displaymessage.c
diff options
context:
space:
mode:
authorlouis <louis.braun@gmx.de>2013-09-13 17:10:58 +0200
committerlouis <louis.braun@gmx.de>2013-09-13 17:10:58 +0200
commit5dbc46aaba992f429c05601a3f97e3d5e7a98d87 (patch)
treee2e62d13e92a35f481f5d50a46616f291966f977 /displaymessage.c
parent337cc43e400a06e66292943a0da038fa79f8c165 (diff)
downloadskin-nopacity-5dbc46aaba992f429c05601a3f97e3d5e7a98d87.tar.gz
skin-nopacity-5dbc46aaba992f429c05601a3f97e3d5e7a98d87.tar.bz2
introduced dedicated theme font colors for different message types and different buttons (closes Feature 1462)
Diffstat (limited to 'displaymessage.c')
-rw-r--r--displaymessage.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/displaymessage.c b/displaymessage.c
index 3ee1765..e44e5a0 100644
--- a/displaymessage.c
+++ b/displaymessage.c
@@ -30,18 +30,23 @@ cNopacityDisplayMessage::~cNopacityDisplayMessage() {
void cNopacityDisplayMessage::SetMessage(eMessageType Type, const char *Text) {
tColor col = Theme.Color(clrMessageStatus);
+ tColor colFont = Theme.Color(clrMessageFontStatus);
switch (Type) {
case mtStatus:
col = Theme.Color(clrMessageStatus);
+ colFont = Theme.Color(clrMessageFontStatus);
break;
case mtInfo:
col = Theme.Color(clrMessageInfo);
+ colFont = Theme.Color(clrMessageFontInfo);
break;
case mtWarning:
col = Theme.Color(clrMessageWarning);
+ colFont = Theme.Color(clrMessageFontWarning);
break;
case mtError:
col = Theme.Color(clrMessageError);
+ colFont = Theme.Color(clrMessageFontError);
break;
}
pixmapBackground->Fill(clrBlack);
@@ -52,7 +57,7 @@ void cNopacityDisplayMessage::SetMessage(eMessageType Type, const char *Text) {
pixmap->DrawImage(cPoint(1, 1), imgLoader.GetImage());
}
int textWidth = font->Width(Text);
- pixmap->DrawText(cPoint((width - textWidth) / 2, (height - font->Height()) / 2), Text, Theme.Color(clrMessageFont), (config.doBlending)?clrTransparent:col, font);
+ pixmap->DrawText(cPoint((width - textWidth) / 2, (height - font->Height()) / 2), Text, colFont, (config.doBlending)?clrTransparent:col, font);
if (config.messageFadeTime)
Start();
}