ManlyMarco/RuntimeUnityEditor

GUI text not rendering on wine (solution included)

daniele-bondi opened this issue · 3 comments

Opening RUE in a windows game running on wine causes the taskbar to open, but no text is rendered, and buttons shrink to their minimum size.

According to my experiments this is because the font for the default unity gui skin is Arial.ttf, which by default is not installed in a wineprefix.
Installing arial via winetricks solved the issue.

I thought I'd report it here in case anyone else is stupidbrave enough to develop mods on linux.

Do you know of any in-engine ways to work around this? Which fonts are installed by default?

Do you know of any in-engine ways to work around this?

Unfortunately I don't.

Which fonts are installed by default?

I attached two dumps of HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Fonts, one coming from a wineprefix without additional fonts installed and one from the prefix where I installed arial (Z: is mapped to the linux root directory).
Note: I use Lutris to manage my prefixes, which may or may not perform additional configuration on top of vanilla wine.

I don't know how relevant this registry entry is to wine or unity, but looking at the differences between the files I assume that unity has trouble loading fonts from nonstandard locations.
Going with this assumption, the only available font files have the .fon extension, which I have never seen before, so I don't know how useful they might be.

fonts-vanilla.reg.txt
fonts-after.reg.txt

EDIT: I uploaded the files using the wrong name...
I updated the links to point to the correct files but I can't change their url so e.g. files/13452986/fonts-after.reg.txt is actually the vanilla dump and vice versa.

I saw that you load custom images for RUE from the filesystem for your custom skin.
Maybe shipping a font and loading that into the skin would work?