BEIRUT, Lebanon — With the bulk of seats decided in Iran’s parliamentary elections, it appeared on Sunday that the supreme leader, Ayatollah Ali Khamenei, has gained the ironclad majority he needed not just to bring the country’s president to heel, but to eliminate the position entirely.

Ayatollah Khamenei has jousted repeatedly with President Mahmoud Ahmadinejad — as well as the two previous presidents — so the supreme leader secured this majority at Mr. Ahmadinejad’s expense.

The ayatollah will seek “to eliminate the post of president,” said Aliakbar Mousavi Khoeini, a former reformist member of the Parliament now living in exile in the United States.

“If they can get that, they will not hold the next presidential election; instead, Parliament will chose a prime minister,” he said. “Then Khamenei will essentially have everything he does approved and pushed through Parliament by his allies.”