Midlothian was previously called the county of Edinburgh and Edinburghshire.
There are 158 castles in the county of Midlothian.