From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?ISO-8859-1?Q?Rodrigo_Gonz=E1lez_del_Cueto?= Newsgroups: gmane.emacs.help Subject: Re: Customizing C Indentation Date: Mon, 13 Apr 2015 19:54:05 -0700 (PDT) Message-ID: <7eac77d6-767a-4f38-a9cd-2030349af9c7@googlegroups.com> References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1428980118 2663 80.91.229.3 (14 Apr 2015 02:55:18 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 14 Apr 2015 02:55:18 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Apr 14 04:55:17 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Yhr0P-0003de-GU for geh-help-gnu-emacs@m.gmane.org; Tue, 14 Apr 2015 04:55:17 +0200 Original-Received: from localhost ([::1]:54012 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yhr0O-0002Zg-VT for geh-help-gnu-emacs@m.gmane.org; Mon, 13 Apr 2015 22:55:16 -0400 X-Received: by 10.182.248.195 with SMTP id yo3mr16440503obc.34.1428980045608; Mon, 13 Apr 2015 19:54:05 -0700 (PDT) X-Received: by 10.182.106.131 with SMTP id gu3mr112085obb.25.1428980045587; Mon, 13 Apr 2015 19:54:05 -0700 (PDT) Original-Path: usenet.stanford.edu!l13no5063050iga.0!news-out.google.com!db6ni15569igc.0!nntp.google.com!l13no5063049iga.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=200.78.177.170; posting-account=A29A8woAAACKlzKP-HQhfnDB3hen9hCu Original-NNTP-Posting-Host: 200.78.177.170 User-Agent: G2/1.0 Injection-Date: Tue, 14 Apr 2015 02:54:05 +0000 Original-Xref: usenet.stanford.edu gnu.emacs.help:211424 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 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-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:103706 Archived-At: On Monday, April 13, 2015 at 5:52:49 PM UTC-5, Rodrigo Gonz=E1lez del Cueto= wrote: > Hey all, >=20 > I hope you could help me figure out how to customize Emacs to indent code= in the following way. >=20 > I'm working on an EDK related project. And the EDK code standards state t= he following: >=20 > "Subsequent lines of multi-line function calls should line up one or two = tab- > stops from the beginning of the function name." >=20 > Example: >=20 > Status =3D gRT->GetVariable( > NORMAL_SETUP_NAME, > &gEfiNormalSetupGuid, > NULL, > &VarSize, > &SystemConfiguration > ); >=20 > So given a function call, the arglist-intro offset, should make reference= to the position of the first character of the function being called, and f= rom there, go up an indentation level. >=20 > I've read the Emacs documentation, and I only understood how to indent in= relation to the previous line's indentation level. But I haven't been able= to understand how to move within the previous line's content. >=20 > -Rodrigo Just realized that the code example format doesn't look the same in every c= omputer. I'll link to the Github source code line, for a better view. https://github.com/tianocore/edk2/blob/5d6bf9e22973c2ad327ca7422f80144c8489= 12dc/Vlv2TbltDevicePkg/PlatformInfoDxe/PlatformInfoDxe.c#L67