0
0
mirror of https://github.com/fralx/LimeReport.git synced 2025-10-23 02:47:28 +03:00

New scale method has been added

This commit is contained in:
fralx
2020-04-27 11:52:25 +03:00
parent e623978281
commit 318af3b221
40 changed files with 558 additions and 273 deletions

View File

@@ -218,10 +218,10 @@ void AbstractLayout::collectionLoadFinished(const QString& collectionName)
}
}
void AbstractLayout::objectLoadFinished()
void AbstractLayout::finishLoading()
{
layoutMarker()->setHeight(height());
LayoutDesignIntf::objectLoadFinished();
LayoutDesignIntf::finishLoading();
}
bool AbstractLayout::isNeedUpdateSize(RenderPass pass) const

View File

@@ -39,7 +39,7 @@ public:
int childrenCount();
int layoutSpacing() const;
void setLayoutSpacing(int layoutSpacing);
qreal layoutSpacingMM(){ return m_layoutSpacing * Const::mmFACTOR;}
qreal layoutSpacingMM(){ return m_layoutSpacing * ppm();}
protected:
void beforeDelete();
void childAddedEvent(BaseDesignIntf *child);
@@ -47,7 +47,7 @@ protected:
void initMode(ItemMode mode);
void setBorderLinesFlags(BorderLines flags);
void collectionLoadFinished(const QString &collectionName);
void objectLoadFinished();
void finishLoading();
bool isNeedUpdateSize(RenderPass pass) const;
QVariant itemChange(GraphicsItemChange change, const QVariant &value);
void updateItemSize(DataSourceManager* dataManager, RenderPass pass, int maxHeight);

View File

@@ -47,7 +47,7 @@ LimeReport::BaseDesignIntf *createHLayout(QObject *owner, LimeReport::BaseDesign
}
bool VARIABLE_IS_NOT_USED registred = LimeReport::DesignElementsFactory::instance().registerCreator(
xmlTag,
LimeReport::ItemAttribs(QObject::tr("HLayout"), LimeReport::Const::bandTAG),
LimeReport::ItemAttribs(QObject::tr("HLayout"), LimeReport::Const::BAND_TAG),
createHLayout
);
}

View File

@@ -160,7 +160,6 @@ void TextItem::paint(QPainter* painter, const QStyleOptionGraphicsItem* style, Q
Q_UNUSED(widget);
Q_UNUSED(style);
TextPtr text = textDocument();
painter->save();
@@ -975,9 +974,9 @@ BaseDesignIntf *TextItem::cloneEmpty(int height, QObject *owner, QGraphicsItem *
return empty;
}
void TextItem::objectLoadFinished()
void TextItem::finishLoading()
{
ItemDesignIntf::objectLoadFinished();
ItemDesignIntf::finishLoading();
// if (itemMode() == DesignMode || !isNeedExpandContent()){
// if (autoHeight() && autoWidth())
// initTextSizes();

View File

@@ -121,7 +121,7 @@ public:
BaseDesignIntf* cloneBottomPart(int height, QObject *owner, QGraphicsItem *parent);
BaseDesignIntf* createSameTypeItem(QObject* owner=0, QGraphicsItem* parent=0);
BaseDesignIntf* cloneEmpty(int height, QObject *owner, QGraphicsItem *parent);
void objectLoadFinished();
void finishLoading();
void setTextItemFont(QFont value);
QWidget* defaultEditor();

View File

@@ -13,7 +13,7 @@ LimeReport::BaseDesignIntf *createVLayout(QObject *owner, LimeReport::BaseDesign
}
bool VARIABLE_IS_NOT_USED registred = LimeReport::DesignElementsFactory::instance().registerCreator(
xmlTag,
LimeReport::ItemAttribs(QObject::tr("VLayout"), LimeReport::Const::bandTAG),
LimeReport::ItemAttribs(QObject::tr("VLayout"), LimeReport::Const::BAND_TAG),
createVLayout
);
}