Is there any difference in the meaning of these two phrases: 'in the distance' and 'from a distance'?
And the following two sentences sound different?
He looks good in the distance.
He looks good from a distance.
The difference is in your starting point; where you measure the distance from.
You use in the distance when you start measuring the distance from where you are standing:
I could see him in the distance, 10km away from me.
You use from a distance when you start measuring from the object you are looking at, in this case where 'he' is standing:
I can see him from a distance - I am 10km away from him.
I saw a boat in the distance. (The boat was far away from my location.)
in the distance is itself almost a "location" that one sees far away. Where was the boat? It was in the distance.
I saw a boat from a distance. (I was far away from the boat when I saw it.)
"I saw a boat in the distance." - I think it emphasizes the boat, which is far away.
"I saw a boat from a distance." - It emphasizes the action. I perform this action "SAW" far away from the boat.
From a distance (not near) e.g. From a distance he looks a bit like Johnny Depp.
In a distance (far away) On a clear day you can see the temple in the distance.
Reference: Cambridge Dictionary
Personally, I think "From a distance" refers to something that is not close to you, while "In a distant" suggests that something is far away from you. I can't clearly tell you the difference, but I can feel the distinction.