From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Kastrup Newsgroups: gmane.emacs.devel Subject: Re: linum and AUCTeX: line number face Date: Mon, 17 Sep 2007 17:02:36 +0200 Message-ID: <86tzpt5o8j.fsf@lola.quinscape.zz> References: <46ea83d1$0$16117$9b4e6d93@newsspool1.arcor-online.net> <87zlzm9uy7.fsf@escher.local.home> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1190041370 2290 80.91.229.12 (17 Sep 2007 15:02:50 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 17 Sep 2007 15:02:50 +0000 (UTC) Cc: emacs-devel@gnu.org To: Stephan Hennig Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Sep 17 17:02:47 2007 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 1IXI7X-0004E7-LF for ged-emacs-devel@m.gmane.org; Mon, 17 Sep 2007 17:02:43 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IXI7W-0001tN-DX for ged-emacs-devel@m.gmane.org; Mon, 17 Sep 2007 11:02:42 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IXI7T-0001tB-5U for emacs-devel@gnu.org; Mon, 17 Sep 2007 11:02:39 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IXI7R-0001sU-QG for emacs-devel@gnu.org; Mon, 17 Sep 2007 11:02:38 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IXI7R-0001sQ-IZ for emacs-devel@gnu.org; Mon, 17 Sep 2007 11:02:37 -0400 Original-Received: from pc3.berlin.powerweb.de ([62.67.228.11]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IXI7R-0003AC-2r for emacs-devel@gnu.org; Mon, 17 Sep 2007 11:02:37 -0400 Original-Received: from quinscape.de (dslnet.212-29-44.ip210.dokom.de [212.29.44.210] (may be forged)) by pc3.berlin.powerweb.de (8.9.3p3/8.9.3) with ESMTP id RAA08034 for ; Mon, 17 Sep 2007 17:02:28 +0200 X-Delivered-To: Original-Received: (qmail 28990 invoked from network); 17 Sep 2007 15:02:36 -0000 Original-Received: from unknown (HELO lola.quinscape.zz) ([10.0.3.43]) (envelope-sender ) by ns.quinscape.de (qmail-ldap-1.03) with SMTP for ; 17 Sep 2007 15:02:36 -0000 Original-Received: by lola.quinscape.zz (Postfix, from userid 1001) id 2A1148F8ED; Mon, 17 Sep 2007 17:02:36 +0200 (CEST) In-Reply-To: (Stephan Hennig's message of "Mon\, 17 Sep 2007 15\:57\:02 +0200") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/23.0.50 (gnu/linux) X-Detected-Kernel: Linux 2.4-2.6 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:79111 Archived-At: Stephan Hennig writes: > Stephen Berman schrieb: > >> If you customize the linum face to default, then all line numbers >> have the default face. It seems the default face does not "inherit" >> the face properties of the string that the linum display property is >> on, whereas, for example, the shadow face, used by default by >> linum.el version 0.9n and later, does inherit at least some face >> properties or attributes. > > Thanks! For \bfseries using default face works for all fonts I've > tried. But for \section commands the behaviour is even more strange. > > As long as default face refers to, e.g., 'Courier New' or 'Bitstream > Vera Sans Mono' all seems to be well. But when default refers to, e.g., > 'Outline-Consolas' or 'Lucida Sans Typewriter' weight is still inherited > from line's face if there's a \section command in that line. > > To reproduce the problem, put the following lines into file .emacs: > > (progn (cd "~/elisp") (normal-top-level-add-subdirs-to-load-path)) > (require 'linum) > (custom-set-faces > ;; custom-set-faces was added by Custom. > ;; If you edit it by hand, you could mess it up, so be careful. > ;; Your init file should contain only one such instance. > ;; If there is more than one, they won't work right. > '(default ((t (:stipple nil :background "SystemWindow" :foreground > "SystemWindowText" :inverse-video nil :box nil :strike-through nil > :overline nil :underline nil :slant normal :weight normal :height 108 > :width normal :family "Bitstream Vera Sans Mono")))) > '(linum ((t (:inherit default)))) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ That is not the default face. Try (copy-face 'default 'linum) or (put 'linum 'face-alias 'default instead). Inheriting will, of course, be overridden by any new properties. That's the whole point of it. -- David Kastrup