My rule of thumb would be, if there's a train route that can make the journey in less than 8 hours, there's no reason to fly at all. Flying will take about as much time when including the overheads, and most hours will be wasted rather than comfortably sitting on a train.
Distance is not a factor; time is. E.g., London-Bergen, in Norway, would be quite difficult to replace by train or boat. Whereas London-Barcelona, which is about the same distance, is easy: there already is a route with Eurostar + TGV via Paris.
London-Bergen: 1044 km https://www.distance.to/London/Bergen
London-Barcelona: 1138 km https://www.distance.to/London/Barcelona