Loop through the events only once to detect both whether there is markdown and whether the markdown is inline. Fix more cases of false negatives in markdown detection, like whitespaces that are removed or the string beginning by a backslash escape.
.m.rule.contains_user_name