emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] [RFC] Org Minor Mode?


From: Thorsten Jolitz
Subject: Re: [O] [RFC] Org Minor Mode?
Date: Sun, 13 Apr 2014 18:00:01 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Nicolas Goaziou <address@hidden> writes:

> Hello,
>
> Thorsten Jolitz <address@hidden> writes:
>
>> What do you think - is there any chance that Org-mode switches from
>> static hardcoded regexp strings (all over the place) to dynamic
>> regexps calculated at runtime (using libraries like drx.el or rx.el)?
>
> I hope not. The syntax should stabilize, not drift away.

This is not so much about changing the syntax but rather about the
common programming practice to define and change/modify a variable or
constant in one place only. 

#+begin_src emacs-lisp
(defvar BOL "^") ; once 
(looking-at (concat BOL "foo")) ; many times
#+end_src

instead of

#+begin_src emacs-lisp
(looking-at "^foo") ; many times
#+end_src

The need to abstract from the Org star '*' too would only arise from
need to deal with Emacs Lisp coding conventions (;;; Level1 Headline),
which is a (unfortunately very important) special case. In all other
cases it would be only about BOL ("^") and EOL ("$") in regexps.

>> There would be a cost definitely, but then a true org-minor-mode could
>> become reality that offers the full power of Org-mode in programming
>> mode's comment section (I'm actually working on it by merging outshine
>> with orgstruct: [[https://github.com/tj64/omm][omm.el]]).

> I don't see why you would need the "full power of Org-mode" (whatever
> that means) in mere comments. 

That means that Org headlines are much more 'intelligent' than outline
headlines (they know about todos, priorities, tags, timestamps,
properties, planning, clocking, being archived etc.) and one could
have that kind of intelligent headlines in other modes too with a true
org-minor-mode.

-- 
cheers,
Thorsten




reply via email to

[Prev in Thread] Current Thread [Next in Thread]