I had a similar problem going from 12 and half stone down to10 stone in about 3 years due to IBS. Another problem is that you feel weak and under nourished and tend to skip activities because it is difficult can lead active life and not eat. We need energy too!
The doctors really let down people in this situation by not helping.
Firstly, I found trying to eliminate foods that trigger IBS. I know this is diffcult because on different days the body reacts differently to the same foods. However, my studies notice that simple sugar foods aggravate IBS - so sucrose, fructose, high fructose corn syrup, lactose, etc are best avoided. You can replace milk with almond milk, coconut milk or hemp milk (the latter gives great levels of omega 3/6 fats which is ideal).
Cereals are refined, that is, they have the goodness removed by processing. Notice in the cereal packaging "fortified" with additional vitamins. Why the need add vitamins to a so called healthy product? Because its not healthy. I am mystified why they remove the natural goodness then have to add it back in with synthetic chemical vitamins! Replace cereals with egg and bacon, scambled eggs, peanut butter on wholemeal toast or oats with water with cinamon to flavour.
Yoghurt and cheese should be okay as most of the lactose is removed. So baked potatoes and cheese topping for example
All meats and fish are fine. All vegetables are fine.
Eat 3 smaller meals spaced out over the day. Wholegrain pasta and beef, tuna and wholegrain rice, wholegrain pasta and chicken, peanut butter sandwiches. Avacado`s are high in calories and easy to digest.
Keep the above as your staple diet and as a treat, the odd KFC or McDonalds wont hurt once a week. Fruit wise, think all berries, watermelon, pomegranet tomatoes, mangos and bananas. Avoid citrus fruits (and drinks with citric acid).
I use ultra fine ground oats with a whey protein powder as a nutritious calory booster. Get a pure whey 90% protein with no sugars or casein added ( I use one with probiotics and enzymes added) and mix with 100g of oats. It drinks easily and is about 460 calories. It tastes a bit oaty but a choc flavoured protein powder helps.
Chew your food thoroughly and take time to eat your meals and digest.
If you stick to the plan you add weight gently without troubling your tummy or bowels too much.
Finally, you could add in weight traininng in a gym provided you get enough energy inside from a regular eating plan. Over a year you could build 14lbs of muscle and become fitter as well. Muscle weighs more than fat so you add weight and will look better. Strength gains actually add mitochrondria to the muscle. Mitochrondria are the energy producers for the body. They are fuelled by carbohydrates or fats from food. So adding strength and muscle fibres increase mitochrondria and energy levels.
Dont worry about Gluten foods unless you get diagnosed with an intolerance to it. I mainly eat wholegrain rice and oats which are gluten free anyway.