This was something I'd meant to include in the original proposal, and have added to my current working draft. Special characters like '@' MAY be sent in the original message, perhaps to show unsupporting clients that this was a mention. But implementations SHOULD include such characters within the range covered by the mention, so that both "user" and "@user" mentions can be formatted the same way. I haven't special-cased any characters in particular, as maybe rooms will use '#', or a different client might format it as "user," to look similar to existing clients. I hope that makes sense. On 11 March 2026 1:07:50 am UTC, Maxime Buquet <pep@bouah.net> wrote:
On 2026/03/10, Snit Guckfung via Standards wrote:
On Tue, 10 Mar 2026 18:47:05 +0100 Philipp Hörist <philipp@hoerist.com> wrote:
Hi,
Im a bit confused about begin/end
The XEP says
If a mention element of type urn:xmpp:mentions:0 or its subtypes contains both begin and end attributes, the receiving entity MAY use this as a hint that the specified range of the content is being addressed to the specified occupant.
I dont think this is necessary, as its usual that the content that follows the mention is addressed to the mentioned user.
What was missing was that we can special format the nickname or the @admin @all etc in the GUI when we receive a message, without hardcoding some regex or scanning for nicknames.
The 'begin' and 'end' attributes specify the range of the specially-formatted text. It is meant to be used to, for example, pillify text like "@room" or "@romeo". Note that there can be multiple mentions, and the content addressed to them isn't always what follows: "@romeo, have you seen @juliet?" has two mentions, with ranges specified for "@romeo" and "@juliet".
Just to be extra sure, the spec doesn't mention any special-cased "@" character. This is just an artifact used in clients UI and should not be observed on the wire, right?
I'm confused by the examples here.
Parameters begin and end here should not be concerned with any special character not part of what is used to refer to the mentioned occupant(s).
Some clients may display "@channel" as a keyword or sth but we agree that's not what is being transmitted. It would look more like a mention tag addressed to the channel. _______________________________________________ Standards mailing list -- standards@xmpp.org To unsubscribe send an email to standards-leave@xmpp.org