From mboxrd@z Thu Jan 1 00:00:00 1970 From: Aaron Ecay Subject: Re: Buffer is read-only: # Date: Mon, 17 Sep 2012 00:36:09 -0400 Message-ID: <87392hgtae.fsf@gmail.com> References: <87vcfdzgkj.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([208.118.235.92]:50914) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TDT4A-0004pM-Rs for emacs-orgmode@gnu.org; Mon, 17 Sep 2012 00:36:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TDT49-0000vX-Ss for emacs-orgmode@gnu.org; Mon, 17 Sep 2012 00:36:14 -0400 Received: from mail-qa0-f41.google.com ([209.85.216.41]:34518) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TDT49-0000u5-Nh for emacs-orgmode@gnu.org; Mon, 17 Sep 2012 00:36:13 -0400 Received: by qafk30 with SMTP id k30so1614794qaf.0 for ; Sun, 16 Sep 2012 21:36:13 -0700 (PDT) In-Reply-To: <87vcfdzgkj.fsf@gmail.com> 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: Org-mode OK, I=E2=80=99ve tracked this down. I added a function to =E2=80=98org-agenda-finalize-hook=E2=80=99 which makes modifications to the= agenda buffer (viz. removing the 'mouse-highlight text properties). At line 3441 of org-agenda.el, in the =E2=80=98org-agenda-finalize=E2=80=99 functio= n, this hook is run outside of any (let ((inhibit-read-only t)) ...). This gives the error. Only some types of agenda buffers are set to be read-only =E2=80=93 e.g. =E2=80=98org-todo-list=E2=80=99 sets read-only at l. 4418 of org-agend= a.el. I think =E2=80=98org-agenda-finalize-hook=E2=80=99 should be run with inhibit= -read-only bound to t, to let the hook modify the agenda buffer in any case. But otherwise, it should be added to the hook=E2=80=99s documentation that any changes to the agenda buffer could be turned into an error by a read-only setting. --=20 Aaron Ecay