I don’t think TextEdit provides any way to arbitrarily change the color of a single “inline” (not separated) character. That said, the issue you highlight with the two add_color_region calls looks like a bug of some sort.
With your code, the - doesn’t work as you indicated. However, if you reverse the order of the assignments, the + doesn’t work. So, it seem the first assignment is ok, but the second one is bugged.
Here’s a related question, with a link to a PR that could improve the situation in the future…
I already reported the bug I have found 4 already xd. I didn’t check if there was another issue with the same problem in this case but now I can add the new information about the second assignment not working thanks. I also mentioned on that issue thatadd_keyword_color is not working at all with symbols idk if this is intended the documentation says it will take a strings but these strings didn’t work.