Show invite menu in wlm chat window immediately
[kdenetwork.git] / kopete / libkopete / ui / webcamwidget.h
blob7042e94e82a52fb2076d346dce1b62a1f01f35d5
1 /*
2 webcamwidget.h - A simple widget for displaying webcam frames
4 Copyright (c) 2006 by Gustavo Pichorim Boiko <gustavo.boiko@kdemail.net>
5 Kopete (c) 2002-2006 by the Kopete developers <kopete-devel@kde.org>
7 *************************************************************************
8 * *
9 * This program is free software; you can redistribute it and/or modify *
10 * it under the terms of the GNU General Public License as published by *
11 * the Free Software Foundation; either version 2 of the License, or *
12 * (at your option) any later version. *
13 * *
14 *************************************************************************
17 #ifndef WEBCAMWIDGET_H
18 #define WEBCAMWIDGET_H
20 #include <qwidget.h>
21 #include <qpixmap.h>
22 #include <qstring.h>
24 #include "kopete_export.h"
26 namespace Kopete
28 /**
29 * A simple widget to display webcam frames.
31 class KOPETE_EXPORT WebcamWidget : public QWidget
33 Q_OBJECT
34 public:
35 /**
36 * @brief WebcamWidget constructor.
37 * @param parent The parent widget of this widget
39 WebcamWidget(QWidget* parent = 0);
40 ~WebcamWidget();
42 /**
43 * @brief Updates the frame being displayed in the widget
44 * @param pixmap The frame to be displayed
46 void updatePixmap(const QPixmap& pixmap);
48 /**
49 * @brief Clear the widget
51 void clear();
53 /**
54 * @brief Set a text to be displayed in the widget
55 * @param text The text to be displayed
57 void setText(const QString& text);
58 protected slots:
59 void paintEvent(QPaintEvent* event);
61 private:
62 QPixmap mPixmap;
63 QString mText;
66 } // end namespace Kopete
67 #endif