I have an C# web application that uses the Segoe UI Emoji font to put an emoji in a PDF that is generated. I'm using a RDLC report to generate the PDF. When generating the PDF on my development PC the PDF appears correct, I get the "devil" emoji.
After deploying and running on the server the emoji is the wrong one. I believe I've tracked the problem down to different versions of the font being installed (I was wrong, this doesn't appear to be the issue after the February 2021 updates brought the font version up to 1.29).
Correct example:
Incorrect example:
On my Windows 10 (20H2) development PC the Segoe UI Emoji font is at version 1.29.
On the Windows Server 2019 (1809) the same font is at version 1.29.
The emoji giving me issues is the smiling face with horns (devil). I'm using 0x1F608 to add the character to my output using the emoji example from here.
How do you convert a single Unicode code point to a string at runtime?
https://emojipedia.org/smiling-face-with-horns/
I've been looking for a way to update the font on the server, but due to it being a protected system font I'm really struggling. I can't delete it or install the newer version by copying the font file from Windows 10 to the server.
I've been researching and trying a few things to deal with protected system fonts, making a registry change to unlock the font and installing/copying the font but then it was promptly overwritten with the old version due to it being stored/cached in the WinSXS folder.
I went down a road trying to replace the file in the WinSXS folder but that turns into a permission nightmare and just feels wrong.
Is there a way to update that font without waiting around for Microsoft to push out an update?
Updated Question
Why would I get different results running the application on my Windows 10 development pc versus running it deployed to Windows Server 2019.
question from:
https://stackoverflow.com/questions/65895513/is-there-a-way-to-update-the-segoe-ui-emoji-font-on-windows-server-2019 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…