emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Orgmode] Org-mode version 6.32trans and 6.21b; Strange interaction


From: Martin Pohlack
Subject: Re: [Orgmode] Org-mode version 6.32trans and 6.21b; Strange interaction between whitespace-mode and cust. org-ellipsis
Date: Thu, 03 Dec 2009 22:34:19 +0100
User-agent: Thunderbird 2.0.0.23 (X11/20090918)

Carsten Dominik wrote:
> Hi Martin, this looks to me like a bug in whitespace.el, why does it  
> override the display table org-mode is using?

Hmm, my understanding is that each buffer can have its own display
table, buffer-display-table.  whitespace-mode has to modify this table
(or install an own one) if it wants to do buffer-local modifications.
So I think it modifies org-mode's table but doesn't override it.

My irritation is that by doing so, it does modifies some global state
that effects other buffers.

A short look into org.el shows that org-display-table is never made
buffer local, so this data structure is shared across all org-mode buffers?

The following hack seems to solve this problem:

--- org.el.bak  2009-12-03 22:31:07.000000000 +0100
+++ org.el      2009-12-03 22:31:48.000000000 +0100
@@ -427,9 +427,6 @@
                 (face :tag "Face" :value org-warning)
                 (string :tag "String" :value "...#")))

-(defvar org-display-table nil
-  "The display table for org-mode, in case `org-ellipsis' is non-nil.")
-
 (defgroup org-keywords nil
   "Keywords in Org-mode."
   :tag "Org Keywords"
@@ -4170,8 +4167,7 @@
   (when (and org-ellipsis
              (fboundp 'set-display-table-slot) (boundp
'buffer-display-table)
             (fboundp 'make-glyph-code))
-    (unless org-display-table
-      (setq org-display-table (make-display-table)))
+    (setq org-display-table (make-display-table))
     (set-display-table-slot
      org-display-table 4
      (vconcat (mapcar


Cheers,
Martin




reply via email to

[Prev in Thread] Current Thread [Next in Thread]