FAQ : Why is the PMI text displayed incorrectly (square)
Problem
When importing a CAD file with PMI (non-ASCII characters), the text becomes square when viewed in the HOOPS Demo Viewer.
Possible root causes and solutions
This could be the specific font is not found.
a. SetA3DRWParamsPmiData::m_bAlwaysSubstituteFontto true. And
b. SetA3DRWParamsPmiData::m_pcSubstitutionFontto a specific font. For example, for Japanese characters, you can set “Yu Gothic”.
c. The font name is written in C:\Windows\Fonts
d. If the font is not installed in the system directory. You should set the font path toA3DRWParamsPmiData::m_ppcProprietaryFontDirectoriesand path array sizeA3DRWParamsPmiData::m_uiProprietaryFontDirectoriesSize
This font is only installed for a single user.
a. Fonts installed on windows for a single user end up in a hidden user directory and they show up when boarding Windows/Fonts even though the file is not located there.
b. Try install the font for all users.Last but not least, you need to restart the application or reopen the project (visual studio).
a. Sometimes, some software tends to cache the system environment, including paths and fonts
For more information or to contribute to the discussion, check out our forum post.