[Top][All Lists]

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

Re: [Orgmode] Re: Bug: Invalid face reference

From: Wanrong Lin
Subject: Re: [Orgmode] Re: Bug: Invalid face reference
Date: Fri, 29 Feb 2008 15:44:44 -0500
User-agent: Thunderbird (Windows/20070728)

I already did so. So far there is no problem. If I don't report anything, I think you can assume in the next release that I have no problem at all with the htmlize advice removed.


Carsten Dominik wrote:
I am taking this patch thanks!

This might indeed make the advice for htmlize unnecessary - could you please
remove it your own setup and test this for a long while?  And then
report back?


- Carsten

On Feb 29, 2008, at 7:41 PM, Wanrong Lin wrote:

Found the bug and fixed it as following (see the comment line marked with <WL>)
(defun org-agenda-align-tags (&optional line)
"Align all tags in agenda items to `org-agenda-tags-column'."
(let ((inhibit-read-only t) l c)
    (goto-char (if line (point-at-bol) (point-min)))
(while (re-search-forward (org-re "\\([ \t]+\\)\\(:[[:alnum:]_@:]+:\\)[ \t]*$")
              (if line (point-at-eol) nil) t)
   (match-beginning 2) (match-end 2)
   ;; <WL>: bug fix against 5.22a
   (list 'face (delq nil (list 'org-tag (get-text-property
                                         (match-beginning 2) 'face)))))
  (setq l (- (match-end 2) (match-beginning 2))
        c (if (< org-agenda-tags-column 0)
          (- (abs org-agenda-tags-column) l)
  (delete-region (match-beginning 1) (match-end 1))
  (goto-char (match-beginning 1))
  (insert (org-add-props
          (make-string (max 1 (- c (current-column))) ?\ )
          (text-properties-at (point))))))))

Wanrong Lin wrote:
More update:

In a tag search result buffer, I move the cursor to a tag, and eval (get-text-property (point) 'face), and I get: (org-tag nil). So this "nil" is causing the problem, but I don't know where it is sneaked in.


Just some update:

I called (org-restart-font-lock) function inside my tag search result buffer, and I can see a new "Invalid face reference: nil [X times]" message is generated in the "*Messages*" buffer, with "X" keeps increasing. I have "jit-lock-mode" (Just in time font locking) enabled in my emacs config, so I guess that ticking "X" number is from the background font locking process.

It seems something is wrong with font locking for tags. But this only happens in tag search result buffer. It does not happen in regular agenda buffer.

I don't know how to proceed to pin-point this. Can any of you guys also reproduce this? Any suggestions? Thank you.


Emacs-orgmode mailing list
Remember: use `Reply All' to send replies to the list.

reply via email to

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