MUKONO (Reuters) - Scuffles broke out between locals and friends of a murdered Ugandan gay activist at his funeral on Friday after the pastor conducting the service berated gay people and villagers refused to bury the coffin.
David Kato was beaten to death with a hammer on Wednesday, police said. His photo was printed on the cover of a newspaper last October that called for gays to be executed under a headline that read: "Hang them".
Ugandan police say preliminary investigations point to Kato being killed during a robbery but human rights activists suspect his killing was linked to his sexuality.
The murder sparked worldwide condemnation and became one of the top 10 topics on the social media website Twitter on Thursday.
U.S. President Barack Obama issued a statement, which was read out at the funeral, calling Kato a "powerful advocate for fairness and freedom".
During the funeral -- which was attended by about 300 people, including about 100 members of the country's gay community -- the pastor lashed out at homosexuality, provoking a strong reaction from friends of Kato.
"The world has gone crazy," the pastor told the congregation through a microphone.
"People are turning away from the scriptures. They should turn back, they should abandon what they are doing. You cannot start admiring a fellow man."
Gay activists, wearing T-shirts featuring Kato's face with sleeves coloured with the gay pride flag, then stormed the pulpit and grabbed the microphone.
"It is ungodly," the pastor shouted, before being blocked from sight.
An unidentified female activist then began to shout from the pulpit.
"Who are you to judge others?" she shouted. "We have not come to fight. You are not the judge of us. As long as he's gone to God his creator, who are we to judge Kato?"
Locals intervened on the side of the pastor and scuffles broke out before he was taken away to Kato's father's house to calm the situation.
Villagers then refused to bury the body at which point a group of Kato's friends, most of whom were gay, carried his coffin to the grave and buried it themselves.
Uganda's anti-gay movement first made international headlines in October 2009 when a bill was tabled in the country's parliament proposing the death penalty for homosexuals who are "repeat offenders".
The bill was quietly postponed under international pressure, but rights groups fear it may pass after a February presidential election that President Yoweri Museveni is expected to win.
"I'm very upset," Julian Pepe, gay rights activist and a friend of Kato's who attended the funeral, told Reuters, her voice breaking with emotion.
"After we had read statements from everybody, including Obama, after all the nice things friends said about David, that this man could stand up and throw dirt at someone who should be resting in peace. It's just disgusting."