Credit items last either 7 or 10 years at most (I forget which). So, from the point of view of the credit bureaus, you have 7 years of solid credit history.
That probably weighs heavily in many credit scores, and if you've only missed mortgage payments but haven't missed payments on revolving credit, that may be strong enough on some credit scores to outweigh the mortgage.
Note that I said 'some credit scores' - there isn't a single credit score, even for any given institution. They all have several, and when a prospective lender pulls your credit score, you don't know which one they're going to use. They use them as secret formulae to figure out whether or not you present a risk to the specific lender, which is why a single agency can have as many as 40 different scores for the same person, depending on which the lender requests.