clickarea.h

00001 /*
00002  * Copyright (C) 2003 Hans Karlsson <karlsson.h@home.se>
00003  * Copyright (C) 2003-2004 Adam Geitgey <adam@rootnode.org>
00004  * Copyright (c) 2005 Ryan Nickell <p0z3r@earthlink.net>
00005  *
00006  * This file is part of SuperKaramba.
00007  *
00008  *  SuperKaramba is free software; you can redistribute it and/or modify
00009  *  it under the terms of the GNU General Public License as published by
00010  *  the Free Software Foundation; either version 2 of the License, or
00011  *  (at your option) any later version.
00012  *
00013  *  SuperKaramba is distributed in the hope that it will be useful,
00014  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  *  GNU General Public License for more details.
00017  *
00018  *  You should have received a copy of the GNU General Public License
00019  *  along with SuperKaramba; if not, write to the Free Software
00020  *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
00021  ****************************************************************************/
00022 #ifndef CLICKAREA_H
00023 #define CLICKAREA_H
00024 
00025 #include <qstring.h>
00026 #include <qrect.h>
00027 #include <qevent.h>
00028 #include <qregexp.h>
00029 
00030 #include <kprocess.h>
00031 #include <kprocio.h>
00032 #include <krun.h>
00033 
00034 #include <meter.h>
00035 #include "clickable.h"
00040 class ClickArea : public Meter
00041 {
00042     Q_OBJECT
00043 public:
00044     ClickArea(karamba* k, int x, int y, int w, int h );
00045 
00046     ~ClickArea();
00047 
00048     virtual bool click( QMouseEvent* );
00049     void setOnClick( QString );
00050     void setServiceOnClick( QString , QString, QString);
00051     void setOnMiddleClick( QString );
00052 
00053 
00054     QRect getRectangle();
00055 
00056     void mUpdate( QPainter* );
00057     void setValue( int );
00058     void setValue( QString );
00059 
00060     QRect rect;
00061     QString onClick;
00062     QString svc_onClick;
00063     QString svc_name;
00064     QString svc_icon;
00065     QString onMiddleClick;
00066     QString value;
00067 };
00068 
00069 #endif
KDE Home | KDE Accessibility Home | Description of Access Keys