From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Tassilo Horn Newsgroups: gmane.emacs.devel Subject: Re: hi-lock and overlays Date: Tue, 19 Jan 2010 08:41:35 +0100 Message-ID: <87ska2tuc0.fsf@thinkpad.tsdh.de> References: <87hbqk620u.fsf@thinkpad.tsdh.de> <87ljfvqerd.fsf@thinkpad.tsdh.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1263886959 28657 80.91.229.12 (19 Jan 2010 07:42:39 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 19 Jan 2010 07:42:39 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jan 19 08:42:32 2010 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 1NX8j8-0003g7-QH for ged-emacs-devel@m.gmane.org; Tue, 19 Jan 2010 08:42:15 +0100 Original-Received: from localhost ([127.0.0.1]:57041 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NX8j9-0005x4-QI for ged-emacs-devel@m.gmane.org; Tue, 19 Jan 2010 02:42:15 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NX8if-0005YB-BA for emacs-devel@gnu.org; Tue, 19 Jan 2010 02:41:45 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NX8iZ-0005WW-Mv for emacs-devel@gnu.org; Tue, 19 Jan 2010 02:41:44 -0500 Original-Received: from [199.232.76.173] (port=33638 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NX8iZ-0005WO-HM for emacs-devel@gnu.org; Tue, 19 Jan 2010 02:41:39 -0500 Original-Received: from mx20.gnu.org ([199.232.41.8]:33498) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NX8iZ-0006fM-0D for emacs-devel@gnu.org; Tue, 19 Jan 2010 02:41:39 -0500 Original-Received: from deliver.uni-koblenz.de ([141.26.64.15]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NX8iY-0005DA-4e for emacs-devel@gnu.org; Tue, 19 Jan 2010 02:41:38 -0500 Original-Received: from localhost (localhost [127.0.0.1]) by deliver.uni-koblenz.de (Postfix) with ESMTP id DB58F78A3BEE for ; Tue, 19 Jan 2010 08:41:36 +0100 (CET) Original-Received: from deliver.uni-koblenz.de ([127.0.0.1]) by localhost (deliver.uni-koblenz.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 15664-02 for ; Tue, 19 Jan 2010 08:41:36 +0100 (CET) X-CHKRCPT: Envelopesender noch tassilo@member.fsf.org Original-Received: from thinkpad.tsdh.de (unknown [141.26.95.45]) by deliver.uni-koblenz.de (Postfix) with ESMTP id 261BF78A3BDD for ; Tue, 19 Jan 2010 08:41:36 +0100 (CET) Mail-Copies-To: never Mail-Followup-To: emacs-devel@gnu.org In-Reply-To: (Lennart Borgman's message of "Mon, 18 Jan 2010 22:51:23 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.91 (gnu/linux) X-Virus-Scanned: amavisd-new at uni-koblenz.de X-detected-operating-system: by mx20.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) 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:120224 Archived-At: Lennart Borgman writes: Hi Lennart, >> I was wrong with my previous mail. =C2=A0The problem that hi-lock pattern >> on the current line are not highlighted, when `hl-line-mode' is >> enabled is not due to conflicting overlays. =C2=A0The problem is that >> hi-lock uses overlays only when the undocumented variable >> `font-lock-fontified' is nil (see `hi-lock-set-pattern'). =C2=A0Else, it >> uses normal fontification, and overlays (like the one for the current >> line created by `hl-line-mode') take precedence over that. > > > I would rather turn the question this way: > > - Why can't an overlay have a priority that is lower than text? ,----[ (info "(elisp)Overlay Properties") ] | `priority' | This property's value (which should be a nonnegative integer | number) determines the priority of the overlay. No priority, or | `nil', means zero. |=20 | The priority matters when two or more overlays cover the same | character and both specify the same property; the one whose | `priority' value is larger overrides the other. For the `face' | property, the higher priority overlay's value does not completely | override the other value; instead, its face attributes override | the face attributes of the lower priority `face' property. |=20 | Currently, all overlays take priority over text properties. Please | avoid using negative priority values, as we have not yet decided | just what they should mean. `---- Hm, reading the last paragraph, this would be an option. A negative priority could be used to make text properties precede overlay properties. Anyway, the two other questions of my previous mail still stand. Bye, Tassilo