Ofc Barcelona it's a better choice than Madrid for Graphic Design.
Its a vanguard city, design it's more innovative there. (The city its quite better in my opinion btw)
Madrid its a more conservative, old school city.
In Barcelona the more important design schools are private, you have names such as Massana, Eina or Elisava.
We also have the DHUB, de desing museum and lots of related events if you stay alert.
Hope it helps 