Other than 'day headlight' being used during 'daylight hours' and 'night headlight' being used in 'night time hours' there is no rule as such. When I was driving for Thameslink, I was told to turn the night light on was when the street lights came on or it was 'obviously night time'. If there is only one headlight it must be used at all times when on the mainline. In sidings and depots, no headlight should be used, only the two marker lights.
Some trains don't have both marker lights on, I think trains built after, but not including, the 319/0s have just one marker light on, on the opposite side to the headlight in use.
Click here for a picture of 319/3 (319/1) with headlights on
Click here for a picture of 319/4 (319/0) with headlights on
Trains built now have to have a headlight in the roof above the cab on at all times.