An increasing number of long distance hikers/backpackers are leaving the lightweight camp stove at home and "eating cold" on the trail...especially during warmer weather. There is virtually no opportunity to refrigerate or microwave anything in the woods so the items they carry have to be lightweight, stand up to summer temps, be nutritious (backpackers strive for 2,000 calories per day that aren't empty calories!) and be easy to prepare --often requiring only water and whatever they carry with them.
Just google "backpacking foods you can eat cold" for more ideas than you hoped for. It's become a mini-industry. Many of these ideas could easily be adapted for train travel.
Gets boring awfully quickly though. I found that having one hot meal a day felt really good, even if it was just something simple like mac and cheese. I also wanted coffee or tea in the morning. But on a train that's easily done in the dining car or at the cafe.
Also - hiking for 10+ miles a day will tend to require more than 2000 calories a day, which isn't going to be the case on a train. I've heard 3000-4000 is typical depending on the person's size.
Still - there are simple, compact foods that can be pretty satisfying and many don't require refrigeration. I remember packing sealed salami slices that didn't require refrigeration until opened. And even then they (with nitrates as preservatives) could last a day without refrigeration once opened.