all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Laurence Finston <lfinsto1@gwdg.de>
Subject: Problems with outline-minor-mode
Date: Sun, 18 Jul 2004 15:15:35 +0200 (MEST)	[thread overview]
Message-ID: <Pine.OSF.4.58.0407181514010.21704@gwdu70.gwdg.de> (raw)

Hello,

The headings below are interpreted correctly in
plain-tex-mode + outline-minor-mode but incorrectly in
c-mode + outline-minor-mode and c++-mode + outline-minor-mode.

Does anyone have an explanation for this?

I've tried this using:

GNU Emacs 21.3.1 (i386-pc-linux-gnu, X toolkit) of 2003-10-31 on raven,
modified by Debian.

and

GNU Emacs 21.2.1 (i586-suse-linux, X toolkit, Xaw3d scroll bars) of 2002-10-16 on D186


I'd like `/*\s-' to be recognized as a prefix, followed by a variable number of
dollar signs indicating the level of the heading.  However, the whitespace
characters are always counted in determining the heading level, so that
`/* $$ */' and `/*  $ */' are equivalent.

I've also tried to get the regular expression \s-*\*/ to be recognized
as the `outline-heading-end-regexp', but it hasn't worked, so that
`/* $' followed by whitespace and `\n' is a valid heading.
(I haven't tried this with GNU Emacs 21.2.1)

I've written a mode for use with
CWEB, but I've had to derive it from c-mode rather than c++-mode for this
reason.  Strangely enough, the headings work in my cweb-mode using
GNU Emacs 21.2.1.

Are the Emacs developers working on a CWEB-mode?  In Don Knuth's
_Digital Typesetting_ there's a photo caption that says so.  I'd like
to release the mode I've written as part of GNU 3DLDF, but if there's
going to be an official CWEB mode this probably wouldn't be a good idea,
or I'd have to change its name.

Thanks for your help.

Laurence Finston
GNU 3DLDF maintainer
http://www.gnu.org/software/3dldf/LDF.html

****************************************************************

(progn
  (plain-tex-mode)
  (outline-minor-mode t)
  (setq outline-regexp "/[ *$]+")
 )

(progn
  (c-mode)
  (outline-minor-mode t)
  (setq outline-regexp "/[ *$]+")
 )

(progn
 (plain-tex-mode)
 (outline-minor-mode t)
 (setq outline-regexp "/[ *$]+")
)





;; Headings.


/* $ */

/* $$ */

/* $$ */

/* $$$ */

/* $$ */

/* $ */

/* $$ */

/* $$$ */

/* $$$ */

/* $$$$ */

/* $$$ */

             reply	other threads:[~2004-07-18 13:15 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-18 13:15 Laurence Finston [this message]
     [not found] <mailman.316.1090156719.1960.bug-gnu-emacs@gnu.org>
2004-07-19 16:17 ` Problems with outline-minor-mode Kevin Rodgers
2004-07-19 16:30   ` Laurence Finston

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Pine.OSF.4.58.0407181514010.21704@gwdu70.gwdg.de \
    --to=lfinsto1@gwdg.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.