Hi Nicolas,
>> I'm trying to define a new emphasis > > Please don't. We're in the process of hard-coding emphasis markers. OK. Understood. >> that would work like org-code (=) except that it would export to >> \textsf instead of \texttt in LaTeX. > > If that's related to export, you can tweak the export of verbatim > (=text=) output. > > For example, in the new exporter (if you use development Org, you can > (require 'org-export) and just call M-x org-export-dispatch), it just > means to change \texttt into \textsf through verbatim filters (list of > function applied to the output of each verbatim object). > > It's a way to have the last words over export engine. > > Here is the code: > > #+begin_src emacs-lisp > (defun my-latex-verbatim-filter (text backend info) > "In `e-latex' backend, change \"texttt\" into \"textsf\"." > ;; No change for other backends. > (if (not (eq backend 'e-latex)) text > (replace-regexp-in-string "\\`\\\\texttt" "\\\\textsf" text))) > > (add-to-list 'org-export-filter-verbatim-functions 'my-latex-verbatim-filter) > #+end_src > > If you call `org-export-dispatch' on a buffer containing: > > =look_at:my~ti ny\reference^string= > > you will get: > > \textsf{look\_at:my\textasciitilde{}ti > ny\textbackslash{}reference\textasciicircum{}string} My goal is, in fact, to keep the default behavior of the '=' marker and redefine the behavior of the '~' marker. I'd like '~' to behave exactly the same way = does but using \textsf instead of \texttt. Is it possible? Thanks, Francesco