If you were seeking to be positive about the likely premiership of Boris Johnson – which is absolutely not my intention – you might liken him to one of his predecessors as foreign secretary and prime minister, Lord Palmerston, who dominated British politics in the 1850s and 60s and, for all his foibles (and sexual excesses), was much loved by the public.

The similarities in their worldviews are striking. Palmerston was popular because his politics were founded on foreigner-bashing. His vision of the world was simple: Britain had perfected the art of democracy and was entitled to impose its views on everyone else. As one historian has noted, the “ideological strand to Palmerston’s diplomacy … appealed to the aggressive national chauvinism that was such an important component of the mid-Victorian psyche”.

Everything Johnson has ever said about the world is jokey, insensitive, stupid and needlessly provocative

That foreigner-bashing finds its modern parallel in Johnson, who has spent much of his career being beastly about those who had the misfortune not to be born British. This despite his own Turkish ancestry – a severe case of over-compensation perhaps. His rude poem about Turkish president Recep Tayyip Erdoğan having sex with a goat (“There was a young fellow from Ankara / Who was a terrific wankerer”) certainly seems to bear out this psychological interpretation.

Johnson’s far-from-sunny view of the French has also now been revealed. He thinks they are “turds”, a remark disgracefully pulled from a BBC documentary on the Foreign Office last year because it threatened to derail the Brexit negotiations – what self-respecting news organisation censors its greatest scoop? – but now exposed by the Daily Mail.

Calling the French “turds” for being intransigent on Brexit is a sign of Johnson’s vulgarity and stupidity. As his second-class degree suggests, his is a second-rate mind trying desperately to persuade us it is a first-rate one by using Latin tags and improper jokes. His useless, vapid books are the measure of the man.

Everything that Johnson has ever said about the world is jokey, insensitive, stupid and needlessly provocative. His racism is well-rehearsed. Where does one begin? Perhaps in 2002 when he discussed a visit to Africa by Tony Blair in an article in his mouthpiece, the Daily Telegraph: “What a relief it must be for Blair to get out of England,” he wrote. “It is said that the Queen has come to love the Commonwealth, partly because it supplies her with regular cheering crowds of flag-waving piccaninnies.”

One racist allusion was, however, not enough. He went on: “They say he [Blair] is shortly off to the Congo. No doubt the AK47s will fall silent, and the pangas will stop their hacking of human flesh, and their tribal warriors will all break out in watermelon smiles to see the big white chief touch down in his big white British taxpayer-funded bird.”

In 2006 Johnson had to apologise when he suggested that the inhabitants of Papua New Guinea were cannibals. “For 10 years we in the Tory party have become used to Papua New Guinea-style orgies of cannibalism and chief-killing,” he wrote (in the Telegraph again, of course), “and so it is with a happy amazement that we watch as the madness engulfs the Labour party.” During the 2016 referendum campaign, Johnson suggested that President Obama’s view of the UK was attributable to his “part-Kenyan” heritage and “ancestral dislike of the British empire”.

Johnson, who once referred to Africa as “that country”, would agree with Palmerston that colonialism is a jolly good thing. “The problem is not that we were once in charge [in Africa],” he wrote in the Spectator in 2002, “but that we are not in charge any more. The best fate for Africa would be if the old colonial powers, or their citizens, scrambled once again in her direction; on the understanding that this time they will not be asked to feel guilty.”

Johnson and his supporters usually claim he is being quoted out of context, or put his statements down to Johnsonian wit and love of rhetorical hyperbole. “Boris is Boris,” they chortle. Will that really wash if he becomes prime minister? Johnson is a classic example of arrested development: he remains the eternal privileged 15-year-old having everything done for him at Eton, devoid of empathy, failing to understand that words have consequences, useless with money (as his current inamorata has noted), utterly self-centred, childlike. You can see this play out once again in l’affaire turd, as the foreign office is left to clean up Johnson’s diplomatic mess with the help of an acquiescent broadcaster.

I'm a civil servant – and we can't make Boris Johnson's no-deal fantasy into reality | Anonymous Read more

Arrogance and lack of emotional intelligence no doubt explain many of his remarks but, as others have noted, beneath the endless layers of bluster there is a yearning for empire and a kernel of nationalism that ultimately led him to support Brexit in 2016. Reciting fragments of Rudyard Kipling’s poem Mandalay on a visit to a Buddhist temple in Myanmar in 2017 suggests that a nostalgic imperial vision still lurks in that atrophied adolescent brain.

The words of Mandalay are almost guaranteed to cause a war on the spot – and especially on this sacred spot: “An’ I seed her first a-smokin’ of a whackin’ white cheroot, / An’ a-wastin’ Christian kisses on an ’eathen idol’s foot: / Bloomin’ idol made o’ mud / Wot they called the Great Gawd Budd / Plucky lot she cared for idols when I kissed ’er where she stud! / On the road to Mandalay …” Yes, our foreign secretary really did think referencing that poem was appropriate.

Johnson’s racist remarks – set alongside equally outrageous examples of sexism and homophobia – should disqualify him as prime minister. Instead, they appear to endear him to the Tory membership, who feel an urgent need to out-Farage Farage, perhaps even to trump Trump. The US president gets away with it by being the leader of the world’s most powerful country, as Palmerston did when Britain was top dog in the 1860s. A Johnsonian UK will just look ridiculous. Xenophobia and gunboat diplomacy only really work if you have enough gunboats. Someone needs to tell Johnson that we no longer do.

• Stephen Moss is a feature writer at the Guardian