Can the gay vote swing an election? Ask Nicolas Sarkozy. He lost the French presidency to François Hollande in 2012. Having toyed with LGBT equality in the 2007 French presidential election campaign, Sarkozy won a comfortable majority, but by speaking out against equal marriage in 2012, he turned his back on the LGBT vote.He paid the price.

There’s a science to how people vote. Approximately 4% of the population will factor in support for LGBT+ rights in deciding who they vote for. Hollande pipped Sarkozy to the post with the tiniest of margins, just over 3%.

Labour, in contrast, has an LGBT action plan. It wants LGBT people to live in 'safety' and 'dignity'

David Cameron learned from Tony Blair that the LGBT vote mattered. In 1997, Blair had turned the status quo on its head, championing the end of “unjustified discrimination wherever it exists”. Gay rights campaigners knew exactly how to interpret this, and Blair became the darling of the LGBT community. This was in stark contrast to the Tory homophobia of the 1980s and early 90s, which seemed to benefit them electorally at the time but which later had become a vote loser – particularly their dogged resistance to repealing the infamous section 28. By 2005, Blair’s commitment to protecting LGBT people, most obviously with the introduction of civil partnerships that year, made his party seem modern compared with the jurassic Tory party under Michael Howard. In 2015, Cameron was able to woo the gay vote having legislated for same-sex marriage, outshining his coalition partners and proving he could be trusted with liberal values. But in 2017 Theresa May found out to her cost that you can’t take the LGBT vote for granted. In her manifesto she spoke warm words but said little of substance. Is it a coincidence she lost Cameron’s majority?

Will the LGBT vote decide the 2019 election? The lack of any real substance in the Conservative party’s manifesto in relation to LGBT rights suggests the party has either learned nothing from Cameron’s success and May’s blunder or it is supremely confident of its majority and thinks it has no need to court gay people. The manifesto makes two references to LGBT people, one to sexual orientation, among a long list of other protected grounds, and no reference to gender identity or trans people.

To their credit, along with the other national political parties (except the Brexit party),the Conservatives are committed in their manifesto to inclusive LGBT education at schools. But when it comes to LGBT rights, that is about it. They agree that LGBT people, along with “all religious groups”, should be protected from harassment and violence. They also flag up an international conference on global LGBT rights that’s been in the pipeline for years. It’s a UK government commitment, not a Conservative party one. Other than that, there’s nothing.

Labour’s manifesto criticises the Conservatives for being “slow to understand the scale of abuse and discrimination LGBT+ people continue to face”. The hollowness of the Conservative manifesto on LGBT issues suggests it has a point. Labour, in contrast, has an LGBT action plan. It wants LGBT people to live in “safety” and “dignity”. It proposes an LGBT ambassador to work on ending LGBT discrimination abroad. It aims to tackle LGBT health issues, making HIV prevention a priority. PrEP, the pill that can stop people becoming infected, will be made freely available. It commits to finding money to support LGBT causes.

The Liberal Democrats and Greens have similarly comprehensive policies. Both are explicit in relation to LGBT mental health, as well as guaranteeing full spousal equality, and rights for non-binary people. The Greens write beautifully about combating gender discrimination against LBT women. Both make reference to asylum policy. It is perhaps not surprising that the Brexit party has no LGBT policies.

But the truly shocking policy omission from the Conservative manifesto is any meaningful reference to trans rights, let alone equality. Labour, the Lib Dems and the Greens have thoughtful, sensitive and well-thought-through policies. Labour has gone on to clarify its commitment to ending discrimination against trans people. The failure of the Tories to engage expressly with trans rights is setting up a battleground for the future. The message is clear: Boris Johnson’s Tories consider trans issues to be a vote loser.

Has Johnson done enough to avoid a Sarkozy-style own goal? He is taking a risk. His manifesto gives LGBT people no reason to vote Conservative. There isn’t even the attempt made by May to present the Tory party as LGBT-friendly. It may be that he’s calculated that his majority, if he’s to get one, will come from persuading Brexit party voters to back him. Self-evidently, LGBT rights are not important to Brexit party-inclined voters, hence their total absence from the Brexit party manifesto. But this is a dicey strategy.

Can Johnson’s Conservatives be trusted with LGBT rights? Cameron aside, Conservatives have form on resisting them. Senior Tories have in the past objected to the lifting of the ban on LGBT people serving in the armed forces. Others have said B&B owners should not be required to have gay people stay in their homes if they don’t want them. Equal marriage happened despite Conservative MPs. Most voted against. On top of that, they have already committed themselves to ditching the EU Charter of Fundamental Rights, with its express right to non-discrimination on the basis of sexual orientation, if or when Brexit happens. In their manifesto they promise to “update” the Human Rights Act, which has been instrumental in protecting LGBT people. Additionally, the manifesto flags up that judicial review must not be “abused” by the courts and a commission will re-examine rights in the UK. Watch out, trans people. Johnson is happy to refer to gay men as “tank-topped bum boys”. As foreign secretary, though it was in his gift to grant civil partnerships to lesbian and gay couples in UK Overseas Territories, he chose not to. In his last cabinet, the majority were opposed to equal marriage.

When the history of this election is written, will Johnson have proved that he can reverse history? Will he win a majority despite deliberately snubbing LGBT people? My money’s on Blair, Cameron and Hollande; Johnson will suffer the same fate as Sarkozy.

• Jonathan Cooper is a lawyer and human rights specialist