/***************************************************************************
 * qcanvasrectanglecm.h: implementation of QCanvasRectangleCm class
 *
 * This file is part of KTabEdit, a KDE tabulature editor
 *
 * copyright (C) 2003-2007 the KTabEdit development team <mrgwen@gmail.com>
 ***************************************************************************/

/***************************************************************************
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * See the file COPYING for more information.
 ***************************************************************************/

#ifndef QCANVASRECTANGLECM_H
#define QCANVASRECTANGLECM_H

#include <QGraphicsRectItem>

#include "qcanvasitemcm.h"
#include "track/qsizecm.h"

class Cm;
class QRectCm;

class QCanvasRectangleCm : public QGraphicsRectItem, public QCanvasItemCm {
public:
	QCanvasRectangleCm();
	QCanvasRectangleCm(const QRectCm& r);
	QCanvasRectangleCm(const Cm& x, const Cm& y, const Cm& width,const Cm& height, QGraphicsItem* canvas);
	~QCanvasRectangleCm();
	
	void setSize(const QSizeCm& size);
	void setSizeInCm(const Cm& width, const Cm& height);
	
	void setPosFromCoord(const Cm& x, const Cm& y);
	
	/*virtual void setX(const Cm& x);
	virtual void setY(const Cm& y);
	
	virtual void move(const Cm& x, const Cm& y);*/
	virtual void moveBy(const Cm& x, const Cm& y);
private:
	QSizeCm mSize;
};

#endif
