This is strange but maybe the new font doesn't have that particular size.
If the pointSize is the only thing that changes with the family you could "remember" it as well
currentfont = ui_vp_message->font();
const int pointSize = currentFont.pointSize();
currentFont.setFamily(...);
currentFont.setPointSize(pointSize);
currentfont = ui_vp_message->font();
const int pointSize = currentFont.pointSize();
currentFont.setFamily(...);
currentFont.setPointSize(pointSize);
To copy to clipboard, switch view to plain text mode
Cheers,
_
Bookmarks