With his marriage to Urraca , queen regnant of Kingdom of Castile , Kingdom of León and Kingdom of Galicia , in 1109 , he began to use , with some justification , the grandiose title Emperor of Spain , formerly employed by his father-in-law , Alfonso VI .