'How to get desktop UI font size on Linux?

I have a FreeType2/FontConfig/Harfbuzz application. I am attempting to get the desktop font size in a portable way on Linux desktops without using GTK+ or Qt, only FreeDesktop norms.

How do I get this information?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source