返回介绍

QFontManager Class

发布于 2019-10-04 15:00:24 字数 1864 浏览 819 评论 0 收藏 0

The QFontManager class implements font management in Qt/Embedded. More...

#include <qfontmanager_qws.h>

List of all member functions.

Public Members

  • QFontManager ()
  • ~QFontManager ()
  • QDiskFont * get ( constQFontDef&f )

Static Public Members

  • void initialize ()
  • void cleanup ()

Detailed Description

The QFontManager class implements font management in Qt/Embedded.

There is one and only one QFontManager per Qt/Embedded application (qt_fontmanager is a global variable that points to it). It keeps a list of font factories, a cache of rendered fonts and a list of fonts available on disk. QFontManager is called when a new font needs to be rendered from a Freetype-compatible or BDF font on disk; this only happens if there isn't an appropriate QPF font already available.

See also Qt/Embedded.


Member Function Documentation

QFontManager::QFontManager ()

Creates a font manager. This method reads in the font definition file from $QTDIR/lib/fonts/fontdir (or /usr/local/qt-embedded/lib/fonts/fontdir if QTDIR isn't defined) and creates a list of QDiskFonts to hold the information in the file. It also constructs any defined font factories.

QFontManager::~QFontManager ()

Destroys the QFontManager and sets qt_fontmanager to 0.

void QFontManager::cleanup () [static]

Destroys the font manager

QDiskFont * QFontManager::get ( constQFontDef&f )

Returns the QDiskFont that best matches f, based on family, weight, italicity and font size.

void QFontManager::initialize () [static]

Creates a new QFontManager and points qt_fontmanager to it

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文