From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Klaus Zeitler Newsgroups: gmane.emacs.devel Subject: font-lock question Date: Tue, 15 Jul 2008 14:19:47 +0200 Message-ID: Reply-To: kzeitler@alcatel-lucent.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1216124426 10649 80.91.229.12 (15 Jul 2008 12:20:26 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 15 Jul 2008 12:20:26 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jul 15 14:21:11 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KIjWc-0004bU-TC for ged-emacs-devel@m.gmane.org; Tue, 15 Jul 2008 14:20:59 +0200 Original-Received: from localhost ([127.0.0.1]:44451 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KIjVk-0001T7-CG for ged-emacs-devel@m.gmane.org; Tue, 15 Jul 2008 08:20:04 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KIjVf-0001Sb-Hz for emacs-devel@gnu.org; Tue, 15 Jul 2008 08:19:59 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KIjVd-0001SI-0A for emacs-devel@gnu.org; Tue, 15 Jul 2008 08:19:58 -0400 Original-Received: from [199.232.76.173] (port=44928 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KIjVc-0001SD-RE for emacs-devel@gnu.org; Tue, 15 Jul 2008 08:19:56 -0400 Original-Received: from ihemail2.lucent.com ([135.245.0.35]:33215) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KIjVc-0000bL-FB for emacs-devel@gnu.org; Tue, 15 Jul 2008 08:19:56 -0400 Original-Received: from ihrh1.emsr.lucent.com (h135-1-218-53.lucent.com [135.1.218.53]) by ihemail2.lucent.com (8.13.8/IER-o) with ESMTP id m6FCJqB9008104 for ; Tue, 15 Jul 2008 07:19:54 -0500 (CDT) Original-Received: from nbgif1.de.lucent.com (nbgif1.de.lucent.com [135.246.31.82]) by ihrh1.emsr.lucent.com (8.13.8/emsr) with ESMTP id m6FCJoOD003279 for ; Tue, 15 Jul 2008 07:19:51 -0500 (CDT) Original-Received: from sfsws1.de.lucent.com (sfsws1.de.lucent.com [135.246.31.38]) by nbgif1.de.lucent.com (8.11.7p3+Sun/8.11.7) with ESMTP id m6FCJok14516 for ; Tue, 15 Jul 2008 14:19:50 +0200 (MEST) Original-Received: from sfsw51.de.lucent.com (sfsw51.de.lucent.com [135.246.72.99]) by sfsws1.de.lucent.com (8.13.8/8.12.10) with ESMTP id m6FCJmVD006498 for ; Tue, 15 Jul 2008 14:19:49 +0200 (MEST) Original-Received: (from kzeitler@localhost) by sfsw51.de.lucent.com (8.11.7p1+Sun/8.8.8) id m6FCJmF18154; Tue, 15 Jul 2008 14:19:48 +0200 (MEST) X-Authentication-Warning: sfsw51.de.lucent.com: kzeitler set sender to kzeitler@alcatel-lucent.com using -f X-Horoscope: Don't discuss life with RMS this month. Loving your tetrodotoxin now will turn out to be costly after a few seconds. A stranger will think of you as two other people put together. You'll perhaps in a few days be unhappy. User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (usg-unix-v) X-Scanned-By: MIMEDefang 2.57 on 135.245.2.35 X-detected-kernel: by monty-python.gnu.org: Solaris 9 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:100734 Archived-At: For many years I had the following statement in my .emacs file: (defun show-tabs () "Show tabs with a slightly changed background" (font-lock-add-keywords nil '(("\t" (0 'tab-face t))) t)) (add-hook 'font-lock-mode-hook 'show-tabs) This has worked without any problems up to 22.1. In version 22.2 and 23 I do have problems with syntax highlighting due to these few lines above, e.g. when I try M-x list-faces-display all colors are gone. So here's my question. Did that only work by accident in older versions? Maybe I have to change this code slightly for 22.2 and CVS version, but I can't see what's wrong, when I look at the docu for font-lock-add-keywords. Klaus -- -------------------------------------------------- | Klaus Zeitler Alcatel-Lucent | | Email: kzeitler@alcatel-lucent.com | -------------------------------------------------- --- Copy Protection: A clever method of preventing incompetent pirates from stealing software and legitimate customers from using it.