From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Steinar Bang Newsgroups: gmane.emacs.help Subject: Problem indenting nested Java annotations Date: Tue, 02 May 2017 20:25:17 +0200 Message-ID: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1493757433 1533 195.159.176.226 (2 May 2017 20:37:13 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 2 May 2017 20:37:13 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (windows-nt) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue May 02 22:37:09 2017 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d5eXk-0000JD-Ow for geh-help-gnu-emacs@m.gmane.org; Tue, 02 May 2017 22:37:08 +0200 Original-Received: from localhost ([::1]:33583 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d5eXq-0000Tk-GE for geh-help-gnu-emacs@m.gmane.org; Tue, 02 May 2017 16:37:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33618) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d5cUX-0002r1-A1 for help-gnu-emacs@gnu.org; Tue, 02 May 2017 14:25:42 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d5cUT-0000Tc-R0 for help-gnu-emacs@gnu.org; Tue, 02 May 2017 14:25:41 -0400 Original-Received: from cadalora.default.sbang.uk0.bigv.io ([46.43.15.90]:46749 helo=cadalora.bang.priv.no) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d5cUT-0000Ga-H9 for help-gnu-emacs@gnu.org; Tue, 02 May 2017 14:25:37 -0400 Original-Received: from NOLSBANG02 (cm-84.208.228.77.getinternet.no [84.208.228.77]) by cadalora.bang.priv.no (Postfix) with ESMTPSA id 1B998CD341 for ; Tue, 2 May 2017 19:25:19 +0100 (BST) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 46.43.15.90 X-Mailman-Approved-At: Tue, 02 May 2017 16:34:57 -0400 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 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 Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:112931 Archived-At: Platform: GNU Emacs 25.1.1 (x86_64-w64-mingw32) of 2016-11-15 CC Mode version 5.33 I have the following nested Java annotations, that I would like indented thus: @Properties({ @Property(name = Constants.PROPERTY_NAME, value = "propval"), @Property(name = Constants.PROPERTY_NAME2, value = "propval2")}) @Named("hello2") public class HelloServiceProviderNamedAndPropertiesHello2 implements Provider, HelloService { public String getMessage() { return "Hello2 says hi!"; } } Instead, I get the following: @Properties({ @Property(name = Constants.PROPERTY_NAME, value = "propval"), @Property(name = Constants.PROPERTY_NAME2, value = "propval2")}) @Named("hello2") public class HelloServiceProviderNamedAndPropertiesHello2 implements Provider, HelloService { public String getMessage() { return "Hello2 says hi!"; } } Is there a way to get what I want? Thanks! - Steinar Here are my current c-offsets-alist settings: ((inexpr-class . +) (inexpr-statement . +) (lambda-intro-cont . +) (inlambda . c-lineup-inexpr-block) (template-args-cont c-lineup-template-args +) (incomposition . +) (inmodule . +) (innamespace . +) (inextern-lang . +) (composition-close . 0) (module-close . 0) (namespace-close . 0) (extern-lang-close . 0) (composition-open . 0) (module-open . 0) (namespace-open . 0) (extern-lang-open . 0) (objc-method-call-cont c-lineup-ObjC-method-call-colons c-lineup-ObjC-method-call +) (objc-method-args-cont . c-lineup-ObjC-method-args) (objc-method-intro . [0]) (friend . 0) (cpp-define-intro c-lineup-cpp-define +) (cpp-macro-cont . +) (cpp-macro . [0]) (inclass . +) (stream-op . c-lineup-streamop) (arglist-cont-nonempty c-lineup-gcc-asm-reg c-lineup-arglist) (arglist-cont c-lineup-gcc-asm-reg 0) (comment-intro c-lineup-knr-region-comment c-lineup-comment) (catch-clause . 0) (else-clause . 0) (do-while-closure . 0) (case-label . *) (substatement . +) (statement-case-intro . *) (statement . 0) (brace-entry-open . 0) (brace-list-entry . 0) (brace-list-intro . +) (brace-list-close . 0) (brace-list-open . 0) (block-close . 0) (block-open . 0) (inher-intro . +) (member-init-cont . c-lineup-multi-inher) (member-init-intro . +) (annotation-var-cont . +) (annotation-top-cont . 0) (topmost-intro . 0) (knr-argdecl . 0) (inline-close . 0) (class-close . 0) (class-open . 0) (defun-block-intro . +) (defun-close . 0) (defun-open . 0) (c . c-lineup-C-comments) (string . c-lineup-dont-change) (func-decl-cont . c-lineup-java-throws) (inher-cont . c-lineup-java-inher) (access-label . 0) (arglist-close . c-lineup-arglist) (arglist-intro . +) (statement-cont . +) (statement-case-open . +) (label . +) (substatement-label . +) (substatement-open . 0) (knr-argdecl-intro . 5) (statement-block-intro . +) (topmost-intro-cont . +) (inline-open . 0))