JEREMY Corbyn insisted the tide was turning towards Labour in his keynote speech to the party’s conference yesterday. The leader of the opposition was in a jubilant mood, addressing delegates just hours after Boris Johnson was found to have acted in an unlawful manner.

He promised delegates that the “years of retreat and defeat are coming to an end” for Labour.

Corbyn was supposed to be addressing conference today, but after Speaker John Bercow announced that Parliament would resume this morning, he rearranged the speech, bringing it forward to the slot earmarked for his deputy, Tom Watson.

The change helped the party avoid what could have been an embarrassing spectacle, with members on the left planning a mass walkout during Watson’s speech.

In his address, Corbyn went on the attack, saying Johnson had “misled the country”.

“This unelected prime minister should now resign,” Corbyn said. “He thought he could do whatever he liked just as he always does. He thinks he’s above us all. He is part of an elite that disdains democracy. He is not fit to be prime minister.”

Corbyn also defended Labour’s Brexit policy. Just 48 hours ago, the fights over the party’s position had threatened to derail the conference. Delegates eventually backed the leadership policy of a “neutral” Brexit.

Labour will go into the next election promising to renegotiate a withdrawal deal before then asking voters to choose between their deal or remaining in the EU in a referendum.

The party would choose which option it would support in that vote at a special one-day conference.

Corbyn said: “We need to get Brexit sorted and do it in a way that doesn’t leave our economy or our democracy broken. The Tories want to crash out without a deal and the Liberal Democrats want to cancel the country’s largest ever democratic vote with a parliamentary stitch-up.

“Labour will end the Brexit crisis by taking the decision back to the people with the choice of a credible Leave deal alongside Remain. That’s not complicated. Labour is a democratic party that trusts the people.”

Corbyn also hit out at Tory leader Johnson over his controversial Daily Telegraph column, telling the conference: “When Boris Johnson compared Muslim women to letterboxes or bank robbers, it wasn’t a flippant comment, it was calculated to play on people’s fears. Displays of racism, Islamophobia or anti-Semitism are not signs of strength, but of weakness.”

Corbyn said his party would “bring people together”.

“We stand not just for the 52% or the 48% but for the 99%,” he said. “The Labour government I lead will take on those who really run our country – the financial speculators, tax dodgers and big polluters – so the real wealth creators, the people of this county, can have the jobs, services and futures they deserve.”

Corbyn also announced plans to create a state-owned pharmaceutical firm which would use compulsory licensing to secure generic versions of patented medicines and create a new publicly owned generic drugs manufacturer “to supply cheaper medicines to our NHS saving our health service money and saving lives”.

Corbyn, would, he promised delegates be: “A different kind of prime minister. Not there from a sense of born-to-rule entitlement. Certainly not there for some personal power trip. There because I want to put government on your side. To put power and wealth into your hands. There because I believe government should work for you.”

“The tide is turning,” he added. “The years of retreat and defeat are coming to an end.”

Over the weekend, an Opinium poll put the Tories on 37% and Labour on 22%.