Use QFontMetricsF to get measurements, e.g. If the window system provides an exact match exactMatch() returns true. The attributes of the font that is actually used are retrievable from a QFontInfo object. Qt will use the font with the specified attributes, or if no matching font exists, Qt will use the closest matching installed font. When you create a QFont object you specify various attributes that you want the font to have. QFont can be regarded as a query for one or more fonts on the system. SetStyleHint(QFont::StyleHint hint, QFont::StyleStrategy strategy = PreferDefault) SetLetterSpacing(QFont::SpacingType type, qreal spacing) SetHintingPreference(QFont::HintingPreference hintingPreference) SetFamilies(const QStringList & families) SetCapitalization(QFont::Capitalization caps) QFont(const QString & family, int pointSize = -1, int weight = -1, bool italic = false) QFont(const QStringList & families, int pointSize = -1, int weight = -1, bool italic = false) QFont(const QFont & font, const QPaintDevice * pd)
0 Comments
Leave a Reply. |