mirror of
https://github.com/fralx/LimeReport.git
synced 2025-09-23 08:29:07 +03:00
Version 1.4 initial commit
This commit is contained in:
@@ -53,6 +53,7 @@ ColorEditor::ColorEditor(QWidget *parent) :
|
||||
setFocusProxy(m_button);
|
||||
setAutoFillBackground(true);
|
||||
setLayout(layout);
|
||||
setAutoFillBackground(true);
|
||||
connect(m_button,SIGNAL(clicked()),this,SLOT(slotClicked()));
|
||||
}
|
||||
|
||||
|
@@ -37,13 +37,17 @@ ImageEditor::ImageEditor(QWidget* parent)
|
||||
:QWidget(parent)
|
||||
{
|
||||
m_button.setIcon(QIcon(":items/ImageItem"));
|
||||
m_clearButton.setIcon(QIcon(":items/clear.png"));
|
||||
QHBoxLayout* layout = new QHBoxLayout(this);
|
||||
layout->addWidget(&m_button);
|
||||
layout->setSpacing(0);
|
||||
layout->addWidget(&m_clearButton);
|
||||
layout->setSpacing(1);
|
||||
layout->setContentsMargins(1,0,1,1);
|
||||
setLayout(layout);
|
||||
setFocusProxy(&m_button);
|
||||
setAutoFillBackground(true);
|
||||
connect(&m_button,SIGNAL(clicked()),this,SLOT(slotButtonClicked()));
|
||||
connect(&m_clearButton,SIGNAL(clicked()),this,SLOT(slotClearButtonClicked()));
|
||||
}
|
||||
|
||||
QImage ImageEditor::image()
|
||||
@@ -57,4 +61,10 @@ void ImageEditor::slotButtonClicked()
|
||||
emit editingFinished();
|
||||
}
|
||||
|
||||
} // namespace LimeReport
|
||||
void ImageEditor::slotClearButtonClicked()
|
||||
{
|
||||
m_image = QImage();
|
||||
emit editingFinished();
|
||||
}
|
||||
|
||||
} //namespace LimeReport
|
||||
|
@@ -46,8 +46,10 @@ signals:
|
||||
void editingFinished();
|
||||
private slots:
|
||||
void slotButtonClicked();
|
||||
void slotClearButtonClicked();
|
||||
private:
|
||||
QPushButton m_button;
|
||||
QPushButton m_clearButton;
|
||||
QImage m_image;
|
||||
};
|
||||
|
||||
|
@@ -88,7 +88,7 @@ namespace LimeReport{
|
||||
void setColorIndex(int propertyValue);
|
||||
void setModel(QAbstractItemModel* model){m_model=model;}
|
||||
QAbstractItemModel* model(){return m_model;}
|
||||
void setModelIndex(QModelIndex index){m_index=index;}
|
||||
void setModelIndex(const QModelIndex& index){m_index=index;}
|
||||
QModelIndex modelIndex(){return m_index;}
|
||||
bool isClass(){return m_isClass;}
|
||||
#ifdef INSPECT_BASEDESIGN
|
||||
|
Reference in New Issue
Block a user