At lunch time, the best option is the Menu del Dia as it is a economic way of getting good quality food.
It consist of 2 main courses, bread, drinks and coffee or dessert for a fixed price of around €12, although the price depends on the restaurant but you can take that as an average.
Menu del Dia is offered at lunch time from Monday to Friday, although some restaurants offer this menu on Saturday usually at a higher price.
There are lots of offices around Passeig de Gracia (see area in the following Barcelona map), that means that there are lots of restaurants in the area where Menu del Dia is offered, so instead of staying around the Ramblas for lunch, go to any of these restaurants around Passeig de Gracia.
Just look for Menu del Dia sign outside (as in picture above) and if you see locals in there, just get in. You won’t regret it as you will get good quality at a reasonable price.