Margaret was Queen of Scotland between 1286 and her death in 1290 (although she never set foot in the country). The daughter of Eric II (the Priest Hater) of Norway and Margaret, daughter of Alexander III of Scotland, she was born in 1283 and recognised as heiress presumptive by the nobility of Scotland in the following year. On Alexander's death in 1286 (after a brief period when it was uncertain whether Alexander's widow, Yolande of Dreux, was carrying a child) she was made Queen, under a regency of 6 guardians drawn from among the bishops and barons, and Edward I of England immediately began to negotiate for her to marry his eldest son, also Edward. Alexander's first wife (another Margaret) had been Edward's sister, so he felt he had some familial claim. After four years the Scots agreed, having obtained the stipulation that, despite the marriage, Scotland would remain independent of the English throne.
Whether the English king would have kept his word will never be known (although it is now known that the English clerks had drafted clauses into the treaty which would have reduced Scotland to no more than an English appendage) because, on the voyage from Norway to Scotland she drowned and died. The succession was now uncertain -- all of Alexander's children being dead and no other heir declared -- and Edward promptly attacked . However, from the chaos and his attack the House of Balliol emerged, followed by the reign of Robert the Bruce.
Dying, therefore, at age 7, Margaret never had a chance to show what she might have achieved as Queen -- and Edward, in the traditional role of 'perfidious Albion', made a firm attempt to annexe Scotland under client rulers nominated from London, and imposed on Scotland through compliant or bribed nobility.