fix text items not displayed entirely

This commit is contained in:
Maxime Gimeno 2019-05-21 13:44:23 +02:00
parent 4b66010b75
commit f08f69e745
1 changed files with 1 additions and 1 deletions

View File

@ -60,7 +60,7 @@ public :
:x(p_x), y(p_y), z(p_z),_3D(p_3D), _is_always_visible(always_visible), m_text(p_text), m_font(font), m_color(p_color)
{
QFontMetrics fm(m_font);
_width = float(fm.width(m_text));
_width = float(fm.horizontalAdvance(m_text)+2);
_height = float(fm.height());
}
//!\brief Accessor for the string