input.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef INPUT_H
00022 #define INPUT_H
00023
00024 #include <meter.h>
00025 #include <sklineedit.h>
00026
00027 #include <qpainter.h>
00028 #include <qcolor.h>
00029 #include <qlineedit.h>
00030 #include <qwidget.h>
00031 #include <qstring.h>
00032 #include <qfont.h>
00033
00034 #include "textfield.h"
00035
00036 class Input : public Meter
00037 {
00038 Q_OBJECT
00039 public:
00040 Input(karamba* k, int ix, int iy, int iw, int ih);
00041 Input();
00042
00043 ~Input();
00044
00045 void mUpdate(QPainter *p);
00046
00047 void setValue(QString text);
00048 QString getStringValue() const;
00049
00050 void setBGColor(QColor c);
00051 QColor getBGColor() const;
00052 void setColor(QColor c);
00053 QColor getColor() const;
00054 void setFontColor(QColor fontColor);
00055 QColor getFontColor() const;
00056 void setSelectionColor(QColor selectionColor);
00057 QColor getSelectionColor() const;
00058 void setSelectedTextColor(QColor selectedTextColor);
00059 QColor getSelectedTextColor() const;
00060 void setTextProps(TextField*);
00061
00062 void hide();
00063 void show();
00064
00065 void setSize(int ix, int iy, int iw, int ih);
00066 void setX(int ix);
00067 void setY(int iy);
00068 void setWidth(int iw);
00069 void setHeight(int ih);
00070
00071 void setFont(QString f);
00072 QString getFont() const;
00073 void setFontSize(int size);
00074 int getFontSize() const;
00075
00076 void setInputFocus();
00077 void clearInputFocus();
00078
00079 private:
00080 SKLineEdit *edit;
00081 QFont font;
00082 };
00083
00084 #endif
|