I thought that "Windows Forms" doesn't support OTF-Fonts. But by trying it anyways I realized the opposite.
For me it works perfectly well, but why, when everyone says that OTF-Fonts are not supported in "Windows Forms"? I also tried different OTF-Fonts and also checked multiple times if they’re actually OTF-Fonts and it still works. And I also tried this "Windows Forms"-Application and the OTF-Fonts on a brand new virtual machine. It still works.
Has anyone an idea, what I’ve perhaps have done different than everyone else?
The reason I asked this question is that someone I know has the problem that a "Windows Forms"-Application crashes with the exception message, that only TTF-Fonts are supported, every time an OTF-Font was chosen. And I'm unable to reproduce this issue in my environment and can use OTF-Fonts in an "Windows Forms"-Application without any problems, but don't know, why.
This problem can be reproduced by installing a Font in runtime of the program before he tried to use it.
The message that the OTF-Format was to blame (only the TTF-Format will be accepted) occured but the true reason was the installation or the way how the font was installed.
The same with the installation of the TTF-Fonts (with the same error message).
So when something with the installation of the Font went wrong the exception happens and the occurring error message is misleading.