libkdegames/libkdegamesprivate
kchatbase.cpp
Go to the documentation of this file.
76 KChatBase::KChatBase(QWidget* parent, KChatBaseModel* model, KChatBaseItemDelegate* delegate, bool noComboBox) : QFrame(parent)
138 kDebug(10500) << "custom menu has been requested at position="<<pos<<". Implement handler at subclass if you need it.";
void customContextMenuRequested(const QPoint &pos)
Definition: kchatbase.h:95
QFont systemNameFont() const
Same as systemNameFont but applies only to system messages.
Definition: kchatbase.cpp:321
const QModelIndex indexAt(const QPoint &pos) const
Returns the model index of the message at the viewport coordinates point.
Definition: kchatbase.cpp:131
void setMessageFont(const QFont &font)
Set the font that used used for the message part of a message.
Definition: kchatbase.cpp:336
void changeSendingEntry(const QString &text, int id)
This changes a combo box entry.
Definition: kchatbase.cpp:212
void setSystemNameFont(const QFont &font)
Same as setNameFont but applies only to system messages.
Definition: kchatbase.cpp:346
bool addSendingEntry(const QString &text, int id)
Adds a new entry in the combo box.
Definition: kchatbase.cpp:154
void removeSendingEntry(int id)
Removes the entry with the ID id from the combo box.
Definition: kchatbase.cpp:200
virtual void returnPressed(const QString &text)=0
This is called whenever the user pushed return ie wants to send a message.
void setMinimumWidth(int minw)
void setCompletionMode(KGlobalSettings::Completion mode)
See KLineEdit::setCompletionMode.
Definition: kchatbase.cpp:269
A delegate (see the Qt Model/View module for details) to paint the lines of the KChatBase list model ...
Definition: kchatbaseitemdelegate.h:37
QFont nameFont() const
This font should be used for the name (the "from: " part) of a message.
Definition: kchatbase.cpp:311
void setSystemMessageFont(const QFont &font)
Same as setMessageFont but applies only to system messages.
Definition: kchatbase.cpp:351
void addSpacing(int size)
KChatBase(QWidget *parent, KChatBaseModel *model=0, KChatBaseItemDelegate *delegate=0, bool noComboBox=false)
Definition: kchatbase.cpp:76
void addWidget(QWidget *widget, int stretch, QFlags< Qt::AlignmentFlag > alignment)
virtual void addMessage(const QString &fromName, const QString &text)
Add a text in the listbox.
Definition: kchatbase.cpp:361
virtual void addSystemMessage(const QString &fromName, const QString &text)
This works just like addMessage but adds a system message.
Definition: kchatbase.cpp:366
bool insertSendingEntry(const QString &text, int id, int index=-1)
Inserts a new entry in the combo box.
Definition: kchatbase.cpp:163
virtual void readConfig(KConfig *conf=0)
Read the configuration from a KConfig object.
Definition: kchatbase.cpp:280
void setNameFont(const QFont &font)
Set the font that used used for the name part of a message.
Definition: kchatbase.cpp:331
void setMaxItems(int maxItems)
Set the maximum number of items in the list.
Definition: kchatbase.cpp:293
int length() const
void setMinimumHeight(int minh)
void setSystemBothFont(const QFont &font)
Same as setBothFont but applies only to system messages.
Definition: kchatbase.cpp:356
void setBothFont(const QFont &font)
This sets both - nameFont and messageFont to font.
Definition: kchatbase.cpp:341
QFont systemMessageFont() const
Same as systemMessageFont but applies only to system messages.
Definition: kchatbase.cpp:326
virtual QString comboBoxItem(const QString &name) const
Replace to customize the combo box.
Definition: kchatbase.cpp:258
bool connect(const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
The model used to store messages displayed in the chat dialog messages list.
Definition: kchatbasemodel.h:76
virtual void saveConfig(KConfig *conf=0)
Save the configuration of the dialog to a KConfig object.
Definition: kchatbase.cpp:272
void addLayout(QLayout *layout, int stretch)
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:18:50 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:18:50 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.