Kwame Kilpatrick was sent off to jail for four months on Tuesday for his part in a sex-and-text scandal and was given a tongue-lashing by the judge, who chastised the disgraced ex-mayor for his arrogance and disregard for the rule of law.

The sentencing before Wayne County Circuit Judge David Groner served as the finale to the scandal that destroyed Kilpatrick's reign at City Hall and threw local government into disarray for months.

"At a time when this city needed transparency, accountability and responsibility, you exhibited hubris and privilege at the expense of the city," said Groner, who ordered the sentence during a lengthy afternoon hearing.

Click here for photos.

He ruled that Kilpatrick not be given an opportunity for early release.

But county sheriff's spokesman John Roach said in a statement shortly after the sentence that Groner didn't have the standing to order Kilpatrick not receive time off for good behavior.

The judge's ruling "does not override Michigan Statute that says a sheriff shall credit all sentenced county jail inmates with one day good time for every five days served, provided the individual is a model inmate," Roach said.

County prosecutor Kym Worthy sided with the sheriff's interpretation, saying during a news conference after the sentencing that Kilpatrick is eligible to receive early release for good behavior.

She predicted he would not serve the full 120 days if he behaves well behind bars.

Kilpatrick, 38, pleaded guilty to obstruction of justice, admitting he lied about an affair with his chief of staff while testifying in a civil lawsuit in 2007. He also pleaded no contest to assaulting a sheriff's detective.

That 120-day sentence will run at the same time. He also was ordered to serve five years of probation and pay the city $1 million in restitution. Kilpatrick paid $20,000 Tuesday to the City of Detroit as his down payment on the restitution.

Despite the prosecution's request, Groner didn't order Kilpatrick to undergo anger management, because he considered the alleged assault an isolated incident. The judge said that if any other incidents happened during Kilpatrick's probation he would reconsider the order.

Click here to read the plea agreement (PDF).

Click here to read his resignation letter (PDF).

Kilpatrick did not take an opportunity to address the court, saying simply "No I don't, your honor," when asked if he wished to speak.

But Groner took full advantage of his right to speak in ordering the sentence, offering harsh words to Kilpatrick.

"Ultimately what shocked this court and much of the community was your press conference after your plea hearing," the judge said. "That night the community expected to hear a message of humility, remorse and apology. Instead we heard an arrogant and defiant man who accused the governor, among others, for his downfall."

Outside court, Bernard Kilpatrick said his son was "railroaded" and referred to Groner's remarks as "crap."

Groner moved the hearing to a larger courtroom to accommodate the news media and spectators. As he waited for the sentencing hearing to begin, Kilpatrick sat back with an arm around his wife, Carlita. The ex-mayor smiled often and chatted with other family members and supporters seated nearby.

But once the hearing began, Kilpatrick's demeanor changed. At times, he was seen burying his head in his hands.

It was Kilpatrick's first public forum since the speech to supporters — referenced by the judge Tuesday — after his guilty plea Sept. 4. In that address, Kilpatrick lashed out at Gov. Jennifer Granholm, who was holding hearings to remove him from office, and told Detroit, "you done set me up for a comeback."

His next stop is the Wayne County jail, just steps from the downtown courthouse, where Kilpatrick will be in his own cell 23 hours a day. He will not be allowed to mix with other inmates during his one hour of recreation.

It's "no country club," Sheriff Warren Evans said.

Kilpatrick, before he was escorted to the jail Tuesday, moved forward to kiss his wife, but was stopped by a sheriff's deputy.

"I can hand her keys, but I can't kiss her?" Kilpatrick said.

As he was being taken away, the former mayor yelled out: "You all take it easy."

In response, shouts of support rang out from the courtroom.

"Be strong, mayor."

"We love you, mayor."

"We got your back, mayor."

Kilpatrick, a Democrat, admitted lying while testifying last year in a civil lawsuit filed by former police officers who had accused him of illegally demoting or firing them.

He and chief of staff Christine Beatty denied having an affair, but text messages obtained by a lawyer in the case — and later the Detroit Free Press — clearly contradicted them.

They used their city pagers to arrange trysts and share sexually explicit desires. A fresh batch of messages was released last week, revealing that Kilpatrick, married with three children, likely had other lovers.

The messages first were publicly disclosed in January by the Free Press. Beatty quickly resigned but Kilpatrick hung on as mayor, even when prosecutors filed criminal charges against the pair in March.

The saga rolled through spring and summer as Kilpatrick hired a team of lawyers and public-image specialists and publicly ridiculed the case against him.

The City Council voted to hold impeachment-style hearings but a judge said it was illegal. Elected officials called on Kilpatrick to step down for the sake of the entire state.

Finally, he agreed to plead guilty and resign only after the governor began the public hearing in September that could have led to his ouster.

Ken Cockrel Jr. was promoted to mayor from council president. A special election to fill the balance of Kilpatrick's term will be held in May after the field is trimmed to two candidates Feb. 24.

Click here to read about the interim mayor.

Click here to read about his legacy as mayor.