was sacked by an anti-papist mob during the Glorious Revolution in 1688. Middle Ages Early Medieval Scotland and Ireland shared a common culture and language. There are much fuller historical sources for Ireland, which suggest that there would have been filidh in Scotland, who acted as poets, musicians and historians, often attached to the court of a lord or king, and who passed on their knowledge and culture in Gaelic to the next generation. At least from the accession of David I (r. 1124–53), as part of a Davidian Revolution that introduced French culture and political systems, Gaelic ceased to be the main language of the royal court and was probably replaced by French. After this "de-gallicisation" of the Scottish court, a less highly regarded order of bards took over the functions of the filidh and they would continue to act in a similar role in the courts of lords in the Highlands and Islands into the eighteenth century. They probably accompanied their poetry on the harp. When Alexander III (r. 1249–86) met Edward I in England he was accompanied by a Master Elyas, described as "the king of Scotland's harper". The same accounts indicate that the Scottish king was also accompanied by trumpeters and other minstrels. The captivity of James I in England from 1406 to 1423, where he earned a reputation as a poet and composer, may have led him to take English and continental styles and musicians back to the Scottish court on his release. Walter Bower, abbot of Inchcolm praised him as "another Orpheus", including mastery of the organ, drum, flute and lyre. James II also demonstrated some musical ability. His marriage to Mary of Guelders, who had been educated in the Burgundian court, meant that she brought the latest ideas of music to the Scottish court. The story of the execution of James III's favourites by his enemies, including the English musician William Roger, at Lauder Bridge in 1482, may indicate his interest in music. Renaissance monarchs often used chapels to impress visiting dignitaries. James III founded a new large hexagonal Chapel Royal at Restalrig near Holyrood that was probably designed for a large number of choristers. Lutenists began to appear in the royal household accounts from the reign of James III, with the earliest reference in 1474. In 1501 his son James IV refounded the Chapel Royal within Stirling Castle, with a new and