[Standards] Proposed XMPP Extension: Styling

Goffi goffi at goffi.org
Mon Nov 6 21:23:30 UTC 2017


Le lundi 6 novembre 2017, 22:14:21 CET Daniel Gultsch a écrit :
> 2017-11-06 22:06 GMT+01:00 Goffi <goffi at goffi.org>:
> > Le lundi 6 novembre 2017, 22:04:29 CET Daniel Gultsch a écrit :
> >> 2017-11-06 21:58 GMT+01:00 Goffi <goffi at goffi.org>:
> >> > Le lundi 6 novembre 2017, 21:53:48 CET Daniel Gultsch a écrit :
> >> >> 2017-11-06 21:46 GMT+01:00 Goffi <goffi at goffi.org>:
> >> >> > And you have no indication of markup, so if I copy/paste some code
> >> >> > for
> >> >> > instance, some client will render it with markup,
> >> >> 
> >> >> I think it is possible to avoid those 'false positives' to some
> >> >> degree. The limited amount of keywords and other rules (has to start
> >> >> with whitespace, not interupted by newline) already work quite well.
> >> >> If you come up with an example of a piece of code that will end up
> >> >> being styled even though it is not supposed to we can maybe fix this
> >> >> be slightly changing the rules.
> >> > 
> >> > Are you suggesting to do heuristic to detect if if a text use a markup
> >> > or
> >> > not?
> >> 
> >> No I'm implying that the current syntax already has very few false
> >> positives and we might be able to bring down the rate of false
> >> positives even more by changing the syntax slightly. But for that to
> >> work I need an example of a false positive.
> > 
> > "Wow, I can write in `monospace`, even a literal ``backtick
> > (`)``!"
> 
> I'm not really sure how you want this to be rendered or what this
> actually means but if you send me the text in between the " it will
> render like this: https://gultsch.de/files/monospace.png which seems
> fine?!
> 
> But I meant more like provide an example of (valid) code you would
> actually paste in real life not some constructed example to 'break'
> the parser.

I took this example because it is in the XEP, so obviously not made to break 
the parser. The point is if you want to paste this simple example to explain 
how to use the syntax, it will render differently depending on the client 
supporting (and using) the XEP or not. In your screenshot it would be bad as 
the monospace backquotes are not displayed.

++
Goffi


More information about the Standards mailing list