Indonesian police used tear gas and water cannon Thursday to break up a rally by supporters of the ex-general who lost last month's presidential election, as a court was set to uphold his opponent's victory.
As judges at the Constitutional Court started reading the lengthy verdict to Prabowo Subianto's challenge of an election won by Joko Widodo, which could take several hours, police responded to a rowdy crowd of his supporters with force.
Officers fired multiple volleys of tear gas and water cannon into the crowd, which was several hundred strong, after they earlier threw rocks and attempted to push past lines of riot police guarding the road to the court, which was closed off.
Some police chased supporters away and hit them with batons. It lasted only a few minutes and the crowd dispersed afterwards. An AFP reporter at the scene said one unconscious protester was carried into an ambulance.
Dalianto, a 57-year-old protester who like many Indonesians goes by one name, earlier said that he was showing his support for Prabowo as he was the "true president".
Independent analysts expect the nine-judge panel to reject Prabowo's challenge. The verdict cannot be appealed.
Both Prabowo, a top military figure in the era of dictator Suharto with a chequered human rights record, and Widodo, the reform-minded governor of Jakarta, declared victory at the July 9 election.
But official results released after a two-week count across the vast archipelago showed Widodo won a decisive, six-point victory after the hardest-fought, most polarising election since authoritarian rule ended in 1998.
The 53-year-old, who won legions of fans with his down-to-earth approach as Jakarta governor and is known by his nickname Jokowi, is the country's first leader from outside the political and military elites.
But Prabowo -- who has been seeking the presidency for a decade -- has refused to accept the results and his team filed a lengthy complaint against the election commission with the Constitutional Court, which has the final say on poll disputes.
His team say fraud occurred at tens of thousands of polling stations, and that election officials failed to order recounts in numerous places where they should have.
But evidence presented by Prabowo's team has not been regarded as convincing.
"They are going to throw out the suit," said Tobias Basuki, a political analyst from Jakarta-based think-tank the Centre for Strategic and International Studies, adding that the evidence was "very weak".
Legal challenges were mounted after Indonesia's two previous direct presidential elections, in 2004 and 2009, and both failed.
The huge team of lawyers for Prabowo, now a wealthy businessman, has been left red-faced at times by unconvincing witness testimony.
One witness claimed to be a village girl from the mountains who supported Prabowo -- only for it to emerge later she held a senior position with the ex-general's party in eastern Papua province.
Security was tight for the announcement, with around 4,000 police on duty at the court, where Prabowo supporters have been staging peaceful rallies for the past fortnight.
Another 30,000 security personnel, including soldiers and police, were deployed around the capital, while a total of 250,000 police were on duty across the vast archipelago.
There have been concerns about the Constitutional Court's impartiality after its former chief justice was jailed in June for accepting bribes to sway his rulings in regional election disputes.
But analysts believe that the court will be desperate to appear clean following the recent scandal.
Even if he loses, Prabowo has pledged to fight on, telling supporters this week that "our struggle has just started". But observers believe he has no other realistic options left to challenge the result.
A loss for Prabowo in court would clear the way for Widodo to focus on forming his administration and formulating policy before his October 20 inauguration.
He has already set up a "transition team" to shape policy and pick his cabinet, and asked the public to suggest who they would like to be ministers in an online poll.