Image copyright AP Image caption Emergency teams descended on Seattle Pacific University and the campus is in lockdown

Police in the American city of Seattle have praised the bravery of a student for disarming a gunman who had killed one person and wounded three others.

Jon Meis, 22, overcame the gunman at Seattle Pacific University as he tried to reload, police said. Pepper spray was used to subdue the attacker.

Police said the actions of Mr Meis, and others who came to his aid, prevented a more serious tragedy.

The gun suspect has been named as Aaron Ybarra, 26, who is not a student.

On Friday, a judge ordered that Ybarra be held without bail on suspicion of first-degree murder and assault.

After the hearing, defence lawyer Ramona Brandes said her client suffers from "significant and long-standing mental health issues" and had been involuntarily committed in the past.

Ybarra told detectives after his arrest he wanted to kill as many people as possible and then himself, Seattle police wrote in a statement filed to court.

He was carrying a shotgun and a knife when he walked into the foyer of the university on Thursday afternoon and opened fire.

Image copyright AP Image caption Jon Meis (centre) was not injured in the attack at Seattle Pacific University

Image copyright Getty Images Image caption Students have been left in shock after the incident

Image copyright Getty Images Image caption The Christian university has about 4,270 undergraduate and graduate students inside a 40-acre campus

"But for the great response at Seattle Pacific University (SPU) this incident might have been much more tragic," Seattle police spokesman Paul McDonagh told a news conference.

Mr Meis is said to be an electric engineering student who was not injured in the shooting.

"He is a hero," fellow student Matt Garcia wrote on Twitter. "I'm proud of [his] selfless actions."

SPU President Daniel Martin told the Seattle Times that the students who overpowered the gunman "acted without regard to their own safety on behalf of others".

"We are a community and we care for others," Mr Martin was quoted as saying. "Those that were involved did just that."

He said that students and university personnel have procedures in place for when a shooting occurs, which was one reason why the gunman was subdued so quickly.

Image copyright AP Image caption Seattle Mayor Ed Murray (second from left) hurried to the scene

Hospital officials in the Washington state city said the person killed was a man in his 20s. A woman is also in a very serious condition with a gunshot wound to her upper body.

The other two injuries were sustained by men in their 20s. One is in a stable condition and the other has minor wounds to the abdomen.

In a statement, Seattle Mayor Ed Murray referred to previous fatal shootings in the city and added: "Once again the epidemic of gun violence has come to Seattle, the epidemic of gun violence that is haunting this nation."

SPU is a privately run Christian university which has about 4,270 undergraduate and graduate students inside a 40-acre campus about 10 minutes from central Seattle.

The US has recently suffered a spate of shootings in or near colleges.