1 /***************************************************************************
2 * Copyright (C) 2005-07 by the Quassel IRC Team *
3 * devel@quassel-irc.org *
5 * This program is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation; either version 2 of the License, or *
8 * (at your option) version 3. *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program; if not, write to the *
17 * Free Software Foundation, Inc., *
18 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
19 ***************************************************************************/
21 #include "qtopiauistyle.h"
23 QtopiaUiStyle::QtopiaUiStyle() : UiStyle() {
26 def.setForeground(QBrush("#000000"));
27 def.setFont(QFont("Verdana",5));
30 // We need to just set our internal formats; everything else is done by the base class...
32 // Internal message formats
34 QTextCharFormat plainMsg;
35 plainMsg.setForeground(QBrush("#000000"));
36 setFormat(PlainMsg, plainMsg);
38 QTextCharFormat notice;
39 notice.setForeground(QBrush("#000080"));
40 setFormat(NoticeMsg, notice);
42 QTextCharFormat server;
43 server.setForeground(QBrush("#000080"));
44 setFormat(ServerMsg, server);
46 QTextCharFormat error;
47 error.setForeground(QBrush("#ff0000"));
48 setFormat(ErrorMsg, error);
51 join.setForeground(QBrush("#008000"));
52 setFormat(JoinMsg, join);
55 part.setForeground(QBrush("#ff0000"));
56 setFormat(PartMsg, part);
59 quit.setForeground(QBrush("#ff0000"));
60 setFormat(QuitMsg, quit);
63 kick.setForeground(QBrush("#ff0000"));
64 setFormat(KickMsg, kick);
67 nren.setForeground(QBrush("#6a5acd"));
68 setFormat(RenameMsg, nren);
71 mode.setForeground(QBrush("#4682b4"));
72 setFormat(ModeMsg, mode);
74 QTextCharFormat action;
75 action.setFontItalic(true);
76 action.setForeground(QBrush("#8b008b"));
77 setFormat(ActionMsg, action);
79 // Internal message element formats
81 ts.setForeground(QBrush("#808080"));
82 setFormat(Timestamp, ts);
84 QTextCharFormat sender;
85 sender.setAnchor(true);
86 sender.setForeground(QBrush("#000080"));
87 setFormat(Sender, sender);
91 nick.setFontWeight(QFont::Bold);
92 setFormat(Nick, nick);
94 QTextCharFormat hostmask;
95 hostmask.setFontItalic(true);
96 setFormat(Hostmask, hostmask);
98 QTextCharFormat channel;
99 channel.setAnchor(true);
100 channel.setFontWeight(QFont::Bold);
101 setFormat(ChannelName, channel);
103 QTextCharFormat flags;
104 flags.setFontWeight(QFont::Bold);
105 setFormat(ModeFlags, flags);
108 url.setFontUnderline(true);
114 QtopiaUiStyle::~QtopiaUiStyle() {}