Unsolved Using Colour Emojis as a substitution font in Windows
-
Hi SGaist,
Thank your for your reply.
Currently using Windows 10 + Qt 5.8 but I will check with 5.10 as well.
Here is a code sample demonstrating the issue:QApplication app(argc, argv); QWidget *mainWindow = new QWidget(); QLayout *layout = new QVBoxLayout(); QLabel *widget1 = new QLabel(); QLabel *widget2 = new QLabel(); QLabel *widget3 = new QLabel(); QFont::insertSubstitution(QApplication::font().family(), "Segoe UI Emoji"); widget1->setText("B/W Emoji \xF0\x9F\x92\xA4"); widget1->setFont(QFont("Sans Serif")); widget2->setText("Color Emoji \xF0\x9F\x92\xA4"); widget2->setFont(QFont("Segoe UI Emoji")); widget3->setText("Should be Color Emoji \xF0\x9F\x92\xA4"); layout->addWidget(widget1); layout->addWidget(widget2); layout->addWidget(widget3); mainWindow->setLayout(layout); mainWindow->show(); return app.exec();
-
Tried with Qt 5.10 and getting the same result.
Here is a screen grab of the code above: -
How did you install that font in your system ?
-
@SGaist
It is part of windows 10, a native font installed with windows.
Currently on Windows 10 build 1709. -
Strange, it sounded like QTBUG-57717 but it should work.
-
Do you think I should file a bug report for this?
-
If you can't find anything else on the bug report system then yes.
Can you check with the latest test version of 5.11 before doing that ?
-
Just tried 5.11 beta and still there.
I will check the bugs again and then report.
Thank you for your help @SGaist -
@boring32 In the above example, have you tried using emoji on win7? Why does the use of emoji color on win7 turn black and white?
-
I wanted to report that when I use 5.9.4 MinGW the color emoji shows up as BW but when I use 5.9.4 MSVC2017 the color emoji shows up as color. Is there anything I can do to get MinGW to work? Same in 5.11.
I'm using a blank project with a single color emoji in the screen.
If I compile with MSVC2017 then it shows up in color.