This is my understanding...
The cable length is fixed.
The cable is attached to the shift lever at one end and the derailleur at the other.
The shift lever body is fixed to the bike.
The shift lever is movable.
The derailleur attachment point is movable and moves the derailleur in and out.
When the shift lever is activated, it pulls on the cable.
The cable doesn't stretch. It gets pulled through the cable housing and moves the derailleur at the other end.
The cable housing is fixed to the bike at both ends, but is flexible.
When the barrel adjuster is rotated anticlockwise it starts to add length to the cable housing.
As the cable housing is fixed at both ends, this extra length makes the cable housing bend a little bit more.
This means the cable has further to go round the loop inside the housing.
As the cable length stays constant, something has to move.
The only movable point is the derailleur attachment, and this is pulled towards the shift lever body.
This makes it look like the cable is being "shortened" between the shift lever body and the derailleur.
The diagram shows this effect greatly exaggerated.
It's a bit like a bowstring. As you pull on the bowstring, the bow flexes and the ends of the bow move towards each other.