Dom Fernando, was already 3rd Count of Arraiolos when he got the new title of Marquis of Vila Viçosa. Later, in 1460, as his older brother Afonso, died without legitimate issue, he became the House of Braganza heir and, one year later, following his father’s death (1461), he also became the 2nd Duke of Braganza.
That’s why the title Marquis of Vila Viçosa became associated with the title Duke of Braganza.
The Queen consort Amélie of Orleans, while in exile (20th Century), also used the title of Marchioness of Vila Viçosa.