src/ui/canvas.cpp

changeset 113
c0d064521ee0
parent 112
5760cbb32bc0
child 115
ed884a2fb009
equal deleted inserted replaced
112:5760cbb32bc0 113:c0d064521ee0
192 position += QPointF{static_cast<qreal>(-fontMetrics.horizontalAdvance(text)), 0}; 192 position += QPointF{static_cast<qreal>(-fontMetrics.horizontalAdvance(text)), 0};
193 break; 193 break;
194 } 194 }
195 painter.drawText(position, text); 195 painter.drawText(position, text);
196 }; 196 };
197 const QRectF box { 197 const QRectF box {QPointF{0, 0}, sizeToSizeF(this->size())};
198 QPointF{0, 0},
199 QPointF{static_cast<qreal>(this->width()), static_cast<qreal>(this->height())}
200 };
201 const QPointF p1 = this->modelToScreenCoordinates(glm::vec3{0, 0, 0}); 198 const QPointF p1 = this->modelToScreenCoordinates(glm::vec3{0, 0, 0});
202 199
203 static const struct 200 static const struct
204 { 201 {
205 QString text; 202 QString text;

mercurial