12Meter::Meter(karamba* k,
int ix,
int iy,
int iw,
int ih):
13 boundingBox(ix, iy, iw, ih), leftButtonAction(
""), middleButtonAction(
""),
14 rightButtonAction(
""), clickable(true), hidden(0), minValue(0), maxValue(0),
15 color(0,0,0), m_karamba(k)
19Meter::Meter(karamba* k):
20 boundingBox(0, 0, 0, 0), leftButtonAction(
""), middleButtonAction(
""),
21 rightButtonAction(
""), clickable(true), hidden(0), minValue(0), maxValue(0),
22 color(0,0,0), m_karamba(k)
30bool Meter::click(TQMouseEvent*)
35void Meter::setSize(
int ix,
int iy,
int iw,
int ih)
37 boundingBox.setRect(ix, iy, iw, ih);
41void Meter::setThemePath( TQString path )
48 return boundingBox.x();
53 return boundingBox.y();
56void Meter::setX(
int newx)
58 int temp = boundingBox.width();
59 boundingBox.setX(newx);
60 boundingBox.setWidth(temp);
63void Meter::setY(
int newy)
65 int temp = boundingBox.height();
66 boundingBox.setY(newy);
67 boundingBox.setHeight(temp);
72 return boundingBox.width();
76 return boundingBox.height();
79void Meter::setWidth(
int width)
81 boundingBox.setWidth(width);
85void Meter::setHeight(
int height)
87 boundingBox.setHeight(height);
91TQRect Meter::getBoundingBox()
96void Meter::setEnabled(
bool e)
101bool Meter::isEnabled()
106bool Meter::insideActiveArea(
int x,
int y)
108 return boundingBox.contains(x, y) && clickable;