The latter part at least is true. Sending "grossly offensive" messages is illegal under the Malicious Communications Act 1988 and the Communications Act 2003, specifically Section 127:
> a person is guilty of an offence if he—
> (a)sends by means of a public electronic communications network a message or other matter that is grossly offensive or of an indecent, obscene or menacing character; or
> (b)causes any such message or matter to be so sent.
I suspect the former is also true, but am not well-read in that area
If this concerns you I would advise not looking into pretty much any UK law which is full of subjective terms and ways to interpret them. The law isn’t an algorithm nor should it be. Just because you can’t understand how it works doesn’t mean it doesn’t work.
Sorry, that was a low shot, and not meant truthfully, but I just couldn’t resist making an offensive comment when the topic was “you can be arrested for offending someone”.
> a person is guilty of an offence if he—
> (a)sends by means of a public electronic communications network a message or other matter that is grossly offensive or of an indecent, obscene or menacing character; or
> (b)causes any such message or matter to be so sent.
I suspect the former is also true, but am not well-read in that area