Questions tagged [characters]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
4
votes
1answer
831 views

Test char at point

I want to test if char at point is, let's say, "{" I found: (string= "{" (buffer-substring-no-properties (point) (+ 1 (point)))) and: (string-match-p "{" (what-cursor-position)) both working. ...
4
votes
2answers
965 views

Non-greedy regex not working

I can't seem to get the non-greedy regex to work. Sample String: ABCD,E《F》、《GH》、《XYIJ》、《KL》、《MN》。 Regex Code: 《.+?IJ》 Search Result: Because .+? is a non-greedy input, I was expecting the ...
2
votes
1answer
65 views

How to replace a digit by a letter?

I want to replace some digits by letters such that 1 ---> a 2 ---> b ... In emacs I have tried the following replacement: M-x query-replace-regexp RET \([0-9]+\) RET \,(string (+ ?a \#1)) RET ...