Image copyright Steven Lennie Image caption The success of Scotland's capital city is obvious but does it spread to all the country?

The city of Edinburgh is no place to judge the success or otherwise of 20 years of devolved government.

Its transformation is obvious. The streets of Scotland's capital teem with energy. The city centre is a forest of cranes as a vast new mixed-use development replaces the unlovely old concrete of the St James Shopping Centre. This is a prosperous, open city of many languages and a booming economy.

So I went instead to the corner of Scotland where I grew up, to get a sense of what the Scottish Parliament looks like from there.

I spent my high school years at Stranraer Academy, which was then one of the biggest comprehensive schools in the country. Galloway was - and remains - a fine place to raise a family but it felt, 40 years ago, like a long way from anywhere and very distant indeed from any centre of power.

Has the return of political power from Westminster to Edinburgh changed anything here?

Image caption Allan returned to his old school to talk to Stranraer Academy pupils

Not if you ask today's Stranraer Academy school kids. "We feel like lower class citizens" one of them told me. "Edinburgh and Glasgow are the higher class in Scotland".

I asked whether they got the educational opportunities they wanted. "They used to teach French, German and Spanish here", one girl said. "Now we can only study French and even then there are only two French teachers [for a school with nearly 1,000 pupils]".

I asked for a show of hands among the dozen or so senior-school kids I was sitting with. How many of you expect to have to leave this area when you turn 18? Every hand except two went up instantly.

Image copyright Anne Macphail Image caption Places like Stranraer can still feel a long way from the seat of power

Forty years after I left here, what you might call peripheral Scotland still feels a long way from the centre political power. The birth of the Scottish Parliament doesn't seem to have done much to narrow the perceived gap.

James Mitchell, professor of politics at Edinburgh University, says: "The same argument that was always applied for having a Scottish Parliament - that Scotland was distinct and different - equally applies at the local level.

"The local authorities and communities are diverse with different interests, different priorities.

"We stand out in comparative European terms as one of the most centralised places in Europe."

Image copyright Getty Images Image caption Scotland's first First Minister Donald Dewar and Presiding Officer Sir David Steel arriving for the opening the new Scottish Parliament on 1 July 1999

Scotland's inaugural First Minister Donald Dewar said 20 years ago - at the opening of the country's first parliament in nearly 300 years - that "this is about more than our politics and our laws - this is about who we are, how we carry ourselves".

Dewar died only 15 months after giving what probably remains the best speech ever delivered in the new parliament. But had he lived, he would scarcely recognise today's political landscape.

His own party, Labour, is a shadow of its old self. It had won every election in Scotland for nearly half a century. Then, 10 years after it created the Scottish Parliament, Labour collapsed. This year, it came fifth - (yes, fifth)- in the European elections with less than 10% of the popular vote in Scotland.

The party that fought tooth and nail to oppose the very existence of the parliament - the Conservatives - have paradoxically been revived by it. They - under the leadership of Ruth Davidson - are now the second largest party.

But it's the SNP whose fortunes have been most radically transformed. Labour adopted devolution in the 1970s and 1980s partly in response to the electoral threat the SNP was beginning to pose. Famously, as the Labour Defence Secretary George Robertson put it, a Scottish Parliament was what would "kill nationalism stone dead".

Image copyright Getty Images Image caption It is the SNP whose fortunes have been most radically transformed by 20 years of devolution

Instead, the SNP, which won power in 2007 and has held it ever since. It also led Scotland to within five percentage points of independence in the referendum of 2014.

Forty years ago, as a first year student at Edinburgh University, I voted for the first time. The occasion was the 1979 devolution referendum. Scotland returned a small majority in favour of a devolved assembly, but the number fell short of the high bar set by the Labour government in London, which required at least 40% of all registered voters to vote in favour. Scotland, then, could not muster sufficient enthusiasm to cross that threshold.

The 18 years of Conservative government after 1979 changed Scottish public opinion profoundly. The more Mrs Thatcher and, later, John Major ruled out a referendum on devolution, the more popular support for it grew. By 1997 there was a rock solid pro-devolution consensus in Scottish society. Scotland voted for it by a majority of three to one.

Image caption The new Scottish Parliament was seen as a way of bringing power home, says Allan Little

Scots saw the new parliament not just as a way of bringing power home but also as a way of blocking policies that had majority support in Westminster but which were unpopular in Scotland. The Scottish Parliament, for example, blocked university tuition fees and it dropped prescription charges. The Scottish government declined to lift the threshold for entering the higher rate income tax bracket when Westminster did that for the rest of the UK.

Are we at a similar crossroads now, another 1979?

There is certainly a new danger for those who want to keep Scotland in the UK, a danger openly acknowledged by both Ruth Davidson and Gordon Brown, both passionately pro-Union Scots: Brexit.

Scotland voted overwhelmingly to stay in the EU but will have to leave anyway.

Scotland did not vote for Mrs Thatcher but went through the profound changes she pursued nonetheless. The more Mrs Thatcher set her face against devolution the more the Scots demanded it. The Scottish Parliament grew, in part, out of that experience.

Similarly, Brexit, rejected by Scotland, has the potential to forge a similar shift in public opinion in Scotland. And each time I hear a contender for the leadership of the Conservative Party declare that they will "not allow" another referendum on independence, I hear the distant echo of the 1980s, and sense a further strain on the bonds holding this old Union together.

Allan Little's Children of the Devolution is on BBC Scotland on 2 July at 22:00 and on the iPlayer