Properly bracket unicode encoding

The unicode encoding functionality uses `&` as a delimiter, so text with `&` in would get encoded, and come out as `&-`, unless using the unicode keyboard, which properly decoded it back to its original form. (For error, see #3435).

The solution is to pass in the flag for using the unicode encoding, if the cap is set, and only encode if it is on.