emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Francesco Pizzolante" <fpz-djc/iPCCuDYQheJpep6IedvLeJWuRmrY@public.gmane.org>
To: mailing-list-org-mode <emacs-orgmode-mXXj517/zsQ@public.gmane.org>
Subject: [PATCH] Avoid all modification hooks in org-unmodified
Date: Wed, 30 Jan 2013 16:59:51 +0100	[thread overview]
Message-ID: <87y5fafyq0.fsf@somewhere.org> (raw)

Hello,

I've changed org-unmodified in order to avoid all modification hooks to be
called (not only before-change-functions and after-change-functions, but also
first-change-hook).

I've used inhibit-modification-hooks as described here:
http://www.gnu.org/software/emacs/manual/html_node/elisp/Change-Hooks.html

In my case, this positively impacts the loading of the agenda.

Regards,
 Francesco

From 173526db9d9b925e9eb568a725647e4065f0e27c Mon Sep 17 00:00:00 2001
From: Francesco Pizzolante <fpz-djc/iPCCuDYQheJpep6IedvLeJWuRmrY@public.gmane.org>
Date: Wed, 30 Jan 2013 16:09:22 +0100
Subject: [PATCH] Avoid all modification hooks in org-unmodified

* org-macs.el (org-unmodified): Avoid all modification hooks in org-unmodified

TINYCHANGE
---
 lisp/org-macs.el |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/lisp/org-macs.el b/lisp/org-macs.el
index a44bdbe..ceee306 100644
--- a/lisp/org-macs.el
+++ b/lisp/org-macs.el
@@ -93,7 +93,7 @@ Also, do not record undo information."
   `(set-buffer-modified-p
     (prog1 (buffer-modified-p)
       (let ((buffer-undo-list t)
-	    before-change-functions after-change-functions)
+	    (inhibit-modification-hooks t))
 	,@body))))
 (def-edebug-spec org-unmodified (body))
 
-- 
1.7.9

             reply	other threads:[~2013-01-30 15:59 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-30 15:59 Francesco Pizzolante [this message]
2013-01-30 16:54 ` [PATCH] Avoid all modification hooks in org-unmodified Bastien
     [not found]   ` <87r4l28vbw.fsf-E3UqQZAQFPqWIDz0JBNUog@public.gmane.org>
2013-01-31  9:00     ` Francesco Pizzolante

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87y5fafyq0.fsf@somewhere.org \
    --to=fpz-djc/ipccudyqhejpep6iedvlejwurmry@public.gmane.org \
    --cc=emacs-orgmode-mXXj517/zsQ@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).