201 break; |
201 break; |
202 case geom::RectangleSide::Bottom: |
202 case geom::RectangleSide::Bottom: |
203 position += QPointF{0, static_cast<qreal>(-fontMetrics.descent())}; |
203 position += QPointF{0, static_cast<qreal>(-fontMetrics.descent())}; |
204 break; |
204 break; |
205 case geom::RectangleSide::Right: |
205 case geom::RectangleSide::Right: |
206 position += QPointF{static_cast<qreal>(-fontMetrics.width(text)), 0}; |
206 position += QPointF{static_cast<qreal>(-fontMetrics.horizontalAdvance(text)), 0}; |
207 break; |
207 break; |
208 } |
208 } |
209 painter.drawText(position, text); |
209 painter.drawText(position, text); |
210 }; |
210 }; |
211 const QRectF box { |
211 const QRectF box { |