Just to clarify, the funny values I mentioned above appear to be more precisely the following: when a string with a trailing " " is evaluated that space is ignored by getStringBoundingBox. When a string that begins with " " is rendered it appears shifted one full character to the left.
I went ahead and tried replacing the spaces with ‘p’'s in order to use the getStringBoundingBox function but that still seemed off. I tried rendering two texts side by side, one with spaces between each letter and one with ‘p’ replacing every space. It looks like the space added by the draw function is actually smaller to that of a rendered ‘p’.
Looking at the code in ofTrueTypeFont.cpp inside the drawString function I noticed that the " " character is modified by the width of p while other characters are normally modified by their setWidth. So setWidth of ‘p’ appears to be larger than the width of a ‘p’. If I change references to width with setWidth for the " " character in the drawString function my texts now align correctly and every space is the same size a a rendered p. Aesthetically these spaces appear a little too large, which may be the reason the other value was being used?
I tried doing the same with getStringBoundingBox but this did not change the error of the trailing " " not being added by getStringBoundingBox. At least now I can substitute those " " for “p” in order to get getStringBoundingBox.width and it will align with the rendered spaces.