By Ed Cropley

JOHANNESBURG (Reuters) - If Donald Trump is interested in rigged elections, Zimbabwean opposition leader Tendai Biti says he could teach him a thing or two. Biti was arrested for treason and detained for a month after daring to suggest his party had defeated President Robert Mugabe in a vote in 2008.

"They denied me food. They beat me up. They put me in leg irons. They beat me in the private parts," Biti, a lawyer who later served as finance minister in an eventual unity government, told Reuters. "That's real election rigging."

To opposition figures in Africa, and in other parts of the world that lack the 240-year U.S. history of peaceful transitions of power, Trump's assertion that November's U.S. presidential election will be "rigged", and his declaration that he may not accept the outcome, are dangerous words.

"Donald Trump is a gift to all tin-pot dictators on the African continent. He is giving currency and legitimacy to rigging because if it can exist in America, it can exist anywhere," Biti said.

"He has no idea what he's talking about, absolutely no idea," said Biti, who speaks from the experience of three election defeats to Mugabe, a 92-year-old ex-guerrilla who has run Zimbabwe since independence in 1980. "It makes us cross because in Africa there's real election rigging."

Long-serving rulers who have faced U.S. criticism in the past are already using Trump's remarks to counter Washington's pro-democracy message.

When Ugandan President Yoweri Museveni, in power for 30 years, won re-election to his seventh term in February, U.S. officials accused his government of arresting opposition figures, harassing their supporters and intimidating the media.

Trump's comments, said Museveni's spokesman Don Wanyama, "should be an eye-opener to them. As they sit down to lecture other countries, they should realize that it's not easy."

"Democracy is a process and it really takes time."

HORRIFIED

Trump refused during a debate on Wednesday to say whether he would respect the result of the Nov. 8 poll. That sent a chill down the spine of Musikari Kombo, a former local government minister in Kenya, where 1,500 people were killed in a wave of ethnic bloodletting unleashed by disputes over the result of a 2007 election.

"I was shocked. I was horrified," Kombo said. "People in Africa who have always challenged elections will say: 'You see, we are vindicated. Even in the Mother of all Democracies, the presidential candidate is not willing to accept because there is rigging.'"

U.S. officials, including state governors from Trump's own Republican Party, say there is no serious vote fraud problem in the United States and the election will be clean.

Nevertheless, Trump and some allies have alleged anomalies in the voter roll in cities such as Philadelphia and Chicago that could allow the votes of dead people to be counted on behalf of his opponent, Hillary Clinton.

It is hard to think what they would have made of this year's election in Gabon, where opposition leader Jean Ping cried foul after narrowly losing to President Ali Bongo, whose family have ruled the oil-producing former French colony for half a century.

The focus of Ping's concern was the province of Haut-Ogooue, where results showed 95.46 percent of voters backed Bongo on a turnout of 99.9 percent, more than double anywhere else.

Gabon's constitutional court - led by the long-time mistress of Bongo's father, Omar - upheld the result.

"I would say to Mr. Trump 'Come to Gabon to see what a fake democracy looks like, to see what a stolen election looks like,'" said Alexandre Barro Chambrier, a senior Ping adviser.

"There is no democracy here. There is the rule of one family and one man imposing a dictatorial regime," he added. "Mr Trump is not serious."

(Additional reporting by Edward McAllister, Edmund Blair and Elias Biryabarem; Editing by Peter Graff)