bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Local variable "mode" breaks hide-show mode


From: John Kodis
Subject: Local variable "mode" breaks hide-show mode
Date: Wed, 01 Jan 2003 13:38:18 -0500

In GNU Emacs 21.2.1 (i686-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2002-08-28 on astest
configured using `configure  --host=i686-pc-linux-gnu --build=i686-pc-linux-gnu 
--target=i386-redhat-linux-gnu --program-prefix= --prefix=/usr 
--exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc 
--datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib 
--libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/usr/com 
--mandir=/usr/share/man --infodir=/usr/share/info --with-gcc --with-pop 
--with-sound'
Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: en_US
  locale-coding-system: iso-latin-1
  default-enable-multibyte-characters: t

I enabled the hide-show minor mode and the automatic hiding of any
initial comment block by creating a .emacs file containing only:

(add-hook 'c-mode-common-hook
 '(lambda ()
    (hs-minor-mode)
    (hs-hide-initial-comment-block)))

When editing the following C program (program fragment really -- I
deleted all the irrelevant bits to better explore the problem), the
hide-show minor mode kicks in, and the initial comment block gets
hidden.  However, I am unable to unhide the initial comment block.
Neither M-x hs-show-all nor clicking shift-button-2 on the initial
comment block has any effect.

/* 
 *  commentary goes here
 */

int main() { return 0; }

// Local Variables:
// mode: C
// End:

I found that I was able to work around this problem by simply
capitalizing the word "mode" in the local variables block!



reply via email to

[Prev in Thread] Current Thread [Next in Thread]