You don't need to eat unhealthy foods to gain weight. It can help you gain weight, but you will lose some of your health.
In order to gain weight, you have to consume more and high nutritional value calories. With other words you have to eat more. Not just fruit and veg, but foods that will supply your body with the right fuel to gain weight.
You may struggle to gain weight because you eat mostly veg and salad.
Whether you are a vegetarian or not, you must include good value carbs and lean proteins to build a stronger healthier body.
3 Meals a day probable won't give your body enough energy to gain weight. Switch over to 6 small meals a day, consisting of lean protein, healthy carbs and fruit and veg. And snack every 2 hours on healthy snacks.
Some of my favorite super healthy snacks include:
* Veggie sticks
* Fat free yogurt
* or few (2-4) whole-grain/wheat crackers with fat free cottage cheese and tomato/cucumber
If it is not practical for you to eat that often, invest in a healthy meal replacement shake. Just don't go for the diet shakes, you don't want to lose weight. A protein shake will be ideal.
Weight training is another exercise that can make you pick up weight and look more muscular (and less anorexic). Aim for 3 sessions a week, doing upper and lower body.
If you follow my tips and you stay away from unhealthy methods of picking up weight, you will gain weight and muscle the natural, healthy way.