If I start an X application from a terminal, the error messages go to the terminal. If I start them from a  GUI, where do the error messages go, or alternatively how are they dealt with?
Where do X error messages go?
xorg;logs
Display managers such as xdm & gdm usually capture stderr from the processes they start and log it to a file such as /var/log/xdm.log or /var/log/gdm/:0.log.  That includes the output from the X server being started.Once your session starts, it may redirect output from the session processes to a file such as ~/.xsession-errors as tante pointed out in his answer.