Questions tagged [backslash]

6 questions
3
votes
1 answer

Yasnippet including backslash

I would like to use Yasnippet to insert the template for a latex inline equation: \( \) The snippet is defined: # -*- Mode: snippet -*- # name: inline equation # key: ineq # -- \( \) But Yasnippet inserts only the parentheses ( ) without the…
Snelephant
  • 814
  • 1
  • 7
  • 17
2
votes
1 answer

How can I insert the backslash character ( \ ) before quotation marks (" ") in Emacs?

I am running Emacs and writing on the scratch-buffer. This is my config file. After executing describe-mode, this is the list of minor modes running: Enabled minor modes: Auto-Composition Auto-Compression Auto-Encryption Blink-Cursor Column-Number…
Pedro Delfino
  • 1,369
  • 3
  • 13
1
vote
1 answer

flush-lines fails in script but works when called otherwise

I'm very new to programming in Elisp so maybe the mistake is there but I'm completely stuck right now. I wanted to make a small, simple Elisp function to remove the AUTOs from my Verilog files so I don't commit those lines to our git repository…
Rice
  • 13
  • 3
1
vote
1 answer

re-search-forward Regex behavior for OR boolean

We usually use \| to depict OR in Regex. Using a\|b as input to Regexp I-search and Occur both gave the desired result. But re-search-forward seems unable to recognize this notation. abcdcba (re-search-forward "a\|b") ;; Search failed: "a|b"
Sati
  • 775
  • 6
  • 21
0
votes
1 answer

split-string: splitting on backslash character

I intend to apply the split-string function to the following string "\ghjky\dfsgi\45fdj\854f" using the character "\" as a separator in order to get the list ("ghjky" "dfsgi" "45fdj" "854f"). I could use the following function (split-string…
0
votes
2 answers

How to type a backslash in emacs "\"

I'm on Prelude, and there is no way I can type a \. I was thinking maybe I should create a keybinding but I don't know how to create it to output a character such as \. Any help welcome! Thank you!