From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bastien Subject: Re: Electric insert of headline stars Date: Thu, 25 Oct 2007 12:29:36 +0100 Message-ID: <87y7dre8kf.fsf@bzg.ath.cx> References: <3c12eb8d0710250315r633d0c9au1fdcc8c8000437b@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Ikzye-0005lA-P2 for emacs-orgmode@gnu.org; Thu, 25 Oct 2007 06:30:13 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Ikzyc-0005iF-4G for emacs-orgmode@gnu.org; Thu, 25 Oct 2007 06:30:10 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IkzyY-0005hU-Jj for emacs-orgmode@gnu.org; Thu, 25 Oct 2007 06:30:06 -0400 Received: from ug-out-1314.google.com ([66.249.92.171]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IkzyR-0007i9-KE for emacs-orgmode@gnu.org; Thu, 25 Oct 2007 06:30:00 -0400 Received: by ug-out-1314.google.com with SMTP id a2so533255ugf for ; Thu, 25 Oct 2007 03:29:31 -0700 (PDT) In-Reply-To: <3c12eb8d0710250315r633d0c9au1fdcc8c8000437b@mail.gmail.com> (Piotr Zielinski's message of "Thu, 25 Oct 2007 11:15:46 +0100") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Hi Piotr, "Piotr Zielinski" writes: > (defun local-org-insert-stars () > (interactive) > (when (looking-back "^ *" (point-at-bol)) ^ ^ This should be "+", otherwise you get a message saying "Replaced 0 occurrence" when you insert a "*" at the beginning of the line. Also remark that this is not suitable for people using "*" for list items, although the manual suggests using "*" for list items is not a very good idea. Anyway, i guess this might be useful for some people, thanks! -- Bastien