From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Abrahamsen Subject: Re: function for inserting a block Date: Wed, 08 Nov 2017 08:01:15 -0800 Message-ID: <8760akwyic.fsf@ericabrahamsen.net> References: <877exghblx.fsf@ericabrahamsen.net> <87po9q2e8k.fsf@nicolasgoaziou.fr> <87tvyyvpst.fsf@ericabrahamsen.net> <87fuaiz069.fsf@nicolasgoaziou.fr> <87lgk9eo4d.fsf@ericabrahamsen.net> <87fuahxxvs.fsf@nicolasgoaziou.fr> <87r2u1cuwj.fsf@ericabrahamsen.net> <87infdctzq.fsf@ericabrahamsen.net> <87k1zsbizs.fsf@ericabrahamsen.net> <87k1zp4rxj.fsf@ericabrahamsen.net> <871slx4j6p.fsf@ericabrahamsen.net> <87376btslq.fsf@nicolasgoaziou.fr> <87vaj7oyxb.fsf@ericabrahamsen.net> <871sl9ow44.fsf@gnu.org> <87fu9pgfkj.fsf@nicolasgoaziou.fr> <87tvy5nf0q.fsf@gnu.org> <87bmkchp1x.fsf@nicolasgoaziou.fr> <878tfg7sbg.fsf@bzg.fr> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:42178) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eCSoy-0002xh-GK for emacs-orgmode@gnu.org; Wed, 08 Nov 2017 11:03:21 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eCSot-0000EM-SV for emacs-orgmode@gnu.org; Wed, 08 Nov 2017 11:03:20 -0500 Received: from [195.159.176.226] (port=57751 helo=blaine.gmane.org) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eCSot-0000De-LA for emacs-orgmode@gnu.org; Wed, 08 Nov 2017 11:03:15 -0500 Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1eCSoe-0008Ta-Da for emacs-orgmode@gnu.org; Wed, 08 Nov 2017 17:03:00 +0100 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" To: emacs-orgmode@gnu.org Bastien Guerry writes: > Hi Nicolas, > > Nicolas Goaziou writes: > >> Bastien writes: >> >>> is there a simple mechanism in Emacs core to restore the same >>> functionnality? >> >> Of course, it is called Abbrev mode: (info "(emacs)Abbrev >> Concepts"). > > Abbrev only expands on words constituents, so " >> You may also use (info "(autotype)Using Skeletons") for more advanced >> uses. > > I see. So combining the two, we would have something like this: > > (define-skeleton org-skeleton-src-block > "" nil > > > "#+begin_src" \n > _ \n > "#+end_src") > > (define-abbrev org-mode-abbrev-table " "" 'org-skeleton-src-block) > > ... modulo the restriction on " > I need to think about this and Kaushal proposal to see if we can > come up with a simple and backward-compatible solution. > > Already thanks for the pointers. I'd be happy to add something to the manual, once we've got a clear way of replicating the old system.