[Interest] Freetype and color fonts

Illogica Studio illogica.software at gmail.com
Fri Mar 25 15:04:35 CET 2016


Hey,
thanks for your reply.
I'm using Qt5.6. I create a small QtQuick project, in a subfolder font/ I
put a bunch of fonts from Google downloaded from
https://www.google.com/get/noto/
This is my source file:

import QtQuick 2.6

import QtQuick.Window 2.2


Window {

    visible: true

    height: 480

    width: 640


    FontLoader{

        id: fontTest

        //source: "font/NotoSerif-Regular.ttf" //works

        //source: "font/NotoSans-Italic.ttf"   //works

        source: "font/NotoColorEmoji.ttf"    // does NOT work

    }


    Text {

        text: qsTr("Hello World")

        font.pointSize: 35

        anchors.centerIn: parent

        font.family: fontTest.name

    }

}


In the fontTest font loader component I commented out a couple of fonts
that work.
When I try to load NotoColorEmoji.ttf the only error I obtain is
QML FontLoader: Cannot load font:
"file:///E:/prod/qt/FontTest/font/NotoColorEmoji.ttf"


Loris

2016-03-25 14:04 GMT+01:00 Robert Buchinger <robert_buchinger at gmx.at>:

> On Friday, March 25, 2016 1:45:30 PM CET Illogica Studio wrote:
> > bump
> >
> > Maybe I'm saying something incredibly stupid here? Please feel free to
> let
> > me know!
> >
> > 2016-03-22 8:17 GMT+01:00 Illogica Studio <illogica.software at gmail.com>:
> > > Hi all,
> > >
> > >
> > > I've been trying to use Google color emoji font
> > > https://www.google.com/get/noto/#emoji-qaae-color with no luck.
> > > When I try to load the font using FontLoader I obtain an error:
> > > QML FontLoader: Cannot load font:
> > > "file:///E:/Qt/FontTest/NotoColorEmoji.ttf"
> > > but the font is in place, I can successfully load other fonts in the
> same
> > > folder.
> > > According to http://www.freetype.org/ , Freetype is supposed to
> support
> > > Google color fonts since version 2.5 (3 years ago).
> > >
> > > What am I missing?
> Hi,
> What versio of QT are you using?
>
> Can you post the piece of code how you try to add the font to your
> application?
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20160325/042073f1/attachment.html>


More information about the Interest mailing list