1 /***************************************************************************
2 * Copyright (C) 2005/06 by The Quassel 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) any later version. *
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 ***************************************************************************/
27 #include "ui_bufferwidget.h"
34 class Buffer : public QObject {
38 Buffer(QString network, QString buffer);
41 bool isActive() { return active; }
46 void userInput(QString, QString, QString);
47 void nickListChanged(QStringList);
50 void setActive(bool active = true);
51 void displayMsg(Message);
52 //void recvStatusMsg(QString msg);
53 void setTopic(QString);
54 //void setNicks(QStringList);
55 void addNick(QString nick, VarMap props);
56 void renameNick(QString oldnick, QString newnick);
57 void removeNick(QString nick);
58 void updateNick(QString nick, VarMap props);
59 void setOwnNick(QString nick);
61 QWidget * showWidget(QWidget *parent = 0);
67 void userInput(QString);
75 QString networkName, bufferName;
77 QList<Message> contents;
80 class BufferWidget : public QWidget {
84 BufferWidget(QString netname, QString bufname, bool active, QString ownNick, QList<Message> contents, QWidget *parent = 0);
86 void setActive(bool act = true);
88 void userInput(QString);
91 void displayMsg(Message);
92 void updateNickList(VarMap nicks);
93 void setOwnNick(QString ownNick);
94 void setTopic(QString topic);
95 void renderContents();
100 void itemExpansionChanged(QTreeWidgetItem *);
106 QList<Message> contents;
108 QString stdCol, errorCol, noticeCol, joinCol, quitCol, partCol, kickCol, serverCol, nickCol, inactiveCol;
113 bool opsExpanded, voicedExpanded, usersExpanded;
115 QString htmlFromMsg(Message);