That's only true if the last position was heating or hot water. If the valve is in mid position when CH or HW is satisfied, it will automatially change over to the function still required (CH satisfied, changes to HW; and vice-versa).
My description was based on what would happen when the programmer switches off the heating and hot water at night. During normal operation, if one function is still running, then of course as you say the valve will move to the correct position as required.
At the end of the days heating cycle what happens depends upon where the valve is positioned at the time.
1) If the valve happens to be in the
'Mid Position' (heating on and hot water on) when the programmer switches off, immediately a live is applied to the grey wire (HW Not required) because the valve's internal microswitch has operated, that live will go straight through it to the valve motor and wind it across to the 'Heating Only' position where it will stay. [I have edited my first post slightly as it could be read that the valve stays in the mid position and not that it moves to heating only, but as far as the OP is concerned (& has noticed) the end result is the same, the motor is still energised.]
2) If it was in the
'Heating Only' position, it will stay there for the same reason, being powered via the grey wire. [The loss of the live on the white wire, in turn, removes the live on the orange wire and so the boiler goes off]
3) If the last position was
'Hot Water Only' there is no power whatsoever applied to the valve motor and the spring holds the valve in the 'Hot Water Only' position. When the hot water goes off and the grey wire becomes live, because the microswitch hasn't operated it doesn't get fed to the valve motor. So, during the summer if the central heating isn't used, the valve will stay held by the spring in the 'hot water only position' with the motor completely un-powered for the duration.