[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Orgmode] Bug: inline image display not working when org-indent-mode
Re: [Orgmode] Bug: inline image display not working when org-indent-mode active, follow-up
Fri, 6 Aug 2010 12:55:23 +0200
Hi Eric, Martin,
thanks for tracking this down! I fixed the part in org-indent.el, at
different location that Erik's proposal
(in org-indent-add-properties and in org-indent-remove-properties)
On Aug 6, 2010, at 6:56 AM, Erik Iverson wrote:
On 08/05/2010 03:34 AM, Martin Pohlack wrote:
On 05.08.2010 04:19, Erik Iverson wrote:
In the past few weeks, I found that the overlays of inline images in
files would flash quickly and then be deleted when using
also happened when re-running an org-babel source block that
output, even without org-indent-mode turned on.
I believe I've tracked this down to the following patch,
If a functions want to elide trigger the modification hooks it should
Could you try to find out the path from where these modifications
occur, insert a relevant bind there, and see if this helps?
OK, seems like I got it!
The overlays would disappear when org-indent-mode was turned on.
Simply bind inhibit-modification-hooks in org-indent-refresh-
section. Do other functions in org-indent.el need this? Possibly,
but it seems like this worked in my basic testing.
diff --git a/lisp/org-indent.el b/lisp/org-indent.el
index 45865d1..f6b0487 100644
@@ -251,7 +251,7 @@ Assumes that BEG is at the beginning of a line."
Point is assumed to be at the beginning of a headline."
- (let (beg end)
+ (let ((beg end) (inhibit-modification-hooks t))
(when (ignore-errors (org-back-to-heading))
(setq beg (point))
The overlays would quickly appear, then disappear when running an
org-babel source block that generates graphical output, say, in R.
This was actually tracked down to using pabbrev.el  in my org
buffers. Ugh. Since this isn't org related, there's nothing in org
to fix, but on the very small chance someone else ever has their
inline images disappearing in org-mode, and uses pabbrev mode, I
fixed it by simply binding inhibit-modification-hooks in the let
block in pabbrev-mark-add-word.
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.