AFAIK GPS never gives you any kind of "slant" range.
If you set say two waypoints, which the GPS says are 10.000nm apart, that will be the great circle distance between them
as measured along the surface of the ellipsoid which approximates the MSL surface.
One could argue that since an ellipsoid is not a sphere, then if you start on say a point on the equator and move to the north or to the south, you are actually going slightly downhill even if you remain at sea level the whole time. But this effect is miniscule.
The altitude portion of the GPS solution comes out of the same calculation as lat/long but is normally presented separately because that's the way we like it. The altitude reading does have a correction applied to it, to correct for the deviation between the ellipsoid and the true MSL surface, but this doesn't affect the horizontal distance.
The science behind GPS is extremely complicated but the end result is very very simple.