An Iranian cartoonist imprisoned over portraying lawmakers as animals to criticize a draft law restricting contraception and criminalizing voluntary sterilization was released from prison Tuesday, her lawyer said.

Iran's President Hassan Rohani meanwhile called for more freedom of expression and said government critics should not be jailed.

Cartoonist Atena Farghadani's lawyer, Mohammad Moghimi, said she was released after an appeals court last month reduced her initial 12-year prison sentence to 18 months.

"I am very happy that she and her parents reunited," Moghimi told The Associated Press.

Farghadani was imprisoned amid a wider crackdown by hard-liners targeting free expression in Iran. Poets, filmmakers and journalists have been charged and imprisoned.

Rohani called for expanded freedoms in a speech at the annual Tehran International Book Fair, underscoring his 2013 election promises of reform.

"Critics should not be detained, critics should not be sent to jail," he said. But he also warned against "lying, blaming and weakening the power of the nation."

This past weekend's parliamentary runoff elections saw the moderate-reformist bloc supporting Rohani secure the most seats in the 290-seat chamber. However, they don't have an absolute majority, a potential challenge to Rohani trying to push through any reforms that hard-liners oppose.