如何在QML中使用Roboto Thin字体 [英] How to use roboto thin font in qml

查看:265
本文介绍了如何在QML中使用Roboto Thin字体的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在Linux的QML中使用自动精简字体.我在ubuntu上安装了粗体,细体和浅色字体. Openoffice等其他程序仅向我显示了roboto. 我如何在qml中使用轻薄的轻薄机械手?

I am trying to use robot thin font in QML in Linux.I have install bold,thin and light fonts on ubuntu. Other programs like openoffice shows me only roboto. How do i get to use roboto thin or light in qml?

推荐答案

您可以将字体文件与应用程序捆绑在一起,然后使用

You can bundle the font files with your application and then use FontLoader component to load the version you want and use these in QML.

QtQuick 1.0中也存在此组件,因为它在Qt 4.7中引入了

This component also exist for QtQuick 1.0 as it was introduced in Qt 4.7 FontLoader

这篇关于如何在QML中使用Roboto Thin字体的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆