17 #ifndef QGSCOMPOSERLABEL_H
18 #define QGSCOMPOSERLABEL_H
40 void paint( QPainter* painter,
const QStyleOptionGraphicsItem* itemStyle, QWidget* pWidget );
43 void adjustSizeToText();
45 QString
text() {
return mText; }
46 void setText(
const QString& text );
53 QString displayText()
const;
56 void setExpressionContext(
QgsFeature* feature,
QgsVectorLayer* layer, QMap<QString, QVariant> substitutions = ( QMap<QString, QVariant>() ) );
59 void setFont(
const QFont& f );
63 Qt::AlignmentFlag
vAlign()
const {
return mVAlignment; }
67 Qt::AlignmentFlag
hAlign()
const {
return mHAlignment; }
72 void setHAlign( Qt::AlignmentFlag a ) {mHAlignment = a;}
77 void setVAlign( Qt::AlignmentFlag a ) {mVAlignment = a;}
94 bool writeXML( QDomElement& elem, QDomDocument & doc )
const;
100 bool readXML(
const QDomElement& itemElem,
const QDomDocument& doc );
103 void loadingHtmlFinished(
bool );
112 double htmlUnitsToMM();
116 void itemShiftAdjustSize(
double newWidth,
double newHeight,
double& xShift,
double& yShift )
const;
134 void replaceDateText( QString& text )
const;