mirror of
https://github.com/fralx/LimeReport.git
synced 2024-12-25 17:14:40 +03:00
38 lines
984 B
C++
38 lines
984 B
C++
|
#include "lrtearoffband.h"
|
||
|
#include "lrdesignelementsfactory.h"
|
||
|
#include "lrglobal.h"
|
||
|
|
||
|
const QString xmlTag ="TearOffBand";
|
||
|
|
||
|
namespace{
|
||
|
LimeReport::BaseDesignIntf * createBand(QObject* owner, LimeReport::BaseDesignIntf* parent){
|
||
|
return new LimeReport::TearOffBand(owner,parent);
|
||
|
}
|
||
|
bool registred = LimeReport::DesignElementsFactory::instance().registerCreator(
|
||
|
xmlTag,
|
||
|
LimeReport::ItemAttribs(QObject::tr("Tear-off Band"),LimeReport::Const::bandTAG),
|
||
|
createBand
|
||
|
);
|
||
|
}
|
||
|
|
||
|
namespace LimeReport{
|
||
|
|
||
|
TearOffBand::TearOffBand(QObject *owner, QGraphicsItem *parent)
|
||
|
:BandDesignIntf(LimeReport::BandDesignIntf::TearOffBand,xmlTag,owner,parent)
|
||
|
{
|
||
|
setBandTypeText(tr("Tear-off Band"));
|
||
|
setMarkerColor(bandColor());
|
||
|
}
|
||
|
|
||
|
BaseDesignIntf *TearOffBand::createSameTypeItem(QObject *owner, QGraphicsItem *parent)
|
||
|
{
|
||
|
return new TearOffBand(owner,parent);
|
||
|
}
|
||
|
|
||
|
QColor TearOffBand::bandColor() const
|
||
|
{
|
||
|
return QColor(200,200,200);
|
||
|
}
|
||
|
|
||
|
} // namedpace LimeReport
|