A man has been jailed for 30 months after threatening to set fire to an art gallery and vandalise a second cultural venue.

Lee Peattie, 36, claimed he was going to set light to the National Portrait Gallery and cause damage to the Royal Scottish Academy in March this year.

Peattie, who represented himself, was sentenced yesterday after earlier being found guilty of two charges of threatening and abusive behaviour at the end of a nine-day trial .

Two years ago, he was imprisoned after vandalising St Giles' Cathedral causing £12,000 worth of damage, including to stained glass windows.

Edinburgh Sheriff Court earlier heard Peattie became enraged following an dispute over his benefits payment and left an office in Edinburgh warning a member of staff he was going to firebomb the National Portrait Gallery. Police were informed.

At the gallery on Queen Street, employee Aileen Millar encountered Peattie as he headed to the control room where she was working.

Security staff at two art galleries were also puzzled when a man claimed they owed him £70 dole money, but their puzzlement turned to alarm when he threatened to return and set fire to the National Portrait Gallery and smash the windows of the Royal Scottish Academy.

Ms Millar told the court: "There was a knock at the door. I opened it and he just stepped in. He said 'you owe me £70'."

She added: "I told him I didn't owe anybody £70 and if he hung on I would get the supervisor to talk to him."

The witness said Peattie kept saying he was owed £70 and then produced a can of lighter fluid and told her he would come back and "torch" the gallery.

Another member of staff, Catriona Gourlay, told the jury Ms Millar "seemed quite distressed. Her voice was "quite shaky".

Shortly afterwards, Peattie headed to the Royal Scottish Academy on The Mound.

Security staff member, Susan Butterwick, was on the front door when a man entered and told her: "I am just here to tell you,you are going to get it".

She said: "I asked him if there was a problem and I could get the supervisor to speak to him.

"He said 'I have just been to the National Portrait Gallery and told them and am now here to tell you, you are going to get it'." Ms Butterwick added: "He was very calm and the fact he was calm was more scary".

"He said he was going to come back and smash the windows and spoke about £70 of dole money. I was very frightened. I thought it was a very personal thing that I was 'going to get it'. It was only when he said he was coming back to smash the windows I realised it was the gallery he was threatening and not me personally."

The following day, police went to the guest house where Peattie lived. When Peattie opened the door to his room, a man handed a can of lighter fluid and a lighter to an officer and said: "You will need these." CCTV footage played in court showed a man wearing a dark blue hat and a blue fleece jacket in the galleries. Similar clothing was found in Peattie's room and civilian and police witnesses identified Peattie as the man at the galleries.

In October 2011, Peattie was jailed for three-and-a-half years after being found guilty of causing £12,000 damage in St Giles' in June that year, reduced to 33 months on appeal.

Sentence had been deferred for background reports, including a psychiatric report, but when the case was called before Sheriff James Scott, it was revealed that Peattie had refused to co-operate in the preparation of the reports.

Sheriff Scott said that because of the gravity of the offences and Peattie's record only a custodial sentence was appropriate.

He backdated the sentence to March 30 when Peattie was detained.