Ainsworth was attacked outside the High Court in Glasgow on Wednesday
A former police officer accused of sex abuse dating back to the 1960s has been attacked and badly injured during a break in his trial.
Paramedics performed CPR as they battled to save James Ainsworth's life following the incident outside the High Court in Glasgow on Wednesday.
The 61-year-old, from Largs, North Ayrshire, is in a critical condition in the city's Southern General Hospital.
A 31-year-old man is in police custody in connection with the incident.
The jury in Mr Ainsworth's trial was discharged after Judge Lady Scott said he had to be taken to hospital for an "emergency admission".
The judge added: "This may come as a shock and I hope you do not find it too distressing."
Prosecutors can re-raise proceedings against Mr Ainsworth should he be fit to return to the dock in the future.
Prior to jurors returning, Lady Scott said the events were a "matter of concern for the court".
She earlier stated "security issues might arise" after what took place.
On Thursday she told the court: "I will want to see a full inquiry and a report into what is happening."
Lady Scott said the matter has also been referred to one of Scotland's top judges - the Lord Justice General - who also awaits the outcome of a probe.
Mr Ainsworth was on trial accused of a string of offences against a number of individuals dating back to the 1960s.
The case began on Monday and testimony was heard from several witnesses.
The attack is said to have taken place during the lunchtime adjournment on Wednesday.
Police initially attended to Mr Ainsworth, who was lying on the ground just yards from the front door of the high court.
A man - thought to be the attacker - was meantime escorted back into the building by two officers.
An ambulance soon arrived on the scene while the area - close to Glasgow Green - was taped off.
One eye-witness said: "Almost every court police officer was on the scene when it became apparent what was happening.
"The man on the pavement was not moving and was clearly in a very bad way. There were also items scattered nearby.
"Paramedics treated him on the street for around 30 minutes including giving him CPR. Another man - who could have been a witness to it all - was also doing what he could to help.
"CID officers were also soon on the scene. It is just is not something you expect to see outside a court building in broad daylight."
It is not thought any weapon was used in the attack.
Reporting of the incident had been banned for 24 hours while a decision was made what to do with the case against Mr Ainsworth.
Prosecutor Kath Harper moved to halt the trial on Thursday, stating it "seemed unlikely" that Mr Ainsworth would be fit to attend court "in the near future at all".
Ms Harper also said: "Mr Ainsworth is in intensive care at the Southern General. His injuries are life threatening and he remains unconscious.
"He was put into a medically-induced coma. Sedation was lifted and doctors are awaiting a reaction.
"Medical staff are unable to give any prediction for recovery."