From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Narendra Joshi Newsgroups: gmane.emacs.help Subject: Re: Clearning a keymap completely Date: Mon, 5 Sep 2016 11:57:43 +0530 Message-ID: References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: blaine.gmane.org 1473056901 15465 195.159.176.226 (5 Sep 2016 06:28:21 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 5 Sep 2016 06:28:21 +0000 (UTC) Cc: "help-gnu-emacs@gnu.org" To: John Mastro Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Sep 05 08:28:16 2016 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bgnOB-0003OF-7d for geh-help-gnu-emacs@m.gmane.org; Mon, 05 Sep 2016 08:28:15 +0200 Original-Received: from localhost ([::1]:52541 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bgnO8-0006Uy-U8 for geh-help-gnu-emacs@m.gmane.org; Mon, 05 Sep 2016 02:28:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50007) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bgnNh-0006Ug-6r for help-gnu-emacs@gnu.org; Mon, 05 Sep 2016 02:27:46 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bgnNg-00069n-8G for help-gnu-emacs@gnu.org; Mon, 05 Sep 2016 02:27:45 -0400 Original-Received: from mail-ua0-x233.google.com ([2607:f8b0:400c:c08::233]:33047) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bgnNg-00069j-3h for help-gnu-emacs@gnu.org; Mon, 05 Sep 2016 02:27:44 -0400 Original-Received: by mail-ua0-x233.google.com with SMTP id 31so18785035uao.0 for ; Sun, 04 Sep 2016 23:27:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=FKD8xo9KBZmd24JZ77gapOyLaWNabTKTzx4PI0ZregM=; b=vomJv1TPvIusEGUOSvbUrz2seVWhVvCMgcH/WP1PuRXDN/MhJBy4XWQAEQycOKvqtd TG4CZMRxDd/9aR0DtFrBoFyQ27tI5YJhgxKx6/i4/sE/lK4+g4OhUaqHv7q1UbDWpc0d /js5r3gUzbU9c7yUHgKNIXdXImlT3VB9BYAHMZ6DZowFWUxnVbs63hRpZNPNNU1CC53D HkKQROrNV9fjeIzRHqkCvfR2tnNCd6GgH6D5ql3iVL423wLxVAYDGIiNEyB+hc5NUzB5 vy4PhAx7wLYSWig2mYP4rteKXFVOQjiPpaHMTe1O+M3kcnyyM7EZhWMhl9offXgniHjM NigQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=FKD8xo9KBZmd24JZ77gapOyLaWNabTKTzx4PI0ZregM=; b=HgeQeyEh/ZvrKqQurIA9HKkPjOXYTc+p6SfD8a4WOphEepPWq7jfob1dRB/JQ8ZL2m 2MoTf0wCROcbh/aHQdXJ7PChBh4i5ho8HpNkiNGZfSKa0BvJ+/fRsMIer8D788c33vGB gaHEUUNsqMvqIpoRfcc64GMfVqeB+qS/lNqczQbGa6NX8z389nEs29c5PtodG//7dq8g OUxvHfTLl3Wb6x//gFHjvHQ7ZXwiepFuTnc8FsTT4AMHXVfXSshvJ0rOLF9dhqv5NHFk ZId8ID2eLKtrAt6jUlqpF6LOE9bNV5bU781gxUWnVHgfLtR1J42ZtoFrmbyopHbquEHl BFpQ== X-Gm-Message-State: AE9vXwPnuv45hReNty6GW3S7RBf3je4IQ2DrxAG4ZFeqjXiwxdFK/Q+b7PgnUX2iAajPB1ghSucG+cZJbYppSw== X-Received: by 10.176.80.199 with SMTP id d7mr18309062uaa.139.1473056863677; Sun, 04 Sep 2016 23:27:43 -0700 (PDT) Original-Received: by 10.31.221.133 with HTTP; Sun, 4 Sep 2016 23:27:43 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2607:f8b0:400c:c08::233 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.help:111258 Archived-At: Thanks! Let binding inhibit-read-only worked. On Mon, Sep 5, 2016 at 9:33 AM, John Mastro wrote: >> Narendra Joshi wrote: >> >> I need to remove all the self-insert commands in a buffer. I want to >> be able to insert text into the buffer through emacs lisp but don't >> want the user to be able to insert text. How can this be done? > > Just make the buffer read only, and then let-bind inhibit-read-only > to t where necessary in your Lisp. > > https://www.gnu.org/software/emacs/manual/html_node/elisp/Read-Only-Buffers.html > > Hope that helps > > John