From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.help Subject: Re: c-hanging-braces-alist customization shows no syntactic symbols Date: Thu, 18 Dec 2003 08:35:53 +0000 Organization: muc.de e.V. -- private internet access Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: <9torrb.t8.ln@acm.acm> References: NNTP-Posting-Host: deer.gmane.org X-Trace: sea.gmane.org 1071739190 14135 80.91.224.253 (18 Dec 2003 09:19:50 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 18 Dec 2003 09:19:50 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Dec 18 10:19:43 2003 Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AWuJq-0000l8-00 for ; Thu, 18 Dec 2003 10:19:42 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AWvCb-0007VR-Qn for geh-help-gnu-emacs@m.gmane.org; Thu, 18 Dec 2003 05:16:17 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!news.belwue.de!news.tesion.net!news.space.net!news.muc.de!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 85 Original-NNTP-Posting-Host: acm.muc.de Original-X-Trace: marvin.muc.de 1071738299 81680 193.149.49.134 (18 Dec 2003 09:04:59 GMT) Original-X-Complaints-To: news-admin@muc.de Original-NNTP-Posting-Date: 18 Dec 2003 09:04:59 GMT User-Agent: tin/1.4.5-20010409 ("One More Nightmare") (UNIX) (Linux/2.0.35 (i686)) Original-Xref: shelby.stanford.edu gnu.emacs.help:119464 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:15404 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:15404 Stephanos Piperoglou wrote on Wed, 17 Dec 2003 17:48:43 +0200: > GNU Emacs 21.3 / Windows 2000 + CygWin > I'm trying to customize my c-hanging-braces-alist and custom doesn't > show the list of syntactic symbols correctly. See below for a snippet > of what I get when I M-x customize-variable c-hanging-braces-alist. As > you can see custom has trouble getting these symbols, ..... The customize interface doesn't seem very helpful for this sort of variable. To use it, you'd first have to click on the "Override Style settings" button, then fill in each line, one by one. A typical such line looks like this, after being filled in: [X] substatement-open : [Choice] Newline [ ] before, [X] after brace > .... and I can find nowhere where the entire list is mentioned and > documented. It's in the CC Mode manual, page "Hanging Braces". (I'm sure I don't need to say this to you, but to get there, do C-h i m cc mode i hanging .) > .... I don't mind hacking my .emacs file by hand for these (in fact I'd > rather define my own c-style, as this is meant for use with JDE), so my > question really is where can I get a list of syntactic symbols that > apply to c-hanging-braces-alist? That's the "Hanging Braces" page. I agree with your suggestion that you'd be better editing your .emacs directly, and defining your own style would be better still. > Is this a known issue in 21.3? Is it fixed in the devel branch? Maybe, and almost certainly no. I think what you're suggesting is that instead of this blank template: > ==== SNIP ==== > ( ) Override style settings: > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > [ ] nil : Choice Newline [ ] before, [ ] after brace > State: this option has been set and saved. > ==== SNIP ==== , onto which you add the syntactic symbols you're interested in, you should get a complete list of relevant syntactic symbols, something like: [ ] brace-list-open : [Choice] Newline [ ] before, [ ] after brace [ ] brace-entry-open : [Choice] Newline [ ] before, [ ] after brace [ ] statement-cont : [Choice] Newline [ ] before, [ ] after brace .... I'm sure this ought to be possible, and it would seem to be desirable. Two suggestions: (1) send a request to the CC Mode mailing list at bug-cc-mode@gnu.org asking for this; (2) (If you're at home with Emacs macros and are feeling really brave :-) Make sure you've got a sufficiently recent version of CC Mode (5.30.8 is currently current), get into cc-vars.el (where c-hanging-braces-alist and defcustom-c-style-var are defined) and fix it. CC Mode is available from . -- Alan Mackenzie (Munich, Germany) Email: aacm@muuc.dee; to decode, wherever there is a repeated letter (like "aa"), remove half of them (leaving, say, "a").