On 05/22/2010 03:38 PM, Ralf Angeli wrote:
> * Ralf Hemmecke (2010-05-21) writes:
> 
>> My .emacs file is
>>
>> ---rhxBEGIN .emacs
>> (custom-set-variables
>>  '(LaTeX-verbatim-environments (quote ("verbatim" "verbatim*"
>> "myverbatim")))
>>  '(inhibit-startup-screen t))
>> (custom-set-faces)
>> ---rhxEND .emacs
>>
>> The highlighting in the file p.tex below is wrong.
> 
> I don't see a problem with the CVS version of AUCTeX and I expect this
> to be the same with 11.86.

Does that help...
http://sites.google.com/site/hemmecke/emacs-auctex-verbatim-bug
And it is 11.85 in Ubuntu Lucid. Sorry, I first have to figure out how
to convince my emacs to load my local cvs-auctex-checkout instead of the
system-wide one. Any hints?

>> ---rhxBEGIN p.tex
>> \documentclass[a4paper]{article}
>> \usepackage{listings}
>> \lstnewenvironment{myverbatim}%
>>   {\lstset{basicstyle=\scriptsize\ttfamily,gobble=2}}%
>>   {}
>> \lstset{basicstyle=\scriptsize}
>> \begin{document}
>> Also put a % right after {verbatim} and look what happens
>> with the highlighting.
>> \begin{verbatim}
> 
> IIRC it is unsafe to add stuff like a comment starter on the same line
> after \begin{verbatim}.  Unfortunately I don't remember where I read
> this and what the exact issue was.

Why should that be unsafe? For auctex or for latex?
You've probably read that putting characters after an \end{verbatim}
might result in losing these characters in the latex output. But with a
% I want to ignore them anyway. (With \usepackage{verbatim} there is not
such a problem. Also \usepackage{listings} has a more robust way to
recognize the ending string.

Auctex should not interpret comment signs in verbatim environments.

Ralf
Well, I should put my last name, too. Otherwise other mailing list
readers get confused. But I'm so lazy. ;-)

_______________________________________________
bug-auctex mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-auctex

Reply via email to