Trying stay focus dealing with back/fibromyalgia pain

My life has been so stressful just trying work and deal with pain constantly. I just can't seem get it together. When I'm not feeling my best I barely eat any food or just enough to take a pill. I'm so tired of doctors always complaining about my weight; like I'm sitting home eating on bonbons all damn day. I've been this size for years. I just can't seem to stay consistent with eating my daily calories