From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: [PATCH] Do not indent option keywords Date: Fri, 10 May 2013 08:26:25 +0200 Message-ID: <41207E77-189F-40AB-909D-3581EFA38288@gmail.com> References: <8738twge3b.fsf@Rainer.invalid> <87txmbgaeg.fsf@Rainer.invalid> Mime-Version: 1.0 (Mac OS X Mail 6.3 \(1503\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([208.118.235.92]:57405) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uagmj-0003aZ-Pq for emacs-orgmode@gnu.org; Fri, 10 May 2013 02:26:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Uagmg-0006Rx-OI for emacs-orgmode@gnu.org; Fri, 10 May 2013 02:26:29 -0400 Received: from mail-wi0-x236.google.com ([2a00:1450:400c:c05::236]:58279) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uagmg-0006Rl-Hf for emacs-orgmode@gnu.org; Fri, 10 May 2013 02:26:26 -0400 Received: by mail-wi0-f182.google.com with SMTP id m6so268301wiv.9 for ; Thu, 09 May 2013 23:26:25 -0700 (PDT) In-Reply-To: <87txmbgaeg.fsf@Rainer.invalid> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Achim Gratz Cc: emacs-orgmode@gnu.org Hi Achim, by decoration you mean font-lock support? Maybe this would be a better fix: Modified lisp/org.el diff --git a/lisp/org.el b/lisp/org.el index 745fb82..43df094 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -5867,7 +5867,8 @@ by a #." ((or (equal dc1 "+results") (member dc1 '("+begin:" "+end:" "+caption:" "+label:" "+orgtbl:" "+tblfm:" "+tblname:" = "+results:" - "+call:" "+header:" "+headers:" "+name:")) + "+call:" "+header:" "+headers:" "+name:" + "+options:")) (and (match-end 4) (equal dc3 "+attr"))) (add-text-properties beg (match-end 0) - Carsten On 9.5.2013, at 22:34, Achim Gratz wrote: > That was not the patch I was trying to send, sorry. Second try: >=20 > =46rom 990257c497aa9fb0b8250d770c8e899762cc7abc Mon Sep 17 00:00:00 = 2001 > From: Achim Gratz > Date: Thu, 9 May 2013 22:30:08 +0200 > Subject: [PATCH] org.el: do not indent option keyword lines >=20 > * lisp/org.el (org-indent-line): Keep option keyword lines at column > zero so they don't lose their decoration. > --- > lisp/org.el | 7 +++++++ > 1 file changed, 7 insertions(+) >=20 > diff --git a/lisp/org.el b/lisp/org.el > index 08570c3..b357c90 100644 > --- a/lisp/org.el > +++ b/lisp/org.el > @@ -21932,6 +21932,11 @@ (defun org-indent-line () > (org-inlinetask-in-task-p))) > (inline-re (and inline-task-p > (org-inlinetask-outline-regexp))) > + (opt-re (org-make-options-regexp > + '("CATEGORY" "TODO" "COLUMNS" "STARTUP" "ARCHIVE" > + "LINK" "PRIORITIES" "CONSTANTS" "PROPERTY" "DRAWERS" > + "SETUPFILE" "OPTIONS") > + "\\(?:[a-zA-Z][0-9a-zA-Z_]*_TODO\\)")) > column) > (if (and orgstruct-is-++ (eq pos (point))) > (let ((indent-line-function (cadadr (assoc 'indent-line-function = org-fb-vars)))) > @@ -21976,6 +21981,8 @@ (defun org-indent-line () > (org-get-indentation (match-string 0)))) > (t > (org-get-indentation (match-string 0)))))) > + ;; Option keywords > + ((looking-at opt-re) (setq column 0)) > ;; This line has nothing special, look at the previous relevant > ;; line to compute indentation > (t > --=20 > 1.8.2.1 >=20 >=20 >=20 > Regards, > Achim. > --=20 > +<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+ >=20 > Samples for the Waldorf Blofeld: > http://Synth.Stromeko.net/Downloads.html#BlofeldSamplesExtra