font-family: monospace renders incorrectly on macOS
On Tor Browser 11.0.4 on macOS 10.15.7, any element with
font-family: monospace doesn't render correctly: it uses Times or Helvetica instead, depending on context. This doesn't seem to happen on Linux. I haven't had time to bisect to determine when this bug started happening. It also showed up on a recent alpha; not sure which version exactly.
An easy way to see this is to create a
.txt file with some text and open it using a
file:/// URL. Observe that it is not displayed with a monospaced font. Open the Inspector, and observe that under "Fonts Used", the font is not a monospaced font. This affects even the rendering of monospaced HTML and CSS code displayed within the Inspector itself. Some webpages with monospaced text happen to display correctly due to explicitly named fonts in their CSS addition to the
Explicitly adding "Menlo" to
font.system.whitelist appears to work around the problem.