From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric S Fraga Subject: Re: Re: Enhancing the Org/Gnus experience Date: Thu, 04 Nov 2010 15:11:49 +0000 Message-ID: <87d3qlazt6.fsf@ucl.ac.uk> References: <80k4lj78ui.fsf@mundaneum.com> <87sk07fl3s.fsf@gmail.com> <80k4lf337a.fsf@mundaneum.com> <80vd4z9q2f.fsf@mundaneum.com> <874oc2z2uv.fsf@gmail.com> <8062wdcp6y.fsf@mundaneum.com> <877hgtfhaq.fsf@ucl.ac.uk> <80sjzh9qtz.fsf@mundaneum.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from [140.186.70.92] (port=41791 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PE1Tu-000063-8r for emacs-orgmode@gnu.org; Thu, 04 Nov 2010 11:12:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PE1Tr-0007gj-Fa for emacs-orgmode@gnu.org; Thu, 04 Nov 2010 11:12:01 -0400 Received: from vscane-b.ucl.ac.uk ([144.82.108.141]:46910) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PE1Tr-0007gC-8A for emacs-orgmode@gnu.org; Thu, 04 Nov 2010 11:11:59 -0400 In-Reply-To: <80sjzh9qtz.fsf@mundaneum.com> (=?utf-8?Q?=22S=C3=A9bastien?= Vauban"'s message of "Thu, 04 Nov 2010 14:11:04 +0100") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: =?utf-8?Q?S=C3=A9bastien?= Vauban Cc: emacs-orgmode@gnu.org S=C3=A9bastian & Eric, Just to follow up on this... (today is my "don't get any real work done and spend some time on org instead" day, I guess ;-) I'm starting to understand the mm-uu-* codes. I've added some =3D(message...)=3D entries into the code you have written for fontifying org blocks in gnus messages: #+begin_src emacs-lisp (defun my-display-org-inline (handle) (condition-case nil (let (ret) (message "about to invoke mm-display-inline with handle=3D%s\n" handl= e) (setq ret (mm-display-inline-fontify handle 'org-mode)) (message "mm-display-inline-fontify returned %s\n" ret) ret ) (error (progn (message "Got an error in my-display-org-inline\n") (insert (with-temp-buffer (mm-insert-part handle) (buffer-string)) "\n"))))) #+end_src The codes appear to be invoked when required. E.g. from *Messages*: : about to invoke mm-display-inline with handle=3D( *mm-uu*<2> (text/org) n= il nil nil nil nil nil) where the buffer =3D*mm-uu*<2>=3D actually has the right contents (an emacs lisp source block): #+begin_src emacs-lisp ;;*** 1.2 (info "(emacs-mime)Non-MIME") ;; regexp of Emacs sources groups (setq mm-uu-emacs-sources-regexp "emacs") [...] (replace-match "" nil nil)))) #+end_src An error does not appear to be thrown by this function. However, the string returned by mm-display-inline-fontify is strange: : mm-display-inline-fontify returned=20 : (lambda nil (let ((inhibit-read-only t)) (delete-region # #))) (I've broken the line after "returned".) Could there be some interaction with, say, gnus article /washing/ treatments? I don't know what that function should be returning but I am concerned about the =3Ddelete-region=3D directive. Could somebody maybe show me what I should be getting for the source block to be fontified correctly? The marker positions appear correct for the source block, by the way. Again, thanks for your time and effort! --=20 : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 23.2.1 : using Org-mode version 7.02trans (release_7.3.18.g3818)