I'm trying to use Pages to write a technical document. The text has mix of normal font and a fixed width font (aka "monospaced") to represent computer code. For example:
The problem is that when there are multiple lines I can see that the fixed width font pushes the line height out and makes the text look bad. It does this even though both the fonts are the same point size. It even does it when I reduce the fixed width font size a little. Here is a larger screenshot to show what I mean.
Some fonts are worse than others. Courier for example, moves the line, but barely. I don't like the looks of it though – its letters appear significantly shorter than the surrounding Helvetica. I like the Fira Code font, but it moves the line a lot. I had to shrink the Fira Code all the way to 7pt before it stopped disrupting the line spacing.
Shouldn't fonts with same point size have the same line height? If not, is there some way to choose fonts that do? Is there a certain kind of font, or property of the font, that I should be looking for?