mirror of
https://github.com/fralx/LimeReport.git
synced 2025-11-25 00:18:06 +03:00
Merge branch 'develop' into feature/CH_Private_To_Public
# Conflicts: # limereport/lrreportdesignwidget.cpp # limereport/lrreportdesignwidget.h # limereport/lrreportdesignwindow.h
This commit is contained in:
@@ -48,15 +48,29 @@ namespace LimeReport {
|
||||
class ReportEnginePrivate;
|
||||
class DataBrowser;
|
||||
class ReportDesignWindow;
|
||||
class DialogDesignerManager;
|
||||
class DialogDesigner;
|
||||
|
||||
class ReportDesignWidget : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PROPERTY(QObject* datasourcesManager READ dataManager())
|
||||
friend class ReportDesignWindow;
|
||||
public:
|
||||
enum ToolWindowType{
|
||||
WidgetBox = 1,
|
||||
ObjectInspector = 2,
|
||||
ActionEditor = 3,
|
||||
SignalSlotEditor = 4,
|
||||
PropertyEditor = 5,
|
||||
ResourceEditor = 6
|
||||
};
|
||||
enum EditorTabType{
|
||||
Page,
|
||||
Dialog,
|
||||
Script
|
||||
};
|
||||
ReportDesignWidget(ReportEngine* report, QMainWindow *mainWindow, QWidget *parent = 0);
|
||||
~ReportDesignWidget();
|
||||
// static ReportDesignWidget* instance(){return m_instance;}
|
||||
void createStartPage();
|
||||
void clear();
|
||||
DataSourceManager* dataManager();
|
||||
@@ -76,7 +90,6 @@ public:
|
||||
QList<QGraphicsItem *> selectedItems();
|
||||
QStringList datasourcesNames();
|
||||
void scale( qreal sx, qreal sy);
|
||||
// void setDatabrowser(DataBrowser* databrowser);
|
||||
ReportEnginePrivate* report(){return m_report;}
|
||||
QString reportFileName();
|
||||
bool isNeedToSave();
|
||||
@@ -88,9 +101,17 @@ public:
|
||||
bool useGrid(){ return m_useGrid;}
|
||||
bool useMagnet() const;
|
||||
void setUseMagnet(bool useMagnet);
|
||||
|
||||
EditorTabType activeTabType();
|
||||
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
||||
void initDialogDesignerToolBar(QToolBar* toolBar);
|
||||
void updateDialogs();
|
||||
DialogDesignerManager *dialogDesignerManager() const;
|
||||
QString activeDialogName();
|
||||
DialogDesigner* activeDialogPage();
|
||||
QWidget* toolWindow(ToolWindowType windowType);
|
||||
#endif
|
||||
public slots:
|
||||
void saveToFile(const QString&);
|
||||
bool saveToFile(const QString&);
|
||||
bool save();
|
||||
bool loadFromFile(const QString&);
|
||||
void deleteSelectedItems();
|
||||
@@ -121,13 +142,21 @@ public slots:
|
||||
void printReport();
|
||||
void addPage();
|
||||
void deleteCurrentPage();
|
||||
void slotPagesLoadFinished();
|
||||
void slotDialogDeleted(QString dialogName);
|
||||
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
||||
void addNewDialog();
|
||||
#endif
|
||||
private slots:
|
||||
void slotItemSelected(LimeReport::BaseDesignIntf *item);
|
||||
void slotSelectionChanged();
|
||||
void slotPagesLoadFinished();
|
||||
void slotDatasourceCollectionLoaded(const QString&);
|
||||
void slotSceneRectChanged(QRectF);
|
||||
void slotCurrentTabChanged(int index);
|
||||
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
||||
void slotDialogChanged(QString);
|
||||
void slotDialogNameChanged(QString oldName, QString newName);
|
||||
#endif
|
||||
signals:
|
||||
void insertModeStarted();
|
||||
void itemInserted(LimeReport::PageDesignIntf*,QPointF,const QString&);
|
||||
@@ -148,13 +177,18 @@ signals:
|
||||
void pageDeleted();
|
||||
protected:
|
||||
void createTabs();
|
||||
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
||||
void createNewDialogTab(const QString& dialogName,const QByteArray& description);
|
||||
#endif
|
||||
private:
|
||||
bool eventFilter(QObject *target, QEvent *event);
|
||||
ReportDesignWidget(ReportEngine* report,QMainWindow *mainWindow,QWidget *parent = 0);
|
||||
private:
|
||||
ReportEnginePrivate* m_report;
|
||||
QGraphicsView *m_view;
|
||||
QTextEdit* m_scriptEditor;
|
||||
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
||||
DialogDesignerManager* m_dialogDesignerManager;
|
||||
#endif
|
||||
QMainWindow *m_mainWindow;
|
||||
QTabWidget* m_tabWidget;
|
||||
GraphicsViewZoomer* m_zoomer;
|
||||
@@ -163,7 +197,7 @@ private:
|
||||
int m_horizontalGridStep;
|
||||
bool m_useGrid;
|
||||
bool m_useMagnet;
|
||||
// static ReportDesignWidget* m_instance;
|
||||
bool m_dialogChanged;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user