the fiefdom under the control of the Scottish crown. By 1372, after reaffirming control in the east, Archibald acquired the Earldom of Wigtown from Thomas Fleming, Earl of Wigtown, thus consolidating his power over the whole of Galloway, the first time under one man since 1234. This transfer of the earldom of Wigtown was ratified by Robert II on 7 November the same year. Archibald's conquest of Galloway was depicted on his seal, which depicts two "wild men" holding up his arms. In 1378, Alexander Ramsay of Dalhousie, a nephew of Archibald Douglas, took Berwick by surprise with 50 men, and was immediately besieged by the town's governor Thomas de Musgrave. Douglas and Lord Lyndsay of the Byres assembled a relief army at Haddington, little more than 500 in number, but marched anyway, hoping to collect more men on the way. When Archibald's army approached Berwick, his scouts informed him that the English army around the castle numbered around 10,000, with archers, siege engines, heavy horse and ships blockading the river. Douglas then retreated to Melrose, followed by the English army. Just short of Melrose, Musgrave attacked. Fortunately Archibald's army had now been reinforced. During the ensuing Battle of Melrose, Musgrave was unhorsed and forced to yield for ransom. With Musgrave and other leaders captured, the remaining English not already slain fled back to Berwick with news of their defeat. It is around this time that Archibald started work on his fortalice at Threave Castle, and endowed Sweetheart Abbey, near Dumfries, with an hospital. Rather than taking over Buittle, traditional seat of the Balliols during the construction of Threave, he took up residence at Kirkcudbright, traditional seat of the earlier lords. In territorial possessions alone Archibald, Lord of Galloway appeared now to have matched, if not overtaken, his cousin William, 1st Earl of Douglas. Earl of Douglas In 1384, William the first Earl of Douglas died of a seizure at Douglas, and was succeeded by his son James Douglas, 2nd Earl of Douglas, who was killed during his victorious Battle of Otterburn four years later in 1388. Archibald inherited his cousin's earldom and all the entailed Douglas lands, making him the most powerful magnate in Scotland. During the intervals of war with the English, he imposed feudal law on the border chieftains, drawing up a special code for the marches. The power of the Black Douglas overshadowed the crown under