emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Michael Sperber <sperber@deinprogramm.de>
To: "Dr. Volker Zell" <dr.volker.zell@oracle.com>
Cc: Dan Davison <davison@stats.ox.ac.uk>,
	mailing-list-org-mode Mode <emacs-orgmode@gnu.org>,
	Carsten Dominik <carsten.dominik@gmail.com>
Subject: PATCH: Xemacs incompatibilities
Date: Mon, 24 May 2010 10:39:48 +0200	[thread overview]
Message-ID: <y9l1vd1k817.fsf_-_@deinprogramm.de> (raw)
In-Reply-To: <7z1vd67cwp.fsf@vzell-de.de.oracle.com> (Volker Zell's message of "Thu, 20 May 2010 18:31:34 +0200")

[-- Attachment #1: Type: text/plain, Size: 492 bytes --]


"Dr. Volker Zell" <dr.volker.zell@oracle.com> writes:

>  o XEmacs 21.4 (patch 22) "Instant Classic" [Lucid] (i686-pc-cygwin, Mule) of Sat Jan 31 2009 on vzell-de

Ah ... OK, this is a 21.4 issue.  The attached patch fixes it.

`write-contents-hooks' is not buffer-local by default in 21.4, which is
why the the hook for exiting the org-src mode gets run when anything
saved, and that checks for the mode.

-- 
Cheers =8-} Mike
Friede, Völkerverständigung und überhaupt blabla

[-- Attachment #2: Type: text/plain, Size: 797 bytes --]

diff --git a/lisp/org-src.el b/lisp/org-src.el
index 0ac8e6c..63c749c 100644
--- a/lisp/org-src.el
+++ b/lisp/org-src.el
@@ -644,8 +644,11 @@ the language, a switch telling if the content should be in a single line."
 	  (setq buffer-file-name
 		(concat (buffer-file-name (marker-buffer org-edit-src-beg-marker))
 			"[" (buffer-name) "]"))
-	  (set (if (featurep 'xemacs) 'write-contents-hooks 'write-contents-functions)
-	       '(org-edit-src-save)))
+	  (if (featurep 'xemacs)
+	      (progn
+		(make-variable-buffer-local 'write-contents-hooks) ; needed only for 21.4
+		(setq write-contents-hooks '(org-edit-src-save)))
+	    (setq write-contents-functions '(org-edit-src-save))))
       (setq buffer-read-only t))))
 
 (org-add-hook 'org-src-mode-hook 'org-src-mode-configure-edit-buffer)

[-- Attachment #3: Type: text/plain, Size: 201 bytes --]

_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

  reply	other threads:[~2010-05-24  8:39 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-11  9:04 Xemacs incompatibilities Dr. Volker Zell
2010-05-14 12:40 ` Carsten Dominik
2010-05-15 10:09   ` Leo
2010-05-17 14:39   ` Michael Sperber
2010-05-17 14:46     ` Carsten Dominik
2010-05-17 18:47       ` Dan Davison
2010-05-20  2:41         ` Dan Davison
2010-05-24 14:22       ` Michael Sperber
2010-05-20 16:31     ` Dr. Volker Zell
2010-05-24  8:39       ` Michael Sperber [this message]
2010-05-24 13:23         ` PATCH: " Dan Davison
2010-05-24  8:41       ` PATCH: Fix minor XEmacs compatibility issue Michael Sperber

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=y9l1vd1k817.fsf_-_@deinprogramm.de \
    --to=sperber@deinprogramm.de \
    --cc=carsten.dominik@gmail.com \
    --cc=davison@stats.ox.ac.uk \
    --cc=dr.volker.zell@oracle.com \
    --cc=emacs-orgmode@gnu.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).