1

How can I redefine \verb!! to translate into \url{}? I have to do this to fool Emacs highlighting so it thinks I have \verb, in the background I like \url{} wrapping capability.

Joseph Wright
  • 259,911
  • 34
  • 706
  • 1,036
BBSysDyn
  • 175
  • 1
    \let\verb\url?! – cgnieder Mar 21 '12 at 15:45
  • Am I correct in thinking this is only so your editor (Emacs) is happy in some way, or is this actually about the LaTeX output you get? – Joseph Wright Mar 21 '12 at 15:49
  • I could not find a way to make Emacs highlight \url the way \verb is highlighted, so I fixed it on the Latex side. It is a hack, big time, but it works now. – BBSysDyn Mar 21 '12 at 15:53
  • 9
    I think that if you asked How to get Emacs properly highlight \url, you would get a sufficient answer. This is, in my opinion, a typical example of the XY problem. – yo' Mar 21 '12 at 16:54

1 Answers1

1

Even if you apparently asked the wrong question (see tohecz's comment) it's solution is

\let\verb\url

See for example this question and its answers for an explanation of \let.

cgnieder
  • 66,645