From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Alexander Pohoyda Newsgroups: gmane.emacs.devel Subject: Re: (font-lock-mode 1) does not always force font-lock Date: 28 Oct 2003 23:09:32 +0100 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: <87he1tt3oj.fsf@oak.pohoyda.family> References: <87vfqffbwe.fsf@oak.pohoyda.family> <8765iephzh.fsf@oak.pohoyda.family> <87y8v9epmv.fsf@oak.pohoyda.family> <87ismcb5ek.fsf@oak.pohoyda.family> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1067385329 9834 80.91.224.253 (28 Oct 2003 23:55:29 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 28 Oct 2003 23:55:29 +0000 (UTC) Cc: hniksic@xemacs.org, Stefan Monnier , emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Wed Oct 29 00:55:26 2003 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AEdgM-0004Sp-00 for ; Wed, 29 Oct 2003 00:55:26 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1AEdgM-00015h-00 for ; Wed, 29 Oct 2003 00:55:26 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AEdbs-0008Mp-Il for emacs-devel@quimby.gnus.org; Tue, 28 Oct 2003 18:50:48 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.24) id 1AEdaJ-0007ea-Uc for emacs-devel@gnu.org; Tue, 28 Oct 2003 18:49:11 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.24) id 1AEdZd-0007M5-Ub for emacs-devel@gnu.org; Tue, 28 Oct 2003 18:49:01 -0500 Original-Received: from [213.165.64.20] (helo=mail.gmx.net) by monty-python.gnu.org with smtp (Exim 4.24) id 1AEdZc-0007Kg-UA for emacs-devel@gnu.org; Tue, 28 Oct 2003 18:48:29 -0500 Original-Received: (qmail 17489 invoked by uid 65534); 28 Oct 2003 22:09:38 -0000 Original-Received: from p508BD569.dip.t-dialin.net (EHLO oak.pohoyda.family) (80.139.213.105) by mail.gmx.net (mp002) with SMTP; 28 Oct 2003 23:09:38 +0100 X-Authenticated: #14602519 Original-Received: from oak.pohoyda.family (oak.pohoyda.family [127.0.0.1]) by oak.pohoyda.family (8.12.9/8.12.9) with ESMTP id h9SM9ZPj002019; Tue, 28 Oct 2003 23:09:35 +0100 (CET) (envelope-from alexander.pohoyda@gmx.net) Original-Received: (from apog@localhost) by oak.pohoyda.family (8.12.9/8.12.9/Submit) id h9SM9Wgv002016; Tue, 28 Oct 2003 23:09:32 +0100 (CET) (envelope-from alexander.pohoyda@gmx.net) X-Authentication-Warning: oak.pohoyda.family: apog set sender to alexander.pohoyda@gmx.net using -f Original-To: rms@gnu.org In-Reply-To: Original-Lines: 41 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:17531 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:17531 > i think that explicit call to font-lock-mode shd apply to all > buffers. Index: font-core.el =================================================================== RCS file: /cvsroot/emacs/emacs/lisp/font-core.el,v retrieving revision 1.23 diff -u -r1.23 font-core.el --- font-core.el 1 Sep 2003 15:45:12 -0000 1.23 +++ font-core.el 28 Oct 2003 22:04:47 -0000 @@ -149,10 +149,6 @@ your own function which is called when `font-lock-mode' is toggled via `font-lock-function'. " nil nil nil - ;; Don't turn on Font Lock mode if we don't have a display (we're running a - ;; batch job) or if the buffer is invisible (the name starts with a space). - (when (or noninteractive (eq (aref (buffer-name) 0) ?\ )) - (setq font-lock-mode nil)) (funcall font-lock-function font-lock-mode) ;; Arrange to unfontify this buffer if we change major mode later. (if font-lock-mode That's what Stefan agreed with, if I got him right. > instead global-font-lock-mode should check to avoid temp bufs. > someone want to do it? I don't know how to do that because global-font-lock-mode is not a function itself, look here: (easy-mmode-define-global-mode global-font-lock-mode font-lock-mode turn-on-font-lock-if-enabled :extra-args (dummy)) An advice is very welcome. -- Alexander Pohoyda PGP Key fingerprint: 7F C9 CC 5A 75 CD 89 72 15 54 5F 62 20 23 C6 44